Posts

Showing posts from March, 2012

Grails mixins not working when using JVM forking -

After upgrading to Grails 2.3.5, I found that my mixer only works when JVM forking stops. All my administrators have a code import usage. Maymicsin @ Micsin (Maymicsin) class MyController { where MyMixin src / groovy / util is defined and looks something like Package usage class MyMixin {Private def aMethod (someArgs) {// do something}} When BuildConfig.groovy the following code in the forkConfig = [Adiktmmomiri: 1024 minimum memory: 64, debug: wrong, Adiktmprrm: 256] grails.project.fork = [test: forkConfig, // test Configure settings to run -app JVM: forkConfig, // run-app JVM Configure settings for Uddh: forkConfig, // Run war configure settings for the JVM console: forkConfig // swing console JVM] Then I get the following error Missing error when processing request: method has no signature: MyController.aMethod () applies for logic type where the logic types match and the course The code works when I have a JVM forking in BuildConfig.groovy E do...

java - JPA equivalent of Hibernate's @Generated(GenerationTime.ALWAYS) -

जब एक इकाई के कुछ विशिष्ट गैर कुंजी फ़ील्ड उत्पन्न होती हैं (उदाहरण के लिए, ट्रिगर्स द्वारा ) जारी रखने के लिए एक कॉल एक ऐसे डेटाबेस को वापस नहीं लाएगा, जो एक डेटाबेस द्वारा अभी उत्पन्न हो। व्यवहार में इसका मतलब है कि आपको रिफ़्रेश को निरंतर या मर्ज के बाद की आवश्यकता हो सकती है (और जब स्तर 2 कैश सक्षम है तो आपको इसकी आवश्यकता भी हो सकती है बेदखल इकाई)। सीतनिद्रा में होना एक कस्टम एनोटेशन है जो संभाल लेगा। // सम्मिलित करें और अपडेट पर गुण 1 को रिफ्रेश करें @ जनरेटेड (जेनरेशन टाइम.अलव्स) @ कॉलम (डालने योग्य = गलत, अपडेट करने योग्य = झूठे) निजी स्ट्रिंग गुण 1; // सम्मिलित करें @ पर जेनरेट किए गए (GenerationTime.INSERT) @ कॉलम पर संपत्ति 2 रिफ्रेश करें @ स्तंभ (डालने योग्य = गलत) निजी स्ट्रिंग गुण 2; जेपीए केवल प्राथमिक कुंजी गुणों के साथ काम करता है तो, मेरा सवाल है कि अगर JPA API पर @ जनरेटेड के लिए कोई प्रतिस्थापन है (शायद 2.1 पर)? और अगर कोई भी नहीं है, तो गैर महत्वपूर्ण डेटाबेस जनरेट किए जाने वाले क्षेत्रों को संभाल करने के लिए सबसे अच्छा अभ्यास क्या है? ...

c# - Reading MySql binlog -

I do not agree that this question was effectively answered: My Pass, which I think is the same question: I want to read a MySQL binologue from within the C # application, but do not know the format of the file. How can I parse the data of these files correctly? First of all, what I learned: MySQL Most source code files are set up with assemblies and are usually included in [Assinner] \. For example, a specific installation program file \ MySql \ MySql 5.6 \ in. Do not place the files in that folder. However, I was able to obtain a quick Google search file easily. The file can be found here: It is well documented and easy to read Second, My solution :. As told by akuzminsky, the format of the binlog of MySQL is subject to change. However, the format returned from the mysqlbinlog.exe utility is compatible. This application is usually included in a MySQL install and it should be located in the [iriser] \ bin. Now let me run this application from within the C # con...

php - Fatal error: Uncaught exception 'Exception' with message 'DateTime::__construct(): -

घातक त्रुटि: संदेश 'DateTime :: __ construct () के साथ अपवाद' अपवाद ': समय की स्ट्रिंग को पार्स करने में विफल ... पंक्ति 26 पर $ first_installment_date = नया दिनांक समय ($ aData [ 0] - & gt; FIRST_INSTALL_DATE); php codeigniter ठीक पहले काम कर रहा था ... जब मैं ओरेकल एन एक्सएम्पपी को पुनः स्थापित करता है..यसी त्रुटि दिखाता है 15 / JAN / 20) नहीं है DateTime () के लिए। आपको उस दिनांक को पार्स करने के लिए उपयोग करना होगा: // मान लें कि YY / सोम / डीडी $ first_installment_date = दिनांक समय :: createFromFormat ('y / m / d', $ aData [0] - & gt; FIRST_INSTALL_DATE);

Cannot debug qt app - Debugging has finished -

I have a QT app that I'm trying to debug with success. I get the following application output: Debugging starts Debugging is finished And nothing happens. I'm using the MSVC2012 x64 compiler, the apple runs fine in release mode or if I choose to run it in debug mode (not debug). Any remedy? Thanks! OK I have a problem - the debugger used was the CDB of the x86 version. Xiis was. I changed it to x64 and everything is working as expected.

visual studio 2013 - Why does VS2013 sometimes throws exception 0x80070057 when closing a file? -

Sometimes, not all the time, the Win7 x64 machine is an exception to Visual Studio 2013 w / update 1 up to date C: \ Users \ AppData \ roaming \ Microsoft \\\\ "C: \ Users \ AppData \ roaming \" \ "ActivityLog.xml \" file has been closed in a dialog to close a file, or close all " VisualStudio \ 12.0 \\ "One of the following entries was that each file was being closed. I am using the latest version of DevExpress controls. How can I fix this? I did not find any similar issues, though the post was exactly the same, but it does not happen when I open a solution. So far, it seems that when many instances of VS 2013 are open, I am unable to reconsider the same. Component model cache was not helped in cleaning because it has happened again after clearing the cache. The solution was originally a VS 2012 solution, and all the new Dxx, MVC and EF components have been updated with the newgate in the latest versions. & lt; Entry & gt; & Lt; Rec...

javascript - Updating visited status of a link when changing its href attribute, under Chrome -

जब मैं जावास्क्रिप्ट $ ('# link_id') के साथ लिंक अपडेट कर रहा हूं। ('Href', some_new_url) विज़िट किए गए / गैर-दौरा किए लिंक के लिए रंग विषय बनी रहती है, नए यूआरएल पते की स्थिति पर ध्यान दिए बिना। और नोट्स: मैं क्रोम (32) और सफारी में इस समस्या का अनुभव कर रहा हूँ (OSX 10.8 पर)। 6.1)। फ़ायरफ़ॉक्स (26) में लिंक्स की स्थिति वांछित होती है, जैसा कि वांछित होता है। उपर्युक्त उदाहरण jQuery में है, लेकिन समस्या वैनेला जावास्क्रिप्ट के साथ उसी प्रकार है, अर्थात document.getElementById और setAttribute । (अगर संभव है तो मैं & lt; a & gt; & lt; / a & gt; को हटाने और जोड़ना पसंद करता हूं।) संपादित करें: कम से कम (गैर) काम कर रहे उदाहरण (Joeytje50 द्वारा): निश्चित जवाब आप इसे ठीक करने के लिए क्या कर सकते हैं, बस ब्राउज़र को href विशेषता को पूरी तरह से हटाकर शैलियों की पुनर्गणना करने के लिए मजबूर कर रहा है, और फिर पुन: इसे तुरंत बाद में वापस जोड़ना इससे पहले कि ब्राउज़र पहले शैलियों की गणना करेगा, क्योंकि & lt; a & gt; अ...

linux - How to create alias for bash inside php exec? -

मेरे पास ऐसा कोड है: सार्वजनिक फ़ंक्शन शेल ($ कोड) {$ code = Preg_replace ('/ "/', '\\' ', $ कोड); Exec ('bash -c' '$ code।' '', $ परिणाम); वापसी का परिणाम; } और मैं alias ls = "ls --color = always" को जोड़ना चाहता हूं। मैंने इसे .bashrc फ़ाइल में डालने का प्रयास किया है जिसे मैंने अपनी प्रोजेक्ट डायरेक्टरी में उस शेल के लिए बनाया है और उपयोग करें: exec ('bash -c' .bashrc; ' $ कोड। '' ', $ परिणाम); लेकिन यह काम नहीं कर रहा है, मैं सही निर्देशिका में हूं क्योंकि जब मैं ls-A को कॉल करता हूं उस फ़ाइल को देखता हूं। मैंने कोशिश की है - init-file और - rcfile सिर्फ एक फाइल और पूर्ण पथ के साथ। मैं उपनाम और फ़ंक्शन कैसे जोड़ सकता हूं कि खोल करने के लिए? क्या यह संभव है? फ़ंक्शंस का उपयोग शायद वैसे भी एक बेहतर विकल्प है। हालांकि, ध्यान दें कि उपनामों का उपयोग करना संभव है : & lt;? Php $ code = 'ls'; $ Aliases = 'shopt -s विस्तार_अलीज़ एलियां ls = "ls -l...

java - CalendarView.setTime issues -

I have issues trying to use .setTime on the calendar ops object, see the code below. package com.example.calendar_test; Import java.util.Calendar; Import java.util.Date; Importroid.os.Bundle; Import android App Import android.content.Context; Import android.text.format.DateFormat; Import android.text.format.Time; Import android.view.Menu; Import android.view.View; Import android.widget.CalendarView; Import android.widget.Toast; Import android.widget.CalendarView.OnDateChangeListener; Public class enhances main activity activity (calendar view cv; @ override protected zero to create the constellation (InstantState saved from bundle) {late start date; super.onCreate (savedInstanceState); setContentView (R.layout.activity_main); Cv = ( Calendar view) this.findViewById (android.R.id.content) .findViewById (R.id.calendarView1); StartDate = cv.getDate (); cv.setDate (cv.getDate ()); last reference reference = this; cv .setOnDateChangeListener (New OnDet Change Listener) {Cancel Select...

android - CWAC Camera crash on NPE on Motorola Device -

I'm also having trouble opening the CameraDamO-V9 application (using version 0.6 of the library). The hardware I am testing is a Motorola DDR Razor MXx HD. It is currently the only physical device that I have access to, but the library works on this phone when this version was around 0.4.2. I am getting into the logbook: 02-17 16: 38: 17.889: E / Android time (4382): Reasons for this: java.lang.NullPointerException 02-17 16: 38: 17.889: E / AndroidRuntime (4382): com.commonsware.cwac.camera.CameraView.setHost (CameraView.java:87) 02-17 16: 38: 17.889: E / Android Time (4382): com.commonsware.cwac Camera.acl.CameraFragment.onCreateView (CameraFragment.java:40) 02-17 16: 38: 17.889: E / Android TimeTime (4382): Android. Support.v4.app.Fragment.performCreateView (piece Java1500) 02 -17 16: 38: 17.889: E / Android Random (4382): Android. Support.v4.app.FragmentManagerImpl.moveToState (FragmentManager.Java: 9 27) 02-17 16: 38: 17.889: E / Android TimeTime (4382): Android Support....

c# - How do you loop Readline statements? -

I have homework work and I'm stuck on a certain part of the question. How do I make a Loop number about the readline statement? In other words, suppose I have two numbers which I want to input. Instead of typing the readline statement twice, how do I get a loop which will allow me to type the readline statement once? There are two numbers that I want to input, instead of typing the readline statement twice , how do I get a loop do, which I once Reedlain statement will allow you to type well, if you want to number two, you're going to have two variables (or an array ), So I think you are trying to change it: int firstNumber; Int secondNumber; FirstNumber = int.Parse (console.readline ()); SecondNumber = int.Parse (console.readline ()); In something like this: int [] myNumbers = new int [2]; (Int i = 0; i & lt; 2; for i ++) (myNumbers [i] = int.Parse (Console. Reedlain ());} But it Think: Will the signal be identical for both numbers? Or there w...

java - How can I Generate a Random Response -

Trying to get one of the responses in the hashaseet when I enter Hello, but display all items in the hash Any help given below is my code. public class tst {public static void main} (string [] args) {scanner input = new scanner (System.in); HashMap & LT; String, HashSet> Map = new hashmap & lt; String, hashase & gt; (); Hasheset & lt; String & gt; HS = new hashset & lt; String & gt; (); Random R = New Random (); Hs.add ("How are you"); Hs.add ("what happened"); H. S.D. ("How did you do it"); Hs.add ("Missed Me"); Hs.add ("ab"); Hs.add ("cd"); Hs.add ("I'm sorry"); Map.put ("hi", hs); System.out.println (Enter "Hi"); String str = input.next (). ToLowerCase (). Trim (); If (map.containsKey (str)) {System.out.println (map.get (str)); }}}} I changed my code and a ArrayList & lt ; String & gt; a HashSet & lt; String & gt; Instead of I ...

python - Set initial value with django-filters? -

When using an app, how can I set the initial value of the field in my filter? Usually with a standard form in Django , for example a simple selection list form: class MyForm (forms.Form) : Option = (('APP', 'apple'), ('ban', 'banana')) country = forms Start form entry on Choisefield (widget = forms.selection, option = option, initial = 'bann') banana However, my I have something like this in filter.py : class MyFilter (django_filters.FilterSet): option = (('APP', 'apple'), ('ban', 'Banana')) myfield = django_filters.ChoiceFilter (widget = django_filters.widgets.forms.Select (), option = option). . Where to get initially selected element of dropdown, where do I put initial = 'BAN' ? I did not take any advantage of the choisefilter argument and selection () arguments. I thought the idea of ​​the filter was very clearly the behavior of form with the benefit of filtering clearly...

mysql - Insert data from textfile to a database table -

Image
I want to ask some help from entering data in a database table from texfile .... I have created a php code to execute the file on the table, but I have no luck in importing it ... can anyone know how to do this? Please help me Current PHP code: & lt ;? Php $ host = "localhost"; $ User = "root"; $ Pass = ""; $ Db = "clayton"; $ Connect = mysql_connect ($ host, $ user, $ pass); If (! $ Connect) die ("can not connect!"); Mysql_select_db ($ db, $ connect); $ File = fopen ("tblApplicants.txt", "r"); Whereas ($ applicant = fgets ($ file)) Include {$ sql = "TB_Applications (AIC, Name) values ​​('$ applicants')"; Mysql_query ($ sql); }? & Gt; Read each row from this file, leave every second line $ i% 2 == 0 break; This "|" Explode and get another ($ line [1]) and the next object ($ line [2]), then trim it, and insert the SQL. Try to do this way

java - How to pull individual pieces of data from a JSON output String? -

In Java, how do I drag data to just the "data" section in the following JSON output? {"getuserhashrate": {"data": 1425, "runtime": 8.2659721374512, "version": "1.0.0"}} Json.get ("data") does not work and returns the following error: Exception to "main" org.json.JSONException thread: JSONObject ["data"] was not found. At org.json.JSONObject.get (JSONObject.java:454) so4308554.JsonReader.main (JsonReader.java:40) You have a JSON object that has exactly one field: getuserhashrate {" getuserhashrate ": ...} There is another JSON object in that field that has its own field ("data", "runtime", etc.). {"data": 1425, "runtime": 8.2659721374512, ..} By looking at your stack trace, you're using the original Are (or). You parse JSON and get the top-level object back through: JSONObject Root = New JSONObject (myJsonSt...

python - scipy.optimize.basinhopping interval and accept test syntaces -

मैं basinhopping का उपयोग करते हुए एक उद्देश्य फ़ंक्शन की वैश्विक न्यूनतम खोज करने की कोशिश कर रहा हूं, लेकिन बहुमत के लिए उस समय के एक स्थानीय न्यूनतम पर अटक गया है मैंने दस्तावेज़ के माध्यम से पढ़ा और पाया कि अंतराल और accept_test सहायक हो सकता है, लेकिन अब सवाल यह है कि उन्हें क्या देना है, उदा। मैं चाहता हूं कि मेरे उद्देश्य का कार्य 4 या 5 जैसे बहुत बड़े मूल्यों पर बहुत अधिक समय बिताने के बिना संभवत: 0 (1e-5 बंद) के करीब जाने के लिए चाहें। अंतराल के लिए कैसे पता चलता है कि कितनी बार एक Stepsize अद्यतन किया जा रहा है? यहाँ मैं एक "वैश्विक" न्यूनतम की तलाश कर रहा हूं: np.random.seed (555) # प्रतिकृति की अनुमति देने के लिए बीज। Minimizer_kwargs = {"विधि": "एल-बीएफजीएस-बी", "सीमा": बीएसडीओ, tol = 1e-4} रेट = बेसिनोपिंग (मेरिट_फंक्शन, एबीसीडीएक्स, मिनिमजर_क्वार्ग्ज = मिनिमजर_क्वार्ग, निटर = 10) ज़ूम = रेट ['एक्स '] Res = minimize (merit_function, ज़ूम, विधि =' एल-बीएफजीएस-बी ', सीमा = बीड, टोल = 1e-9) प्रिंट रेस ...

ios - Sprite Frame Animation Cocos2d 3.0 -

I am trying to create an animated sprite, they have lots of tutorials but they are all for Cocos 2D 2 X The name of my sprite sheet is flapboard page and Plist's name is flappbird.plist I have this code but every time I crash it, it's in my init method // ------------------------------------ ------ ----------------------------- _player = [CCS Prakash Spit with Image Nominated: @ "Monster 1 Page"]; // your. The plist file comes from _player.position = ccp (self.contentSize.width / 28, self.contentSize.height / 2); _player.physicsBody = [With sycophysics body body: (CGRact) {CGPointZero, _player.contentSize} Corner: 0]; // 1 _player.physicsBody.collisionGroup = @ "Players Group"; _player.physicsBody.Type = CCFixixBodyTypeStatic; CCSpriteBatchNode * Batch node = [CCSpriteBatchNode batch nodewhitefile: @ "Monster 1Page"]; [Batch node adb: _player]; [Self linking child: batch node]; NSMutableArray * animFrames = [NSMutableArray array]; For (...

gruntjs - Simple html templating for small sites with grunt -

I'm looking for a simple HTML templateing solution for small sites. I really want to do something basic (super simple PHP similar to some) that come out of flat HTML I tried to experiment, but there is so much involved in it. I am coming for reference, some of which are very easy template, but since it is a subscription, I can not do that the way our whole office sites I have also seen the middleman but I think it is very easy to deal with the node. I think there is a way to do this that is looking for a mustache alone but my javascript is not very good. I'd recommend looking for a cabin Workflow uses Grunt and they added LiveLoad support to the previous release. Good choice for using jacail

how to use the (document.forms) with the checkbox name as an array (PHP) -

मुझे ये चेकबॉक्स मिला है: & lt; form name = "achievements_list" id = " Achievements_list "action =" achievements.php "विधि =" पोस्ट "& gt; विदेशी मुद्रा ($ नमूना 1 $ नमूना 2 के रूप में) {& lt; इनपुट प्रकार = "चेकबॉक्स" मान = "'। $ नमूना 2।'" नाम = "उपलब्धि सूची []" / & gt; } और एक साधारण सीमक जो काम नहीं करते अगर चेकबॉक्स नाम को एक सरणी के रूप में सेट किया जाता है: सीमक काम नहीं कर रहा है क्योंकि इनपुट चेकबॉक्स नाम को ब्रैकेट्स [] है। इसे कैसे काम किया जाए? सिंटैक्स के साथ फ़ॉर्म को एक्सेस करना myForm ["myelement"] मेरा फ़ार्म के रूप में एक ही परिणाम है। Myelement, सिवाय इसके कि यह जावास्क्रिप्ट अवैध पहचानकर्ता या व्याकरण के निर्माण की अनुमति देता है जो अनपेक्षित परिणामों का कारण बनता है (आपके मामले में: नाम के आधार पर एक तत्व प्राप्त करने के बजाय एक सरणी के रूप में एक अनिर्दिष्ट तत्व तक पहुंचने का प्रयास करना एक PHP- अपेक्षित सरणी नोटेशन)

html - How to get <input type="time" /> to display full time picker in IE 10, Firefox, Safari, etc -

I am struggling this whole day. I am using & lt; In our company web application, input type = "time" /> for a long time. , and only recently I came to know that it is showing a dropdown with only 5 minutes intervals in IE and Firefox. I believe that this is happening in Safari. Is there any solution so that it works on all browsers? As a side note, it seems ridiculous that these extremely popular browsers will not support the new HTML5 input types. Super disappointing. Anyway, thanks in advance for help. If you suggest using a JavaScript time picker, it works more robustly so the default A Look at this one.

asp.net - Converting inc files to php files -

I am working on a project which is in ASP. My customer wants to convert me to ASP.NET in ASP.NET . There are several .include files in this project, which are kept in a folder and these ink files & lt ;! - #include file = "../include / example.inc" - & gt; Many pages contain most of these files are variables or constants that are used in many pages or functions (written in VBScript). Now my client tried to convert me these ink files into PHP files (there is no clue about php as I have never done before). My question is here How will it affect these files in PHP? How can I call the function in php page from aspx page? What would be better way of php? Thanks in advance! For this, all of these flies will need to be rewritten because someone in PHP VBSP is not supported. Therefore, 'effectiveness' is the best objective statement that this person is accidental on the qualifications and skill sets of the migration performance. You c...

javascript - How to get MySQL query result returned using $.ajax -

I'm trying to update is a JavaScript, when you hover over an image, a devi Floats near your mouse, this information is stored in an .js file as an array, for example. text [0] = ["image 1", "data1"] text [1] = ["image2", "data2"] In the past, if the array change / add / delete the data it will need to upload a new copy .js file, if the data was attached / deleted, then the new image needs a change in .dwt file Which can update each file using the .dwt file as the main template, which can result in 20+ pages They are uploaded I thought that I can automate this record by using the database and using the database if they are active and use only mysql queries which are active, such a black app The database can be added and disabled, thus eliminating the need for every soft upload of the file. To do this, I had planned to store the information in the database and create the above array based on the results, by researching how to us...

json - Refresh Button / Auto Update GOOGLE SPREADSHEET -

I hope you can help me I'm trying to get this work for some time. I'm taking an API from a website by importing it to Google Spreadsheet VIA importjson () ImportJSON ("") I have no problem importing Jason Data in Google Spreadsheets, now the hard part is updating data, I would really like to update it automatically, but the "Update Now" button will be great Thank you, this is driving me crazy You can simply add time triggers

jquery - Counter that constantly counts up live in real time -

I am trying to find a way to add a counter to a website that is linked to the initial number and counting Regardless of who is watching it, I'm still speculating that it will need to constantly pull / update from its database. Example: Example: Start P> Then it will display the number after real-time or refreshing. Preferably in real time Any help on this will be highly appreciated

curl - google translate api trouble -

I am trying to put the Google translation API to work in my webapp. I am using some Ajax to load into a div, but when I take it on my laptop, I get an error about 50% of the time that it says that there is no index data from the JSN reaction . I think this is because the API has not responded so far, so I'm hoping that I keep a loop here to wait for the code, but I'm not sure where is the PHP page here that XML response Generates & lt ;? Php header ('content-type: text / xml'); $ Cc_nlc = 'good'; If (isset ($ _ POST ['cc_nlc'])) {$ cc_nlc = $ _POST ['cc_nlc']; If (empty ($ cc_nlc)) {$ cc_nlc = 'not very good'; }} Echo & lt ;? Xml version = "1.0" encoding = "UTF-8" standalone = "yes"? & Gt; '; Echo '& lt; Feedback & gt; '; Echo & lt; Translation & gt; '; $ Apikey = 'my key'; $ Url = 'https://www.googleapis.com/language/translate/v2?key=' $ apk ...

ruby on rails - xsl:attribute: Cannot add attributes to an element if children have been already added to the element -

I have this XML: I try to apply it I am doing this xls: Use of this gem: I am getting the following error: runtime error: file style .xsl line 209 element attribute xsl: attribute: can not add attributes to elements if children are already added to the element. I'm not sure its a That means, when I see XML link from Firefox and XSL Sheet, it renders correctly. A shot in the dark, but this line can be 1 9 7 : 1 9 6: 197: | 198: & lt; xsl: each selection =" @ * "& gt; You are adding elements in the text before setting the attributes later. Because & lt; Xsl: if & gt; Block?

ruby - Rugged - fetch, pull rebase possible? -

बीहड़ का उपयोग आप निम्न कार्यों को कैसे करते हैं: fetch , पुल और रिबेस ? मैं विकास शाखा का उपयोग कर रहा हूं और रिमोट वर्ग के लिए एक मार्गदर्शक के रूप में इसकी दस्तावेज़ीकरण की समीक्षा करने के बाद। संपादित करें: चूंकि git pull केवल git fetch और git मर्ज FETCH_HEAD के लिए एक लबादा है बेहतर प्रश्न यह है कि कैसे Git fetch , git मर्ज और git rebase । git fetch: रिमोट = बीहड़ :: रिमोट। लुकअप (रेपो, "मूल") रिमोट.कनेक्ट (: फ़ेच) करो | r | R.download r.update_tips! अंत जीआईटी मर्ज: मर्ज_इनडेक्स = रिपो। मेर्ज_आइटिट्स (बीड़ाग्रस्त :: शाखाएं। लुकअप (रेपो, "मास्टर")। टिप, बीड़ाग्रस्त :: शाखाएं। लुकअप (रेपो, "मूल / मास्टर")। टिप) "संघर्ष का पता चला!" अगर merge_index.conflicts? Merge_commit = rugged :: Commit.create (रेपो, {माता-पिता: [बीड़ाग्रस्त :: शाखाएं। लुकअप (रेपो, "मास्टर")। टिप, बीड़ाग्रस्त :: शाखाएं। लुकअप (रेपो, "मूल / मास्टर")। पेड़: merge_index.write_tree (repo), संदेश: 'मास्टर' ...

perl - 'Unquoted string ".." may clash with future reserved word' but only when package is used -

I ran into this problem while trying to reactor one of my modules in the object-oriented code. I compressed it down to the bottom. Here is the list of 3 files I am using: _mypkg.pm: Usage _debug; Use _debug dprint; Package mypkg; Sub New {my ($ class,% args) = @_; My $ self = blessing {}, $ square; DPPrint "PKG \ n"; Return $ self; } 1; _debug.pm: # package mydebug; # Getting this line gets an error 500 $ my bprint = ""; Sub print_now {print "print:". $ Bprint; $ Bprint = "";} Subprint {$ bprint. = "@_"; } Subdeprint {bprint @_; } 1; testfile.cgi: #! / Usr / bin / perl is required '_mypkg.pm'; #require '_debug.pm'; #use_debug; Use _debug dprint; Print "content-type: text / html \ n \ n"; DePrint "First & lt; br & gt; \ n"; & Amp; Print_now; My $ somepkg = mypkg- & gt; new (); DePrint "Second & lt; br & gt; \ n"; & Amp; Print_now; As they a...

Add class to element when price content changes JQuery DOMCharacterDataModified -

$ H $ price changes, I want to add a square in the price period. I add better products to customers when looking at better visual leads . Tried: $ (document) .ready (function () {$ ('cart-price'). ('DOMCharacterDataModified', function () { $ ('. Cart-price')) addClass ('change'); var delay = setTimeout (function () {$ ('cart-price'). RemoveClass ('change');}, 1100)});} ); CSS: . Cart-price.change {color: # F00; } It seems that it would be better to use because it has been excluded but its Be aware of - IE & lt; 11 does not support it $ (document) .ready (function () {var $ cartprice = $ ('cart-price'); if (in 'mutationObserver' window) {var inspector = New Mutation Observer; Observer Blog ($ CarPrice [0], {Child list: True}) //} For other browsers that do not support Mutation Observer $ CartPrice ('DOMSubtreeModified', Highlight ) Function highlights () {$ cartprice.addClass ('change...

c++ - Most cpu-efficient way to use std:: algorithms with arguments to a variadic function template? -

You have a variadic function template that takes a sequence of functor and homogeneous types, and you Std :: Accumulate sequence fold, like: template & lt; Typename BinaryFuncType, typename ... ArgTypes & gt; Do_something (const BinaryFuncType & amp; F, CONST ERTTYPE & amp; ... objects) {// ... // use std :: to collect 'objects' fold 'F' // ...} What variation algorithms ( std :: accumulate ) directly pass variadic logic ( objects ) Itemprop = "text"> Apparently yes, l In what twisted way. Consider the following code: #include & lt; Algorithm & gt; # Include & lt; Array & gt; # Include & lt; Cstdio & gt; #include & lt; Iterator & gt; Template & lt; Typename ... Ts & gt; Int sum (ts ... number) {std :: arrays & lt; Int, sizeof ... (number) & gt; List {{number ...}}; Return std :: Deposit (std :: start (list), std :: end (list), 0); } __ distributed __ ((noinline)) zero...

php - add background image to entire screen, across all divs -

I am trying to get the following WordPress-based site to keep a consistent background image: I can change the background of individual elements, but there is no way to draw the same background as the full screen. Thank you for your help! Add this CSS to your body class body.custom -background {background: url ('/wp/wp-content/themes/twentyfourteen/assets/BG.jpg'); Background-size: auto 100%; Background size: cover; Background-condition: center center; Background-attachment: fixed; }

Using Geocoding in windows phone 8 -

I used Maps and Geocoding in Android using Google Maps. Currently I am developing a project in Windows Phone 8. I know that the best way or setting the map and using the longitude and latitude is to locate the conditions with the path from the current location. Pls give me some tips or links. Thank you To get started, check "" Article series from MSDN " I know that the best way is to set up the map and use the longitude and latitude to locate the conditions along the path from the current location. " See the third article in the above series if you want to display the map along the path inside your app . Otherwise, you have the easy choice by using this, which will launch the built-in map.

jquery - How to find scroll position of overflow (Please help!) -

वर्तमान में मेरे पास एक अतिप्रवाह है & lt; tbody class = "data" & gt; जो जब स्क्रॉल सीधे शीर्ष पर। क्या इससे पहले कि ओवरफ्लो स्क्रॉल की ऊंचाई रिकॉर्ड करने से पहले इसे रोकने का एक तरीका है और फिर बाद में उस स्थिति में अतिप्रवाह वापस डाल दिया जाए मैंने अभी (मुझे बेवकूफ) काम किया है कि डेटा स्क्रॉल स्थिति के ऊपर 0 है इसलिए मैं इसे इसे रिकॉर्ड नहीं कर सकता। I यह कोशिश की है: // var load = 20; $ ("# लोडमोर")। क्लिक करें (फ़ंक्शन () {var y = $ ("# डेटा")। ScrollTop (); // लोड = लोड + 20; $ .get ("Data.php", {// सीमा: लोड}, फ़ंक्शन (डेटा।) {$ ("। डेटा")। Html (डेटा);})। (फ़ंक्शन () {// color (); $ ("# data")। स्क्रोलटॉप (y) ;});});

html - CSS3 is not working -

I have problems with css3 I am currently following a tutorial, when I test it on my local copy I am not going to read CSS 3 by the browser. Here's the code: & lt; Html & gt; & Lt; Top & gt; & Lt; Style type = "text / css" & gt; / * Custom Font - Montserrat * / @ Import URL (http://fonts.googleapis.com/css?family=montserrat); / * Background * / html, body {min-height: 100%} body {background: # 123; Background: Linear shield (# 123, # 399); } / * Original Reset * / * {Margin: 0; Padding: 0;} / * thumbnail BG * /. Thumb {width: 400px; Height: 300px; Margin: 70px auto; Perspective: 1000px; }. A {display: block; Width: 100%; Height: 100%; Background: URL ("http://thecodeplayer.com/u/m/i1.png"); Conversion-style: protection-3d; / * Hover Effect * / Transform: Rotate X (80 degree); Change original: bottom; } & Lt; / Style & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; Div class = "thumb" & gt; ...

php - Reverting a grant privileges statement in MySQL -

Image
So I'm hacking on some software and I decide to run MySQL order * At all private. * Identify 'password' by 'root' @ '%'; Then I came to know that my bug tracker uses the same local MySQL server on my development PC. Good darn .. Now when I try to use my bug tracker (mantis), I get an error message. Application Error # 400 Database Connection Failed. Error # 1045 from database: User denied access to 'root' @ 'localhost' (using password: no). To return to the previous page, please use the "back" button in your web browser, you can correct any problems that are being recognized in this error or you can select another action. You can click on an option from the menu bar to go directly to a new section. The previous non-fatal error occurred. Follow the content of the page. System Warning: 'mysql_connect () [function.mysql-connect]: User denied access to' root '@' localhost '(using password: no)' ...

operating system - Which Virtual-memory translation technique (consider x86) is used generally? -

It is known that with the help of MMU, there are various types of virtual-address translations (x86) such as segmentation, paging My questions: 1) Normal operating systems such as Linux / Windows only use a special technique (like paging)? 2) If 2 or more techs are available for an OS, then & amp; Where will every one be used? Can we customize according to your needs? 3) If 'paging' is used, then how is Segment registers of x86 used? These include normal, modern operating system x86 usage paging and no split. This means that the base address of the Segment registers is set to zero and the maximum limit of the segment is determined. Paging is used to map the virtual address to physical address, it is a process address space between the processes, Protection, and the privilege (kernel) and the user gives precisely control of security between the address space. Segments are still used in x86 for specific purposes: To run legacy operating systems and applications ...

javascript - Ember Template will render but won't display inside app -

Then there is a topic in the above link which I am trying to explain. but I'm not sure. Here's what's going on, my index template is being provided, but visually I can not see anything. I have no JS errors and it works just fine. When I inspect it all the codes are shown, but for some reason I can see it (the blind code has been provided) shows that the only thing is navigation which is not part of the template. So I take out the whole thing well and eventually call {{outlet}} ... Nop has not seen anything other than navigation. I am not trying to be ambiguous, amber and new to stack overflow. Not sure if a link to the actual problem is sufficient or not, I know that if any further explanation is necessary There is no problem with Please take a look at the example below, This is done by the code / files found in www.redberryapp.com And this content appears to be displayed & lt; Link rel = "stylesheet" href = "http://www.redberryapp...

php - How to do edit function in symfony2 -

I wrote a function for editing in symfony2, my problem is that I can get previous values ​​from the database But after submitting public function editAction ($ id) {$ request = $ this- & gt; GetRequest} (); $ Em = $ this- & gt; GetDoctrine () - & gt; GetEntityManager (); $ Profile = $ em- & gt; GetRepository ('TcprofileBundle: TcProfiles') - & gt; Search ($ ID); $ Profile_form = $ this- & gt; CreateForm (new profile type), $ profile); $ Response = new JasonRespons (); $ Response- & gt; SetData (array ('content' = & gt; $ this- & gt; render view ('TcprofileBundle: default: create.html.twig', array ('form' => $ profile_form-> createView))) )); $ Refund; } Html.twig file & lt; Div class = "edit01" & gt; & Lt; A href = "#! {{Path ('tcprofile_edit', {'Id': profile.getId})}}" & gt; Edit profile & lt; / A & gt; & Lt; / Div & gt; I am ...

sql - How to get row count of a stored procedure? -

I have a stored procedure that accepts client numbers and returns some data. I have another stored procedure that internally calls the first one and needs to use line calculation from previously stored procedure. Can I get it anywhere without using a temporary table (to get the result set) or parameter in the first stored function using one. Thanks. Since you are already calling your archived operation, you already have @@ ROWCOUNT function. Below is an example of using the `@@ Rocheckant to start Proc. Test 1. Start with * sys.tables from selection; EXEC Test1 PRINT @@ ROWCOUNT END EXEC Test2 In my example I have just printed that value, but you can simply assign it in one variable in the same process and it Can use for something else.

PHP and Python integration : Calling python scripts from PHP page and respond back to it -

इस सवाल का पहले से ही एक उत्तर है: 1 उत्तर मेरे पास कुछ लिपियां हैं फाइल अपलोड करने वाली पायथन जो डेटाबेस को पढ़ती है और अपलोड की गई फ़ाइलों को संशोधित करती है मैं एक ही काम करने के लिए एक वेब पोर्टल बनाना चाहता हूं। PHP कोड से इस पायथन स्क्रिप्ट को कॉल करना संभव है? और लेकिन इसमें पैरामीटर कैसे पारित करना है? मैं इसे अपलोड की गई फाइल कैसे पास करूँगा? या क्या यह कोड को अजगर स्क्रिप्ट में छोड़ना ठीक है? पायथन स्क्रिप्ट उत्पन्न होने वाले इंटरैक्टिव बल्क परिणाम पीएचपी पृष्ठ पर वापस लौटने के लिए कैसे? मैंने जवाब ढूंढने की कोशिश की है और मुझे कई मिले हैं, लेकिन मुझे यह करने का सबसे अच्छा तरीका नहीं है। कोई कृपया मुझे इस प्रणाली को डिज़ाइन करने के लिए सर्वश्रेष्ठ परिदृश्य दें? संपादित करें: समस्या परिदृश्य मैं एक फ़ाइल अपलोड करने के लिए उपयोगकर्ता से पूछता हूं। / Li> मैं उस फ़ाइल की जानकारी के आधार पर डेटाबेस को क्वेरी करूंगा। फ़ाइल में सैकड़ों यूनिट हो सकते हैं जिसके लिए मुझे डेटाबेस और प्रॉम्प्ट उपयोगकर्ता से संबंधित इकाइयों को चुनने के लिए पूछना है। / ...

javascript - GM_xmlhttpRequest POST request not working cross-domain -

I'm running a script in Tamtomony, and I use the GM_xmlhttpRequest method to post the POST cross-domain. Although this is not working for me, I get a normal cross-root error in the console: XMLHttpRequest can not load [domain1]. There is no 'access-control-permission-generation' header on the requested resource Access to [domain 2] is not allowed. I understand that the full issue of the GM request method is that it supports cross-domain in contrast to XMLHttpRequest (). So I do not see why this will work because it should be here Here is what I am doing: // match https: // [domain2] // @grant GM_xmlhttpRequest GM_xmlhttpRequest ({Method: "POST", url: "https: // [domain1] /exmaple.php", data: formData, onload: function (feedback) {} console.log (response.responseText);}}) Maybe I have something wrong with me or I have a wrong idea Edit: I think I should keep in mind that the above code should be given to any other common XMLHttpRequest Insi...

c - Program to traverse a m*m matrix in inverse s order -

उदाहरण: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 मुझे कार्यक्रम के लिए निम्नलिखित आउटपुट की आवश्यकता है: 1 2 3 4 8 7 6 5 9 10 11 12 16 15 14 13. के लिए (I = 0; i & lt; m; i ++) {for (j = 0; j & lt; m; j ++) {प्रिंट ("% d", एक [i] [j]); }} कोड का यह टुकड़ा एक सरणी में मैट्रिक्स को प्रिंट करता है लेकिन मुझे उलटा क्रम में इसकी आवश्यकता है क्योंकि यह मेरी प्रोजेक्ट का हिस्सा है। के लिए (int i = 0; i & lt; m; i ++) {if (i% 2 == 0) {for (int J = 0; j & lt; m; j ++) printf ("% d", एक [i] [j]); } Else {for (int j = m-1; j & gt; = 0; j--) printf ("% d", एक [i] [j]); }}

php - In magento got a fatal error while creating new coustmers -

मुझे एक नया आदेश बनाते समय एक गंभीर त्रुटि हो रही है Sales-> ऑर्डर- & gt; नया ऑर्डर बनाएं घातक त्रुटि: 33554432 बाइट्स की स्वीकार्य स्मृति आकार / home / deeplovi में थका हुआ (3072 बाइट आवंटित करने की कोशिश की गई) /public_html/magento/app/code/community/BL/CustomGrid/Model/Grid/Type/Abstract.php ऑन लाइन 383 मेरे होस्टिंग के लिए कोई सर्वर फ़ाइल आकार सीमा नहीं है

java - Disable enhancement for Play Framework model classes -

Is there a way to disable play framework model classes? The reason for this is that I am asking because I want to serial model object in JSON, but as soon as the JSON serializer touches any non-inhalational model, that model will be launched due to an additional database hit and its As a result, Jason will be flooded with unnecessary model objects, I call this code serverConfig.addClass (Model.class) with the model. * and ServerConfigStartup have tried to leave it. Call serverConfig.addPackage ("Model") but none of them work for me EBI requires that the model class be extended If you are not expanding then you can not use model class with EBI. So, you have options, do not use EBI, or do not sort your model objects in JSON. The latter is considered to be the best practice, it is not a good idea to bind your rest data data object to your database models, due to this problem now which you are experiencing - both models are generally different - the database mo...

bioinformatics - Prove that L >= G for Local and Global alignments of a specific function -

I am taking a bioinformatics class in this semester and I have trouble with a specific question from the book. * Considering the two DNA sequential, S and T, define the same length of N and let the scoring function as follows: match = 1, mismatch = -1, indel = -2 value Take that G and L are the scores of an optimal global alignment and an optimum local alignment between S and T, respectively. Prove that L> = G I understand how to find the related alignment of two random scenes, but I am having trouble in proving this. As far as I can say it is true. G will never be more than the LL because the Indal Penalty is so high and the match is not getting ready for it. I had to produce an example to prove that they could be equal, so I know that this is true. So yes, how great a sign will be about this. Well, this site is not doing us homework, but this is a simple question There is a crack on this: / P> We assume that the points that you originally made are valid (about...

java - Spring bean configuration to use singleton or prototype? -

I am using Java 7 and Spring 3. I'm below the classes. Request. Java Public Interface Request {Public Zero doProcess (); } RequestImpl.java @Transportable Public Category RequestImpl applies {request} private string name; Private string era; // Setsers and Gates Public Wide Do Process () {// Usage name and call age and third party class which will secure database in database}} SpringConfig.xml & lt; Bean id = "request" category = "pkg.RequestImpl.java" /> The client will now use RequestImpl as the following. RequestImplreq = (RequestImpl) applicationContext.getBean ("request"); Req.setName ("SomeName"); Req.setAge ("20"); Req.doProcess (); Now my question is do I have to declare the RequestImpl.java scope as a prototype or singleton? Thank you! IMHO you are not working well: data must be separated from process and process ( ) Then doProcess () should be defined doProcess (name, age) or...

flex4 - Read elements from XMLList in flex -

Image
क्या मैं छवि में चक्कर किया है तत्वों को पढ़ने के लिए संभव है मुझे इसकी ज़रूरत है क्योंकि सिस्टम से प्राप्त होने वाली एक्सएमएल सूचीएं गतिशील हैं.उन तत्वों को स्थिर नहीं है.मैं हर तरह के तरीकों का उपयोग नहीं कर सकता प्रत्येक (var आइटम: XML में डीपी) {var element : String = मद @ date.toString;। } मैं हमेशा @date का उपयोग नहीं कर सकता क्योंकि XMLList सामग्री हमेशा बदलती है तारीख, खुले, निकट नाम हमेशा नहीं मिल रहे हैं यह मेरा नमूना XML है निजी var testXML: XML = & LT; मुख्य & gt; & Lt; आइटम का नाम = "एजेंट 1" टैग = "सीपीयू" मान = "39" / & gt; & Lt; आइटम का नाम = "एजेंट 2" टैग = "सीपीयू" मान = "17" / & gt; & Lt; आइटम का नाम = "एजेंट 3" टैग = "सीपीयू" मान = "27" / & gt; & Lt; आइटम का नाम = "एजेंट 4" टैग = "सीपीयू" मान = "39" / & gt; & Lt; आइटम का नाम = "एजेंट 5" टैग = "सीपीयू" मान = "1...

Where mysql stores the password of users -

When we set up a MySQL database system, the system automatically creates a MySQL database that includes db There are several tables, Event, func, host, server, slow_log, user_info etc. By checking the user_info table in , I can choose from the user_info by executing a query like user list and their details; leaving the password but in which table does MySQL store the password of every user? MySQL passwords for users are only stored in MySQL; They are stored in mysql.user table. Password PASSWORD () function. Is washed by default by using

android - Image Share on Facebook using Facebook SDK -

I'm following the tutorial. I only want to share the picture when you select the image from the gallery but I'm getting the Null Pointer exception error. I have a suggestion how I can solve it Thanks. My image sharing code My error It needs to be converted to a byte array and then in your bundle, you have to pass a byte array like this. bundle postpay = new bundle (); Bitmap BMP = "your bitmap"; Bytereon output stream stream = new byteOutStream (); BMP. Commerce (bitmap.compress format.png, 100, stream); Byte [] Biteire = Stream. To Batere (); Postperm. InputBitare ("Images", Bitarere); Eventually you need to set it request request = new request (session, "m / photo", postparamas, Callback);

ruby on rails - How do I view the last X hours in my production.log in console -

I am on a very poor Internet connection and have to check the only today section> File in the production.log console. How can I do this? As specified in the comment, Can you pull the line? You can use it, tail -n 50 production.log get the previous 50 line To (or) If you want, then production.log From tail -f production.log will monitor the production.log file for the embedded data.

ios - UITableViewCell separator lines appearing during editingstyle -

UITableViewCell के साथ cell.backgroundView, और self.webSiteTableView.separatorStyle = UITableViewCellSeparatorStyleNone, जब मैं संपादन शैली में मिलता है, रेखा के नीचे दिखाई दिया लाल पृष्ठभूमि के साथ हटाएं बटन [self.webSiteTableView setSeparatorInset: UIEdgeInsetsMake] सेब के बीच कोई रेखा नहीं, केवल इसका एक हिस्सा बटन के नीचे दिखाया गया है जब मैं संपादन शैली में जाता हूं .. (0, 0, 0, 0)]; Self.webSiteTableView.separatorStyle = UITableViewCellSeparatorStyleNone; [[यूआईटीबलव्यू उपस्थिति] सेटसेपरेटर इन्सटः यूआईईडगेइन्ससेटज़िरो]; Self.webSiteTableView.backgroundColor = [UIColor स्पष्ट कॉलर]; Cell.contentView.backgroundColor = [UIColor स्पष्ट कॉलर]; Cell.backgroundColor = [UIColor स्पष्ट कॉलर]; [सेल सेटबैकग्राम रंग: [UIColor clearColor]]; यह अभी काम नहीं कर रहा था ... रेखा अभी भी वहां है ... क्या इसे गायब करने का कोई तरीका है? Thx! UPDATE : मैंने स्वयं की कोशिश की.वेबसाइटइटव्यू। बैकग्राउंड रंग = [UIColor redColor]; बारी बारी से विभाजक रेखा गायब हो गई .. समस्या यह है कि सेल की ...

winapi - How to handle double click exactly? -

I want to execute a double click by clicking on the left mouse button twice. Between 2 click-time, I sleep 100m SendInput (LEFT_CLICK ...); Sleep (100); SendInput (LEFT_CLICK ...); It works fine in my PC, but may not work correctly in the virtual machine, there is a delay time when the machine does the "SendInput" function I delete "sleep (100)", it only clicks 2 times how to fix double click in this case Please do me this Thank you, BTW You must specify that you In the atmosphere Working and expanding your code a little bit Using SendInput is an option, I do not know what you are actually trying to do, but I'll give you two more options to try to emulate clicks Something like this (I code in Python, but this should be the same idea): def leftClick (x = 0, y = 0): win32api.SetCursorPos ((x, y )) # Where you click on win32api.mouse_event (win32con.MOUSEEVENTF_LEFTDOWN, x, y, 0, 0) # to move the cursor Get Mouse Event Win32api.mouse_eve...

mysql - java.lang.RuntimeException: java.sql.SQLException: Field 'UserName' doesn't have a default value -

I am developing a web application ... which will be the list of users requesting registration ... We accept that all the details should be taken from the register table to enter the table ... This is my servlet: ClientApproveService = New ClientApproveService (); Approve.clientApprove (); This is my service: public class ClientApproveService {Public Zero Client Configure () {ClientApproveDAO cad = new ClientApproveDAO (); Datasource datasource = new datasource (); Cad.setDataSource (data source); Cad.insertClient (); }} And this is my DAO: public class ClientApproveDAO {Private Data Source Datasource; Public Zero SetDataSource (Datasource Data Source) {this.dataSource = DataSource; } Connection = null; Statement made = zero; Results set rs = null; Public Zero Insert Client () {try conn = dataSource.createConnection (); Prepared State Place ps = conn.prepareStatement ("Login, ID, Firstname, LastLameM, gender, category, dateofrth, age, address, country, state, c...

c# - Sorting based on the keys in dictionary -

Image
कृपया उसे चित्र संलग्न करें। ls एक शब्दावली & lt; स्ट्रिंग, स्ट्रिंग & gt; है। मैं कुंजी के आधार पर सॉर्ट करना चाहता हूं लेकिन अगर चाबियां हैं तो 7020_1, 7020_23, 7030_5 7020_8, 7030_1। मैं इसे 7020_1,7020_8,7020_23,7030_1.7030_5 के रूप में व्यवस्थित करना चाहता हूं। मुझे समाधान पता है। यहां एक आसान समाधान है। शब्दकोष & lt; स्ट्रिंग, स्ट्रिंग & gt; D = dic.OrderBy (x = & gt; int.Parse (x.Key.Split ('_') [0]))। तब (x = & gt; int.Parse (x.Key.Split ('_') [1]))। ToDictionary (j = & gt; जे। के, जे = & gt; जे। वेल);

bit manipulation - Java: Why is it called bitwise exclusive or? -

I am trying to understand how bitwise exclusive or works in Java Example For: false ^ false = false true ^ true = false true ^ false = true false ^ true = true According to some terms here In java, the size of boolean is jvm dependent. Usually boolean can be displayed on the stack with 32 bits , in the 8 bits array. So, why is it called bitwise if it is more than a byte on the stack? According to the java language specificity, there is no boolean bitwise operator, only more . 15.22.1 Integer bitwise operator & amp;, ^, and | When both operators of operator and, ^, or | There is a type of convertible (§5.1.8) of a primitive integral type, the binary numerical promotion is done on the first operand (§5.6.2). Bitware operator type of expression; For more, the result value is bitwise and operable values. For ^, the value of the result is a bitwash exclusive or operand value. | For this, the result value is included in bitwise or 15.22.2 B...

jquery - how to simpify this javascript? -

यदि (! त्रुटि हुई है) {info.show (); error.hide (); } और {info.hide (); error.show (); } मैं टॉगल का उपयोग नहीं कर सकता। मैंने फ़ंक्शन शो को पास करने या चर को छुपाने का प्रयास किया और फिर इसे निष्पादित किया, लेकिन यह किसी कारण के लिए काम नहीं करता है मुझे एक जेएस त्रुटि मिली। आप इस तरह से कुछ कोशिश कर सकते हैं: जानकारी [errorHasHappened 'छिपाएं': 'शो'] (); त्रुटि [errorHasHappened 'शो': 'छिपाएं'] (); लेकिन यह एकमात्र विकल्प है जिसके बारे में मैं सोच सकता हूं, जो कोड को छोटा बनाता है। इस तरह से कोड को बनाए रखना आसान नहीं होता है, हालांकि।

php call constant with using a variable -

// include.php परिभाषित करें ('OPTION_0', 'जनसंख्या का सार'); परिभाषित करें ('OPTION_1', 'पासपोर्ट अनुरोध / विस्तार'); परिभाषित करें ('OPTION_2', 'अनुरोध लॉगिंग रियायत'); //form.php & lt; चुनें नाम = "सॉर्ट" & gt; & Lt; विकल्प मान = "0" & ​​gt; & lt;? Php echo (O_0)? & Gt; & lt; / विकल्प & gt; & Lt; विकल्प मान = "1" & gt; & lt;? Php इको (O_1)? & Gt; & lt; / विकल्प & gt; & Lt; विकल्प मान = "2" & gt; & lt;? Php इको (O_2? & Gt; & lt; / विकल्प & gt; & lt; / select & gt; //show.php extract ($ _ POST); // चर $ सॉर्ट का मान है 1,2 या 3 प्रतिध्वनि ("यह आपकी पसंद है"); गूंज (OPTION_। $ सॉर्ट); // मैं निरंतर उदा का उपयोग करना चाहता हूं जैसे OPTION_2 मैं मान गूंजना चाहता हूं मिलान के निरंतर। तो जब मैं form.php में दूसरा मान चुनता है तो यह 1 के मान को सॉर्ट करता है, अब मैं स्थिरांक OPTION_1 का उपयोग करना चा...

IPython | Unix commands not working in script but working in command line interpreter -

When I put them in test.py and runs it, gives me an error, but when I command them ". pyvar = 'Hello World'!" A Python variable: {pyvar} "" jitu @ jitu-pc: ~ / ipython / python $ ipython test.py file "/ home / jitu / ipython / python / test.py", line 2! Echo "A Python variable: {pyvar}" ^ Syntex error: invalid syntax Any idea why this is not working? .py The file is a Python script, they are supposed to be a pure python, Ipython will not try to do some "magic" on this. If you want to use the syntax constructive Chinese IPHONE, then you should name your script .py above the pure Python syntax Note that all iPython syntax Chinese Can be converted into a pure dragon (cf % hist versus % hist -t ) which will be valid dragon syntax, but still need to use an IPython instance is.

php - Prepared SQL Statement returning blank from Database -

यह कोड है, निम्नलिखित (स्पष्टीकरण बाद में है): & lt; php error_reporting (E_ALL); ini_set ( 'display_errors', 1); $ Uname = $ _POST ['uname']; अगर ($ uname! = "") {$ Mysqli = नया mysqli ('localhost', 'root', '', 'dota_site_test'); यदि (mysqli_connect_errno ()) {गूंज ("connetion त्रुटि:"। Mysqli_connect_errno ()); बाहर जाएं(); } $ Stmt = $ mysqli- & gt; तैयार ("प्रयोक्ता नाम का चयन करें उपयोगकर्ता नाम कहाँ है?"); $ Stmt - & gt; बाइंड_परम ("s", $ uname); $ Stmt - & gt; निष्पादित(); $ Stmt - & gt; bind_result ($ unamecheck); अगर ($ stmt- & gt; num_rows & gt; 0) {गूंजती "लिया:"; गूंज "नाम है"। $ Unamecheck; } Else {गूंजती "फ्री:"; गूंज "नाम है"। $ Unamecheck; } $ Stmt - & gt; बंद करे(); $ Mysqli - & gt; बंद करे(); }? & Gt; मुझे यकीन नहीं है कि समस्या कहां है, लेकिन जब मैं नीचे हूँ, तो गूंजने की कोशिश कर रहा है ...