Posts

Showing posts from June, 2013

visual studio 2012 - Compile error in a short OpenGL code: 'PFNGLBINDPROGRAMARB' : undeclared identifier -

संक्षिप्त कोड इस प्रकार है: #include & lt; windows.h & gt; # शामिल करें & lt; GL / gl.h & gt; # शामिल करें & lt; जीएल / glext.h & gt; Int main (int argc, char ** argv) {PFNGLBINDPROGRAMARBPROC glBindProgramARB; glBindProgramARB = (PFNGLBINDPROGRAMARB) wglGetProcAddress ( "glBindProgramARB"); } जब मैं संकलित करता हूं, तो मुझे एक संकलन त्रुटि मिलती है: त्रुटि C2065: 'पीएफएनजीएलबीआईएनआईपीएनआरपीआरएएमआरबी': अघोषित पहचानकर्ता। मैंने जांच की है हेडर फाइल glext.h पर PFNGLBINDPROGRAMARBPROC इसमें है (रेखा 2922)। मुझे इस बारे में पता नहीं है कि मदद के लिए यहाँ मेरा प्रश्न पोस्ट करें। मैं विज़ुअल स्टूडियो 2012 का उपयोग कर रहा हूं और मैंने शामिल निर्देशिका सेटिंग्स को चेक किया है अन्य सिस्टम जानकारी: विंडोज 7 64 बिट, नवीनतम चालक के साथ एनवीडिया गेलफ़ोर्ड कार्ड स्थापित। यदि आपको किसी भी अन्य संबंधित जानकारी की आवश्यकता है तो कृपया पूछें। यह एक संकलन त्रुटि है, लिंक त्रुटि नहीं है, इसलिए उसका एक्सटेंशन फ़ंक्शन glBindProgramARB (यह मेरे सि...

javascript - Prevent jQuery slidedown menu from pushing down elements in other columns? -

My current responsibility is slide down the Site menu. I intend to do this, because the window grows so that the objects can be arranged in columns (1,2 and 3). It's working a lot, but when I bow down one element in the first column, the elements of the first column also go down. Sometimes the elements jump from one column to the other. I just need a general idea of ​​what to do? Menu items are not automatically menu ready Give your column the relative position with some padding and your When the menu is full, you can position your menu at the top of the text in the column, and when you slide toggle () .col {padding: 20px; Status: Relative; } Menu {status: absolute; Top: 0; } To show this action, is

xml - Xpath in mule anypoint studio -

I need to use an option router in the root message based on a specific field value in the input XML. Also using the latest version of the studio I am not able to compare XPath and compare prices in a specific area and then converting the route accordingly. How did someone compare me to the capture field in XPSath to UPS? Here is the sample XML file: I need to retrieve the Career field from the XML given above. I am # [xpath ('/ deliver-order / tracking-data / carrier' == 'UPS'] Like I'm using xpath expressiosn in the router me gt; ; got the value of it and was printed from the logger to the console ... also the message was rooted according to the field value .. Here I did what I did: - I xml File and my Valid: "Context": & lt; file: connector name = "File_Global" AutoDelete = "true" Streaming = "true" Connection = "true" Doctor: name = "file" / File: Inbound-Endpoint ResponseTi...

Error returning a list of user-defined objects from a function in C++ -

पृष्ठभूमि मैंने एक वर्ग Str उस निर्देश के उद्देश्यों के लिए स्ट्रिंग ऑपरेशन की नकल करता है वर्ग Str सार में वर्णों की एक सरणी है। मैंने एक फ़ंक्शन makeList बनाया है जो एक Str ऑब्जेक्ट प्राप्त करता है, Str वस्तुओं का push_back का उपयोग करके एक सूची बनाता है और सूची लौटाता है। मैं आबंटक का उपयोग कर रहा हूं, लेकिन मैंने कड़ा कर दिया है मेमोरी प्रबंधन को बनाए गए पात्रों के लिए पर्याप्त मेमोरी आवंटित करना। समस्या संकलन, लिंक और रन-टाइम कोई त्रुटि उत्पन्न नहीं करता। सूची का उपयोग करके cout । समस्या यह है कि सूची में ऑब्जेक्ट में कचरा इनपुट पहले ~ 10 वर्णों को अधिलेखित करते हैं, जब मुख्य में देखे जाते हैं body। मैंने यह भी सत्यापित किया है कि Str मैं बना रहा हूँ डिफ़ॉल्ट डिस्ट्रक्टर के माध्यम से नष्ट हो रहा है। मैंने समस्या को दोहराने के लिए कोड की न्यूनतम राशि शामिल की है। गैर-वर्ग कोड: सूची से & lt; Str & gt; मेनलिस्ट (कॉन्स्ट स्ट्रल्स) {सूची & lt; str & gt; सेवानिवृत्त; ret.push_back (रों); Cout & lt; &...

java - What order do threads run (execute) after being submitted to ExecutorService? -

There is a better way of writing files to safeguard (in cases where files can not be all the files Or compared to syncing the file author in each thread) I read some threads similar to this topic, but they start focusing on a file in opposition to multiple files. Ex There are 20 threads that write (which means that it uses a method that creates the file author in the file and then files it with a try-hold, etc. Writes for); Let's write 10 files of thread, write 5 threads fileB, write 4 threads on fileC, and write 1 thread in D.D. By synchronizing the method, threads that want to be written in separate files, before proceeding with it, to wait for the previous thread to finish it, I think synchronizing the file author is very similar. Or am I wrong? If I have a separate thread thread (from the main application) that writes in a file, then do they execute in the order submitted to the executable service with 1 thread (run) Do you? In the main application, I will submit ...

assembly - ARM NEON my calculation result when there are negative numbers is incorrect -

I'm trying to calculate the use of neon in assembly ((200 * (53-255) / 255 ) + 255, which should be approximately 97% I have tested here on the Dual Core Cortex-A7 ARM CPU Tablet and the result is 243 which is not true. How do I apply this 97 should be done to get the correct result? d2 included 200.200.200.200.200.200.200.200 d4 included 255.255.255.255.255.255.255.255 d6 53,53 included, 53, 53,53,53,53,53 vsub.s8 D8, D6, D4 (53 - 255 results D8 = 54,54,54,54,54, 54,54) vmull.s8 q5, d8, d2 (54 * 200 results Q5 = 244,48,244,48,244,48,244,48,244,48,244,48) vshrn.s16 D12, divided by 255 result in D12 = 244,244,244,244,244,244,244,244) vadd.s8 d5, d4, d12 ( Last result d5 = 243,243,243,243,243,243,243,243) After 243 is absolutely correct. Alpha channel is an unsigned 8bit value, you should use u8 or u16 s8 and s16 . While for standard arithmetic, where the width is the same, it does not matter, it is a completely different story for multi-long running. A...

php - wp_insert_post auto schedule or post based on date -

& lt;? Php // आज की तिथि 2014-07-27 $ title = "title"; $ सामग्री = "सामग्री"; $ तिथि = "2014-07-30"; $ My_post = array ('post_title' = & gt; $ title, 'post_content' = & gt; $ content, 'post_status' = & gt; 'पोस्ट', 'पोस्ट_डेटा' = & gt; $ date, 'post_author' = & gt; 1) ; $ Post_id = wp_insert_post ($ my_post); ? & Gt; आज की तिथि (या पुराने दिन) और ऑटो शेड्यूल पोस्ट कब पोस्ट करें? ps: आज के लिए (या पुराने दिन) हो सकता है कि यह कोड सही तरीके से काम करे, लेकिन जब मैं कल या अगले दिन की तिथि (यदि संभव हो तो कृपया नमूना कोड दें) को ऑटो शेड्यूल के लिए कैसे करें अपडेट प्रश्न: मेरा क्या मतलब है कि कैसे wp_insert_post भविष्य की तारीख (अगले दिन / अगले महीने / अगले वर्ष या विशिष्ट तिथि) के लिए शेड्यूल पोस्ट करें क्योंकि जब मैं 'पोस्ट_डेट' => "2015-08-30" को सेट करने की कोशिश करता हूं, तो आज की तिथि के साथ पोस्ट क्या रखता है मैं चाहता हूं कि पोस्ट शेड्यूल पोस्ट क...

javascript - Why do white lines appear in my canvas when rendered on my iPad (Safari and Chrome)? -

I am updating a line with a canvas while using JS. On my laptop, the canvas renders the canvas as expected, whenever I refresh, white horizontal lines are displayed in the canvas on different lines in every row. I If I zoom in or out on my iPad then the lines get out why this is happening but any thoughts and how can I work around it? I have tried to overwhelm the browser window again through several ways. It has not changed anything. Here is the code: function pentrev (y) {if (y == 100) return; Var c = document.getElementById ("myCanvas"); Var ctx = c.getContext ("2D"); Var image data = ctx.createImageData (100, 1); Var i = 0; {ImageData.data [i] = x / 100 * 255 for (x = 0; x Here is an alternative solution that appears to work: c.style.zoom = c.style.zoom == "100%"? "100.0001%": "100%"; After each update.

css - Buttons Missing in Firefox Bootstrap 3 Modals -

I do not understand why my buttons in Firefox are not displaying properly Chrome and in Internet Explorer Do the work. You can see my problem here: test.loginsm.com "Social" buttons are not being displayed while clicking on "Sign In" and "Registration". This problem is typical for appearing in Modals. Boot (more or less): Any help would be greatly appreciated! The problem has shown that Serlite gets gears while roaming in my head. It was turned on, especially a social button remover. It looks like Facebook or Twitter does not like but favorite Google+! Just disable it and show my buttons! Thank you!

javascript - Parse master key cloud code following users -

I am preparing a simple social network app for iOS with Pars and I am currently working on relationships , Such as followers and following are my followers and in my data browser the following columns are saved as an array so that I can save all the user names. So it is that I am having trouble with this: Say that the current user is looking at user's profiles and clicks, I need to save the name of the current user in the user's follower array which he is looking at. So far as I know that I can not do this on the client side, and in some way it is not a good idea for ether for safety reasons. So I want to try using the master key and cloud code to add every user's name to their proper array. I have never used the cloud code before and I have to make sure that this is the best way to do this. I establish the cloud code, I do not know where to start. Any suggestions would be appreciated! I will start by creating a new function in main.js in my cloud, code folder just...

ios - Trying to create a custom initializer method -

So I know there are a group of such questions, but none of their solutions are helping me is. I'm using the storyboard, starting with this saying so that I initWithCoder instead of initWithNibName: . We got out of that way, so, just want to pass in the second view with an object custom anilizer. Then in my second view I will have the code like this: - (id) InitWithMyLifeChangingObject: (MagicType *) Object {// Apparently it's important self = [Super init]; // Some things with my magical object / you know the self-return story; } And in the form of the story you need to call your global Init: [second class alloc] initWithMyLifeChangingObject: object]; but initWithMyLifeChangingObject: is not recognized and a build error tells me that it does not exist ... so what should I do.

ios - Pass Date Picker date back to View Controller to show Date in label -

I've searched a lot of questions on how to do this, and I'm just coming. I have ViewControllerA and ViewControllerB. ViewControllerB NSDate UIDatePicker back for ViewControllerA . I'm fine until trying to put that code> NSDate TableViewCell it's related. Can you help? ! Thank you ViewControllerA - (zero) addItemViewController: (EXEDurationPickerViewController *) Controller didFinishEnteringItem: (NSString *) Item {NSLog (@ "Back to ViewControllerB% @ ", item); } Item is the date selected from ViewControllerB How do I get to show it as a label in this table view? Use representative to send date or other Option Notification View this to ViewControllerA @interface Viewer: UIViewController {NSIndexPath * selectedIndexPath; } @end - (zero) viewDidLoad {[[NSNotificationCenter defaultCenter] addObserver: self selector: @selector (receiveNotification :) name: @ "dateSend" object: zero]; } - (zero) Rec...

android - Send message body and phone number to Viber -

I try to get messages and phone numbers in my app and then send a message to that number, I want to send a message via Viber application, I can send a message with this code: intent = new intention (int. Action_snnd); Intent.setType ("text / plain"); Intent.putExtra (android.content.Intent.EXTRA_TEXT, "Test Test Test"); Intent.setpackage ("com.viber.voip"); StartActivity; How can I send a phone number to Viber? There are two ways to send messages using the intents for Viber. Option A - Unfortunately sms_body will not be filled up. But the dialog will open directly with the specific contact: intent smsIntent = new intent (Intent.ACTION_SENDTO); SmsIntent.addCategory (Intent.CATEGORY_DEFAULT); SmsIntent.setPackage ("com.viber.voip"); SmsIntent.setData (Uri.parse ("SMS: +1001002003"); SmsIntent.putExtra ("address", "+1001002003"); SmsIntent.putExtra ("sms_body", "body text"); St...

bash - Sed cannot convert uppercase to lowercase -

I want to change the "email address" variance in lowercase in a JSON message. I tried to use sed but failed, because \ l option does not work for me, am I missing something? a = "{" id ": null," enabled ": true," password ":" "," email ":" foo@bar.com "," last name ": "Foo", "First Name": "Eligible"} "Allo $ a | Sed -e / s Email: [[Graph:]]. *, The last / \ L & g / ' returns the result: {id: blank, enabled: true, password :, {l} Email: Foo @ Bar Com, last name: foo, firstname: lol} I want the result: {ID: blank, enabled: true, password :, email: foo @ Bar.com, lastName: foo, first name: lol} I think That you do not have GNU sed and therefore do not have access to \ l . Instead, try Perl: "$ a" echo Perl -pe 's / (email: [[graph:]] *, last) / \ L \ 1' '

php - How to hide all the comments in Zend Studio? -

I wonder if there is a hotkey that can hide all the comments '//' and '/ * * /' is? So the real effective code is clear. Where else can you find the Zend Tutorial? In Zend Studio, there is no way to hide the mark '/ **'. In other IDE, you can hide

linux - Sending a mail via php script in ubuntu -

I am trying to send my gmail id to Ubuntu via php script but it is unable to send my code & lt; Html & gt; & Lt; Head & gt; & Lt; Title & gt; Send mail & lt; / Title & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt ;? Php $ name = $ email = $ query = ""; If ($ _ server ["REQUEST_METHOD"] == "POST") {$ name = test_input ($ _ POST ["name"]); $ Email = test_input ($ _ POST ["email"]); $ Query = test_input ($ _ POST ["query"]); If (mail ("abc@gmail.com", "subject", $ query, "sender: $ email \ n")) {resonant "send email"; } Else {resonance "do not send"; }} Function test_input ($ data) {$ data = trim ($ data); $ Data = stripsash ($ data); $ Data = htmlspecialchars ($ data); $ Return data; }? & Gt; & Lt; Form method = "post" action = "& lt ;? php echo ($ _SERVER [" PHP_SELF "]) ;; & gt; ...

javascript - Trouble referencing JSON imported object outside of FOR -

I am having trouble referencing my imported JSON data. If I run the loop, then I get == 1 and the output works if I try to refer it outside of the four loop, then it fails with the error of "Uncort Type Error": the property Can not read 'Tname' undefined " This works ... For (var i) in cities {if (i == 1) { Ctx.fillText (towns [i] .name, 0, 0);}} This fails with the next line "Uncort Type Error": 'undefined' Tname 'property Do not read This additional line is written directly after the loop above. ctx.fillText (Towns [1] .Tname, 0, 0); I have tried many formats but all are unsuccessful. "Towns [1]" is the production "[object object]". For those people, this is a snippet from the city. Jason: {"Tid": "2057277", "Tname": "York"}, {"Tid": "2057575", "Tname": "Yanchep" }}} This is JSON for the cities [code]: var cities []...

java - how to parse a JSON string into ObjectNode in Jackson? -

First of all, can anyone explain, what is the difference between the object node and the jesenand, and where did they use it? Then what can I do if I want to convert a JSON string to ObjectNode? You can: object mapper mapper = new object On mapper (); JsonNode realObj = mapper.valueToTree ("{\" k1 \ ": \" v1 \ "}") JsonNode is a super class of this object node. You can find differences in the API.

parse.com - Dynamic Websites on Parse -

I am trying to explain how the dynamic websites work on parses and I have followed the instructions given here. :. To establish a basic example Clouds / ideas / hello.ejs next, I used to have clouds / ideas / mything.ejs and used them that works from app.js and all this works. Now, for example, I would like to show the number of records in MyClass on Parse. In other words, inside my dynamic website, I want to display information related to pars content on DB. How can I do that? Obviously I need to include some DB queries at some point, but is there any samples? itemprop = "text"> Here is an example snippet handles a GET request for this / mypage , It creates one on execution but returns the record set that matches the query. On completion of the query, we set the count or error on the response using res.set (). After this you can use EJS to display the count or error. app.get ('/ myPage', function (request, race) {var query = new Parse.Query (...

Confusion in unsigned keyword in C/C++ -

Consider the following two programs. My question is in the first program unsigned keyword print -12 but I think it should print 4294967284 , but it should be sent to Does not print for% d Specifiers prints it for % u specification but if we look at another program, then output is 144 where It should be -112 There is a mess about some code that I can not find. Any help friend! #include & lt; Stdio.h & gt; Int main () {unsigned int i = -12; Printf ("i =% d \ n", i); Printf ("i =% u \ n", i); Return 0; } From the top I found this link: #include & lt; Stdio.h & gt; Int main (zero) {unsigned letter A = 200, b = 200, c; C = A + B; Printf ("result =% d \ n", c); Return 0; } Each printf forms the argument specification of something A special type of requirement is "% d" requires a type of argument int ; "% u" requires a type of logic unsigned int . There is full responsibility for passing t...

javascript - how display input fields and required them when selected option with jquery -

मैं इस तरह एक फार्म का उपयोग करता हूं: & lt; form id = "clac" क्रिया = "#" विधि = "पोस्ट" & gt; & Lt; select onchange = "func_type ()" नाम = "t_person" id = "t_person" class = "t_person_class" & gt; & Lt; विकल्प मान = "0" चयनित & gt; व्यक्ति चुनें & lt; / विकल्प & gt; & Lt; विकल्प मान = "1" & gt; एक & lt; / विकल्प & gt; & Lt; विकल्प मान = "2" & gt; दो & lt; / विकल्प & gt; & Lt; विकल्प मान = "3" & gt; तीन & lt; / विकल्प & gt; & Lt; / चयन & gt; & Lt; इनपुट आईडी = "t_person_name1" & gt; & lt; br / & gt; & Lt; इनपुट आईडी = "t_person_name2" & gt; & lt; br / & gt; & Lt; input id = "t_person_name3" & gt; & lt; br / & gt; & Lt; इनपुट प्रकार = "सबमिट करें" मान = "ठीक है" & gt; & Lt; / ...

c++ - swig warning message with vector.i and vector of classes -

I use swig to wrap Ruby code to C ++ classes. Some of my classes return std: vector to other classes, so I use std_vector.i for this. % include "std_vector i" namespace study {% template (vector string) vector & lt; String & gt; % Template (vector-field) vector & lt; Truckborough :: Field & gt ;; % Template (vector structure) vector & lt; Truckborough :: Structure & gt; % Templates (vectornem) vector & lt; Truckborough :: Enem; } Enum and composition for classes I have such warnings: parser.cpp: 2781: 9: Warning: This' Magnet's The destination 'call for the dynamic class is an indicator' truckboris :: ANUM '; Vtable indicator will be overwritten [-DrVenture-class-mamacus] memeset (v_def, 0, size (type)); ^ Parser.cpp: 2807: 66: Note: Member Function 'swig :: traits_as & lt; TruckBoris :: Enum, swig :: pointer_category & gt; :: as requested here 'back traits_as & lt; Types, typographical sympto...

javascript - how to set transition to mouse scroll -

I would like to add a transition to my web page with custom scrolling (I can override lines at a fast-to-normal rate I am). My code is following - & lt; Html & gt; & Lt; Top & gt; & Lt; Script & gt; Var MOUSE_WHEEL_GAIN = 1000; Function On-Mouse Volume () {window.scrollTo (0, document.body.scrollTop - event.wheelDelta / 120 * MOUSE_WHEEL_GAIN); Var e = window.event; E.returnValue = false; E.cancelBubble = true; return false; } & Lt; / Script & gt; & Lt; Top & gt; & Lt; Body ONMOUSEWHEEL = "onmouse violet ()" & gt; & Lt; Script & gt; (I = 0; i & lt; 20; i ++) document.write ("& lt; p>" + + + + "For the mi, I am working for my work, But for some time he does more work to do work to work. No one does the work to do any kind of exercise, which can be used to avoid leaving him. There should not be any information about any kind of work. Ltorum. "); & Lt; / Script & gt; & Lt; ...

html - How to Align Sidebar elements with respect to content id's -

Image
OK, I want to combine the sidebar elements in relation to the main content, which can be mentioned only after one Instead of stacking one, the id is mentioned in the sidebar. I want to mention the ID to align the sidebar elements with some id tags mentioned in the main post content. In the image it should look like the basic structure: I also want to combine the sidebar element with content when using the media queries, the sidebar disappears in the mobile platform, so that these elements will not disappear with the sidebar in the mobile platform. I can align the stuff but I do not know how to do this kind of targeted alignment with respect to the IDs or classes. One example would be very useful (JSfield) Many thanks in advance :)

html - Parse value from JSON to url -

I created a small script that creates URLs from a text box value such as: & Lt; Input id = "cod_meio" name = "cod_meio" type = "text" value = "" & gt; & Lt; Input id = "inspecionar" name = "inspecionar" onclick = "location.href = 'http: //hyves.worldofalice.com/jsonp.php? M =' + document.getElementById ('cod_meio'). Value;" type = "Button" value = "inspector" & gt; This will open the URL in a new window, but this is not what I want! Can I get a string from generated JSON? And then put in another url? ("Atrial", "font collar": "008000", "fontWeight": "", "message", "message" normal "," body ":" hi: d "}]}); For example, only the message of the body, and then put it Is it possible and someone is able to help me?

python - Regex url pattern for django -

I need to define the URL pattern for the URL below http: // Myurl: 8080 / authentication / agent / newpassword /? Reset Powered = Text Value and AggressCode = Text Value I tried the following, but I have 404 url (r '^ What I'm doing wrong here. / P> The message receiving the error "Received / Authentication / Agent / New password / Reset paced = text value and agentcode = text value HTTP / 1.1 "302 0 You match query string with Django url pattern Use the following pattern: url (r '^ authentication / agent / newpassword / $', password validation), and in the view, use the request to get the GET parameter: defect password verification (request): reset password = request.GET.get ( 'Resetpassword', '') agentCode = request.GET.get ('agentCode', '')

android - preform ontouch over two ImageView in overlay? -

Image
My problem occurs when I click on both intersection spheres. Preform click I need an image preform, then when I click on the intersection area, the View view only priority. Public Boolean On-Touch (see V, Motion Event Event) {// Todo Auto-Generated Method Stub v.performClick (); // View Image 1 if (v.getId () == RID.Card1) {If (! Cardflag [0]) {Animation A = Animation. Anamagam (main activity. This, R. anem. AmvuP12); V.clearAnimation (); V.setAnimation (a); }} // ImageView2 if (v.getId () == RID.Card2) {if card! ({Cardflog [1]) {Animation A = Animation. Anamination (main activity. This, R. Anime, Ampup 10); V.clearAnimation (); V.setAnimation (a); } return false; } try it public boolean on-touch (see V, Motion event event) {/ TODO Automatically generated method stub v.performClick (); // View Image 1 if (v.getId () == RID.Card1) {If (! Cardflag [0]) {Animation A = Animation. Anamagam (main activity. This, R. anem. AmvuP12); V.clearAnimation (); V.setAnimation (a);...

php - Rest confusion in making apis -

People are new to this web area .. I would like to know how to create APIs. For example Web APIs Like facebook api , youtube api etc. I have heard that Web API is done through rest . I have no information in it and I do not know I know that the framework had already come with an API. For example, Symphony API I have three questions ol> what rest is used to create a web API can be done ?? Is there any difference in creating framework APIs and web APIs ?? is yes, use of web applications It has no relation to using the API to make front-facing developers to separate themselves and their code from the actual logos. This means that people can make iOS, Android and HTMFS apps without worrying about business logic. Yes, the API means that your application interacts with the framework, which usually happens inside your application. / Li> No - I mean the interface with the second example in the API.

AngularJS is not updating a select after an option was deleted -

Not updating the options of a selection box after the corner is removed. I have to refresh the view to see the updated options. Thank you My view form (ng-controller = "formumvustadent controller", name = "formadministrationform", enlidet) div.combine label.default.top (for = "Student") Select a student. Default (ng-model = "student.id", ng-option = "s.id as s.name for students in s") option (value = "") I would like to remove ... div. Submit Controller My Controller App Controller ('FormRemoveStudentController', [ '$ Scope', '$ http', function ($ amount, $ http) {$ scope.student = {}; $ scope.students = []; var setStudents = function (data) {$ Scope.students = data. Students || []; console.log ("Students updated.")} Error students = function () {$ scope.students = []; console.error ("database Reverse ");} $ Http.get (url) .sevate (set students) .Rar (error); $ scope.r...

html - getting CSS/browser forced new line with javascript -

I've found a text like this: And then the browser (due to width etc) presents it like this: One day I went to the park and then ate the apple Then, with which [escape] character, I should get a broken line? If the line was broken with , then it was easy, but now it is not using any HTML tags to do this. & lt; P & gt; One day I went to the park and & amp; Nbsp; Then & amp; Nbsp; Eat & amp; Nbsp; & Amp; Nbsp; Apple. & Lt; / P & gt; "& amp; Nbsp;", (non-line breakable space) when used to create a space, then produces that behavior

mysql - Transactions in nodejs -

I have two questions that want to run inside the transaction rollback var mysql = Need ('my sql'); Var connection = mysql.createConnection ({host: "host", user: "user", password: "pass"}); Var query1 = "Enter table 1 values ​​(1,2,3)"; Var query2 = "update last_update set date = now ()"; Connection.beginTransaction {if (err) {error err;} connection.query (query1, function (mistake, result) {if (err) {connection.rollback (function () {err err;}); }};) Connection.query (query2, function (error, result) {iframe} {connection.rollback (function () {err err;}}}}})}}; When I run it, then there are no errors and no queries come out If you start the transaction, then you also have to do it - and, nothing will be updated. You need to execute the following, but both questions After: connection.commit (function (err) {if (err) {connection.rollback (function () {err err;});} Console.log ('Success! ');}); To know ...

python - How to send a POST request with JavaScript XMLlhttpRequest to Google App Engine? -

I'm the one on Google App Engine. I would like to send the XML XMLhttpRequest to the XML script. but I jQuery solution HTML: & lt; Form action = "javascript: SendMessage ();" & gt; & Lt; P & gt; User: & lt; / P & gt; & Lt; Input value = "" name = "user" id = "user" & gt; & Lt; Br> & Lt; B & gt; Comment here: & lt; / B & gt; & Lt; Div & gt; & Lt; Textarea id = "message" name = "message" rows = "3" cols = "60" & gt; & Lt; / Textarea & gt; & Lt; / Div & gt; & Lt; Input type = "submit" & gt; & Lt; / Form & gt; & Lt; Div id = "result" & gt; & Lt; / Div & gt; Javascript: & lt; Script type = "text / javascript" language = "javascript" & gt; Var url = window.location.href; Var element_id = "my_first_element"; Function ...

vb.net - How do I "Cancel an event"? -

itemprop = "text"> I have two DateTimePickers dtpDateFrom and dtpDateTo . I have already codified a conditional statement that if I get an error message, I will get an error message earlier than the DTPDTEO DTPDAT, through its value-added event. The change applies. Example: dtpDateFrom = 2 July dtpDateTo = July 3rd If I DtpDateFrom on 4th of July> error message + without altering July 4 control in your code where you fail to put your validation in e.cancel = true private sub dtpDateFrom_Validating (ByVal DtpDateFrom.Validating this form as System.Object, ByVal E System.ComponentModel.CancelEventArgs) as dtpDateFrom. Value & gt; DtpDateTo.Value then messagebox.show ("must be shorter than date") e.Cancel = True 'Validation failed. End if ending sub

javascript - Responsive CSS div positioning priority -

First of all, I would like to thank the members of this community for the help they received in the last few months. I did not have any projects, which I finalized without your tips and tips. I have now found a problem in a responsive layout where I need your help: I found a layout like this: & lt ; Div class = 'outer' & gt; & Lt; Div class = 'sidebar_links' & gt; Divi 1 & lt; / Div & gt; & Lt; Div class = 'mitte_rechts' & gt; & Lt; Div class = 'd2' & gt; Div2 & lt; / Div & gt; & Lt; Div class = 'd1' & gt; Divio 3 & lt; / Div & gt; & Lt; / Div & gt; & Lt; / Div & gt; Now the current CSS div {display: inline-block; Background color: #cdcdcd; Margin: 0px; 0; Padding: 0px; Width: 150px}. D1 {float: right; Background: blue; White color; }. D2 {background: orange; } .mitte_rechts {padding: 0; Width: 70.81%; Swim left; Margin-left: 0px; }. Sidebar_link {hei...

iOS check if application has access to microphone -

With the introduction of iOS 7, whenever they want to record the audio, the application must request microphone access How do I check whether the application has access to the microphone? In IOS 8 SDK, I can use the AVAudioSessionRecordPermission enum, but how do I check it in iOS? 7? INFO: I do not want to request permission, I just want to know if the app has access to the microphone (like location access): If ([CLLocationManager authorizationStatus] == kCLAuthorizationStatusDenied) {// do something} The iOS7 There is no way to obtain the current state of the microphone authority . IOS8 As iOS7 you must request permission [[AVAudioSession sharedInstance] requestRecordPermission: ^ (Bul approved) { If (given) {nslog (@ "allowed"); } Other {nslog (@ "Permission denied"); }}]; The same question has been asked earlier but there is no such API with which you are present as iOS8 Know the situation. Solution: Another option is ...

Should I use Start or Update to call the given method in Unity3d -

1. I have a class in which i projectile motion () with the returned type One method is IEnumerator and this method is being said to start () 2. The above script is linked to a prefab which is immediately from any other category. Problem: In the IENumerator ProjectileMotion () method, I need the update status of an object to continue running, so I declared // It was assigned to o = gameback and it is continuously moving forward to the public goal; In projectile motion (), if I target. Transforming the situation, it only gives the initial status and not where it was initially in the prefab, on which this script is attached, however, in updating code I get updated status of updated target Enabled (checked using debug.log) But I can not call ProjectileMotion () in Updateile. Definitely, every time when the prefix is ​​interactive, then what I should do to get the updated status of the target and hence the script is called . just put ... If you want to execute the co...

perl - Determine if directory is the root directory -

I am searching for the name of the directory, if the directory is found, give me the code chdir In other words, otherwise give an error message. For example: Use warnings; Strict use; Use cdwd getcwd; Die "base directory not found!" If (! Gaotier ()); All goto {my $ baseDir = '.test'; My $ curdir = getcwd (); While (1) {return 1 if (-d $ baseDir); If (Chdir ("..")) {chdir ($ curdir); Return 0; The problem is that chdir is not unsuccessful after going out of the root, so the above program enters an infinite loop if .test is not found. Of course, when I'm on Linux, I could just test for / , but I want to do it independently in a system. / P> As @GNUK replied, the original directory portable with its rootdir in the module The representation is the method. In this way I will write my goto_dir subroutine to note that capital letters are traditionally reserved for global identifiers such as Package :: Names . I think it is best to p...

arrays - VB.NET For loop adding extra character -

I do not really know how the error ... CODE: AnagramSolver does not input btnSolveAnagram.If the input as the Private Input Chase (), as the four private sub-btnSolveAnagram_Click (object as the sender, and EventArgs). Lesson Length and lt; = 1 then input for input (input.Text.Length - 1) = 1 input.Text.Length 'an array input chars (i-1) = meridian (input text, i, 1) from each letter string ("Anagram should be at least 2") End if the ending class I use the next loop to move through a string and each character Put in an array. But when I'm debugging from the clock window, each element of an additional character array is in it. I have array elements in this clock window (4) = "E" C (4) = "S" c I do not know where any additional 'C' is coming from any help? These are not part of the 'C' value, this is only the represantation of the debugger. . It prints them so that you know that this is a char "j" , not...

Can I ruin a MIDI device by sending bad data? -

I have got a guitar amp with a MIDI interface, I'm planning to see that with the manufacturer's built-in device What is possible Since I have no experience with MIDI, I would like to know that it is possible to delete the MIDI device by sending the wrong data. I'm not sure which data I want to send, and the device is basically a black box without any documents, so I can not give more details. But the one thing I would like to try is overwriting the underlying effects. MIDI commands are parsed and any effect (commands) executed by the device's firmware is a command Determines that the firmware is programmed to receive that order. Usually, unknown commands are ignored, so it is possible that do not waste any device random data. Most devices have no permanent status, however, some devices allow their firmware to be renewed through the medium, so if you use the correct SysEx command, and correct any checksum , It would be possible to replace the original firm...

cordova - Offline/local storage of data (text, images, …) in PhoneGap 3.5 -

I am creating a simple app using PhoneGap 3.5.0-0.20 and I have the content of the app "stored offline Want to do "and locally on the device so there is no need to download the content every time. Although there are thousands of ways to do this, I am not the best way to do this, it is in PhoneGrap 3.5 using a Javascript API. I know about LocalStorage but as far as I know, it has a file size restriction (5 MB), but I need to store almost 100 MB of content on the device. I only want to update it, I also have a need to flush the cache (= as soon as the device has an internet connection). I will implement the check for updates and download myself, I need to keep content continuously on devices across platforms (iOS, Android, Windows Phone) and clear it Please. Thank you for your help! :) You can use websql . It's constantly easy to use, but I would recommend any SQLite wrapper. Check it out This plugin is very easy to use, such as webSQL var db = Wi...

Auto click a custom hyperlink when page load using jQuery -

I have a link and click on Auto to open a popup window to play a video. Link like Just do something like this: & lt; A rel = "wp-video-lightbox" href = "" title = "" & gt; Watch Movie & lt; / A & gt; $ (Document) .ready (function () {$ ('a [rel = "your-rel"]'). Get (0). Click (); trigger ('click');}); Update: Update the code for your needs; Now you only have to change the "rel" attribute.

java - Why does the join() now work here? -

Image
I am trying to sum all numbers from 1 to n with the help of multiple threads. This is my thread: The public class executes MyThread Runnable {// limitations int lowerLimit; Int upper limit; MyInteger results; // Constructor public MyThread (int less limit, int extract, myintase result) {this.lowerLimit = lowerLimit; This.upperLimit = Upper Limit; This.result = results; } @ Override lists the numbers in the given time for public wide run () {// (int i = less limit; i & lt; = upper limit i i ++) {result.add (i); }}} This gets an upper and lower border and results that are shared on all threads. This is my test class: The amount of public square {public static long surrenders (int number threads, int ann) {thread} thread = new thread [ Numbertrareds]; MyInteger Results = New MyInteger (0); // creates new threads and starts them (int i = 0; i If I only use one thread, then the result is correct. If I use many threads, the result is sometimes correct and most of the ...

javascript - Kendo UI Grid - Sort by Descending Before Ascending -

I have read through every online post that I can find about sorting with the cando grid, in fact i I am trying to find a method of sorting by climbing first and then climbing. I know how to set a default sort in descending order when the grid is loaded, but I need that any field is sorted. sortable: {allowUnsort: false SortByDescendingFirst: true & lt; == Something like this}, I do not think one of defining it There is an option - you can try to do something like this (this is for Q1 2014, you can do the older version but you have to modify kendo.ui.Sortable.fn._click instead ): kendo.ui.Sorter.fn._click = function (default) {return function (e) {var element = this.element, dir = element.attr (kendo.ttr ( "DIR");); If (! Dir) element.attr (kendo.attr ("dir"), "asc"); If (dir === "desc") element.attr (kendo.attr ("dir"), ""); If (dir === "asc") element.attr (kendo.attr ("dir"), "de...

Kernel 3.8 support for beaglebone black Yocto project -

I am using beaglebone belk and chipcissar LCD. I buy the Yoto project for Beagle Blon Black and have found that it has the latest kernel i.e. linux 3.14 but for Linux kernel 3.8 I have the ChipCycle LCD patch. So I want to create a Yokor project for Linux kernel 3.8. Is this possible? If yes, how? Any help / indicator will be appreciated. Edit: After referencing the Yotoko document, I found that kernel 3.8 is supported in the Yocto project version "YP Core-Dylan 1.4.3", but I think it is Beaglebone Kali The BSP is not supported, if this is the case then my question is whether the latest YOcto project supports "Yip Core- Daisy 1.6.1" Linux kernel 3.8 or not? Edit: 3.14 is booting with LCD:

c++ - Difference between two ways of using default constructor -

What is the difference between defining an object of a square "person" by using its default constructor after two different ways: / P> Method 1: person = person (); Method 2: person (); When I started some variables inside the default constructor and tried to use those variables or tried to set those variables with the set / set methods in the main routine, then I found the compilation error in Method 2, but method 1 works. Thank you. person = person (); This declares an person object called a person . It starts with this object a temporary object created by Person () . This means that it will implement the copy / driver converter of the person (which will probably be omitted). person (); This is a function is called person which gives the person object to an object There is no announcement. You want it instead: person; This declares an object called person by calling person which is created by default. You have i...

c - Parameters to jump all the way through this assembly? -

I am reading myself to understand the assembly code, but need some help in ensuring that I Whether or not it's happening Here are the codes and my comments. Edit: Will the parameter make this function all the way through "jump"? We have regular prolozes in the beginning here). After that, we are storing% d% d which is in the $ 0x804ae8d, as I saw this value in GDB, and that's it. 804989e: ba 8d ae 04 08 mov $ 0x804ae8d,% edx 80498a3: 8b 45 08mm 0x8 (% ebp),% eax 80498a6: 8d 4d f0 lea -0x10 (% ebp) ,% Ecx 80498a9: 89 4c 24 0c mov% ecx, 0xc (% esp) 80498ad: 8d 4d f4 lea -0xc (% ebp),% ecx 80498b0: 89 4c 24 08 mov% ecx, 0x8 (% esp) 80498b4: 89 54 24 04 mov% edx, 0x4 (% esp) 80498b8: 89 04 24 mov% eax, (% esp) I believe that at this point (below) this Setting two parameters is basically to be taken into the function. It's scanning those people, and to compare the first parameter, it's bigger than 1, to see. If it is more than 1, then it goes down in ...

javascript - How to change the text inside a list item on hover -

Then I have an app that shows me the list of homes, shops, forums, and apps / apps But when you hover over the list item to make changes in the word application, I want to change it anywhere within the list item and not only on text messaging That's why I want to be able to move anywhere in the list area and not only to change it on the word. If someone knows how to do this then it would be awful that I just need the code and tell me for you how I will put it in my code and I need to change the name. Thank you. I have html for this list item & lt; A href = "#" & gt; & Lt; Li class = "item drop" & gt; & Lt; A href = "#" & gt; Apps & lt; / A & gt; I'm sure you want something like this: & lt; Ul class = "list" & gt; & Lt; Li & gt; Home and lt; / Li & gt; & Lt; Li & gt; Shop & lt; / Li & gt; & Lt; Li & gt; Forum & lt; / Li & gt; & Lt; Li ...

c# - size limit of varchar(MAX) in SQL Server -

I have a line that has the field defined as varchar (MAX) . I'm confused about the range of fields: In some places, I have read that the size of varchar (MAX) is the limit of 8K and in other places it seems that the limit is 2 GB. I have the string that I want to save in the database; It's about 220 I'm using linq-to-sql and when the query is submitted to the database query, then the row arises without any exceptions. However, when I open the database table in SSMS, then the cell should have a long string which is empty. Https://i.stack.imgur.com/ksxv0.png" alt = "here Enter image details "> Thanks. all the MAX datatype - in VARCHAR (MAX), NVARAR (MAX), and verbini (max) - There is a limit of 2 GB. You do not have to do anything. Without specifying MAX , the range of VARCHAR and VARBINARY is 8000 and the NVARCHAR limit is 4000 (due to NVARARAR is double-byte). If you do not see any data, then something else is going on. Are you sure ...

php - How to not obtain any row if there is nothing in both tables? -

I have a profile.php file on our site that generates a specific profile from a database using SQL queries . Choose Select Registered, date-format ('00 -00-0000 00: 00 ','% E 'as use, U.Mail, UACAC, date-format (U.GURTDD,'% e.% C.YY)) % C.% Y ') as' Last_Visit', as Posts from Users U as Count (PID), Yu ou U on posts. Username =? And p.post_creator = u.id; And below I test that if the user is present with all its data, then using the mysql_num_rows () function (please read PHP's MYSQL extension Avoid comments about using, I only get the problem , because if I give unknown code to WHERE section (instead of user icon, instead of question mark) Instead of getting blank results - the finished MySQL database Gives me a line, which contains most code fields NULL s, last_visit > with the expected 0 0000 and posts with 0 (zero). It is very beautiful, but I do not want to be empty, but in some specific areas (such as u.username ) th...

operator precedence - In Java, why does an assignment in parentheses not occur before the rest of the expression is evaluated? -

विचार करें int a = 20; A = a + (a = 5); // a == 25, क्यों नहीं 10? सभी पूर्ववर्ती नियमों को तुच्छ नहीं करें? क्या कुछ अभिव्यक्तियों के मूल्यांकन से पहले आरएचएस पर कुछ चर? > आपके उदाहरण में पहले लोड किया गया है, और फिर कोष्ठक में बिट का मूल्यांकन किया जाता है। यदि आपने आदेश को उलट दिया है: int a = 20; ए = (ए = 5) + ए; Println (एक); 10 ... आप वाकई 10 प्राप्त करते हैं। अभिव्यक्ति का मूल्यांकन बाएं से दाएं। इस पर विचार करें: f () + g () f को g से पहले बुलाया जाएगा। कल्पना कीजिए कि यह कैसे अनइंड्यूयूट होगा, f () + (g ()) के पास g होना चाहिए f से पहले। यह सब (इन टिप्पणियों में अपील करने के लिए @पीआईएसएन्को के लिए धन्यवाद) में विस्तृत है।

selenium webdriver - PageLoadTimeout and implicitywait not working in chrome browser in mac -

Pageloadloadouts and ImplicitWait are not working in the Chrome browser in Mac OS. They were working for me sometime back. But recently due to the failure of Chrome, all the scripts have started failing on Chrome because the browser does not have to wait to complete the Paglod. I downloaded the chromemader from the bottom and tried it. But still it is not working. chromedriver_mac32.zip Mac OSX 10.9.4 Chrome browser 36.0.1985.125 Terminal output when Chrome browser launches Starting ChromeDriver (v2 .10.267517) ) Only local connections are allowed on port 7567. Please know that I need to download chromemare from any other location (or) what I am doing wrong. Thanks

java - libgdx lag when sound.play() while collecting apple -

I'am सरल libgdx खेल कर रहा है। जब मैं sound.play () संपादित करें का उपयोग करता हूं, तो मेरे पास अंतराल है (0 सेकंड के लिए खेल बंद)। 2.3 पर 2.3 पर यह बग एपियर सब कुछ ठीक चल रहा है। विधि मैं इस कोड के द्वारा ध्वनि चलाता हूं: अगर (CollisionDetector.detect (स्पर्शएरिया, हूडि.गेटटौचएरिया ())) {गेमस्क्रीनटोटाःकोर ++; setPosition (); Println ( "खेला"); Assets.eatSound.play (); } और मैं ध्वनि लोड करने के लिए इस पद्धति का उपयोग करता हूं: स्थिर लंबे इंतजारफोड़ लोड हो गया (ध्वनि ध्वनि, फ्लोट वॉल्यूम) {long id; जबकि ((आईडी = ध्वनि.प्ले (मात्रा)) == -1) {लंबा टी = टाइमयूटल। नैनोटाइम (); जबकि (टाइमयूटील्स। नैनो टाइम) - टी एंड एलटी; 100000000); } वापसी आईडी; } मैं क्या कर रहा हूँ गलत? या इस अंतराल को ठीक करने के लिए मैं क्या कर सकता हूँ? संपादित करें: मैंने अभी धागा करने की कोशिश की है। Play () लेकिन यह भी काम नहीं करता है: नया थ्रेड (नया रननाबल) {@Override public void run () {// कुछ महत्वपूर्ण यहाँ है, अतुल्यकालिक रेंडरिंग धागा के लिए // रेंडर करने वाला थ्र...

c# - PictureBox Refresh causes layers above to flicker -

I am trying to read data from ports and show that the background on the dial is a picturebox in which a circular scale There is an image in which the reading is done, and the lineship is used to represent the dial. Pictureboxes are 'sent back' to allow the visibility of the lineship. I am attaching the representative code: If I do this: Private zero timer 1 volt (object sender, eventAggas E) {ang + 2.0 * meth. PI / 180.0; LineShap 1.x1 = convert.OINT32 (lineup 1.x2-r * monastery seam (angle)); Line Shape1.Y1 = Convert. ToInt32 (Lineship 1. Y2 - r * Math. Cos (Angle)); } Then it leaves a trace on the picture box. But if I use the refresh function of the picturebox, the dial appears for flicker. I have tried with the timer interval of 10, 15, 20, 50 and 100, but the problem persists. Private zero timer 1 volt (object sender, event ergugged E) {ang + 2.0 * meth. PI / 180.0; LineShap 1.x1 = convert.OINT32 (lineup 1.x2-r * monastery seam (angle)); Line Shape1.Y1 = Con...

c - Using FreeRTOS with XC8 compiler -

Image
I am trying to set up FreeRTOS with the XC8 compiler without any success. I searched the Internet but I do not know much about it, I am using PIC18F46K80, so I can not use C18 because it is not supported. I am trying to compile this minimum program: #include & lt; P18f46k80.h & gt; # Include & lt; Stdlib.h & gt; # Include & lt; FreeRTOS.h & gt; Int main (int arc, four ** argv) {return (EXIT_SUCCESS); } I have included the path related to the compiler: And the error I am getting is this: Include in free RTOS / source / timers. H: 71: Error: (103) #Terror: "Include FreeRTOS." The source files should appear before joining. Include FreeRTOS / Source / task.h: 71: Error: (103) #Terror: "Includes freeRTOSH should appear in source files before joining." You can clearly see that I'm including FreeRTOS.h . Manually add #define to timers.h for example here: #ifndef INC_FREERTOS_H #error "contains The freeRTOS.h...