Posts

Showing posts from September, 2013

Unable to receive Apple push notification on iphone through php service -

I'm sorry if this is a duplicate question, but I did not find the solution I was looking for. Here is the service code to send information to my PHP's iPhone: & lt ;? Php $ data = array (); // Place your device token here (without spaces): $ deviceToken = 'eb9ea0d12eb9a0bae159c7e54fa59baee22329df'; // Place the passphrase of your private key here: $ passphrase = 'dell'; $ Message = 'push notification service'; //////////////////////////////////////////////// ////////////////////////// $ ctx = stream_context_create (); Stream_context_set_option ($ ctx, 'ssl', 'local_cert', 'app / controller / ck.pem'); Stream_context_set_option ($ ctx, 'ssl', 'passphrase', $ passphrase); // Open the connection to the APNS server $ fp = stream_socket_client ('SSL: //gateway.sandbox.push.apple.com: 2195', $$ err, $ errstr, 60, STREAM_CLIENT_CONNECT | STREAM_CLIENT_PERSISTENT, $ ctx); If (! $ Fp) // exit ("Faile...

java - Writing to Files : Printwriter Converting Forward Slash to Backslash -

Why are doing this Printwriter? file file = new file ("/ files / kattextext"); Author = new printritter (file); Writer.write ("hello"); I get an error in the code above which says: java.io.FileNotFoundException: \ files \ KA.txt (the network path was Not found) This was not my specified path? Then how do I specify a file to write - usually create a new file and write it on? It also throws errors if KA.txt does not exist - I want to make it a new file and author. Thanks I ideally create a new file and author You can create just one file, PrintWriter author = new Print Writer ("name.txt", "UTF-8") ; Author.println ("text"); Where UTF-8 is file encoding. And write the file, remember that the file exists with the same name, then this override

c++ - Whose destructor is this one? -

नीचे दिए गए कोड में: #include & lt; स्ट्रिंग & gt; # शामिल करें & lt; iostream & gt; Struct एस {std :: string a; Int b; एस (const एस & amp;) = डिफ़ॉल्ट; एस (एस एंड amp;) = डिफ़ॉल्ट; & Amp; ऑपरेटर = (सेट एस & amp;) = डिफ़ॉल्ट; & Amp; ऑपरेटर = (एस एंड amp;) = डिफ़ॉल्ट; // यहां जरूरी नहीं है लेकिन इसे पूर्णता के लिए जोड़ा जाना चाहिए ~ एस () {std :: cout & lt; & lt; एक & lt; & lt; "" & Lt; & lt; बी एंड एलटी; & lt; std :: endl; }}; एस एफ (एस आर्ज) {एस s0 {}; एस एस 1 (एस 0); // s1 {s0}; पुस्तक में s1 = arg; वापसी s1; } Int main () {एस एस 3 {"उपकरण", 42}; च (S3); } मुझे निम्न आउटपुट मिलता है (मैंने अपनी युक्तियों के साथ आउटपुट टिप्पणी की थी): 42 // ??? 0 / s0 उपकरण को नष्ट कर दिया गया है 42 / / एआरजी उपकरण नष्ट कर दिया है 42 / / पर वापस लौटने के मूल्य एफ उपकरण नष्ट हो गया है 42 / s3 नष्ट हो जाता है जिसके विनाशक एक है जो outputs 42 ?? मैं इसे समझ नहीं सकता स्वचालित वैरिएबल घोषणा के रिवर्स ऑर्डर...

c# - Amazon Feed API - The file's header row is missing or invalid -

I am trying to submit a flat file filled with products (tab delimited) if I upload media Uploading this file with & amp; Inventory page upload is correct though, if I try to use the API I get an error: The file's header row is missing or invalid header row only uses Amazon And should not be modified or removed. To fix this error, then download the template again with vendor support and use that new copy, or insert the correct header row directly above the column headings in your existing file. This sample code, feeds API stream client library - C #. Submit Request Request = New Deposit (); request. Merchant = merchantId; request. Market placeIdlist = new irredist (); Request.MarketplaceIdList.Id = New list & lt; String & gt; (New string [] {marketplaceId}); Request.FeedContent = File.Open (@ "C: \ Amazon_Upload_20141104_10.txt", FileMode.Open, FileAccess.Read); Request.ContentMD5 = MarketplaceWebServiceClient.CalculateContentMD5 (request.FeedConte...

c++ - casting between two derived classes -

Is it appropriate to put between the points of the general ancestor? Does the compiler notice such a hierarchy and is it safe (call 1)? Or should the user be manually protected from the hierarchy manually (call 2)? Say that we have class A {}; Class B: A {}; Class C: A {Public: int SomeFunc () {return 3;}}; Int _tmain (int argc, _TCHAR * argv []) {b * b = (b *) ((a *) new c ()); // It is done manually, I believe it is safe ((C *) b) - & gt; Some finger (); // it's safe? This question has been refunded ((C *) ((A *) B)) - & gt; Some finger (); Edit: This code is consistent and scalable edit2: more comments added b * b = (b *) ((a *) new c ()); // It is done manually, I believe it is safe this no is safe. By changing the form of (t) xp , either static_cast or reinterpret_cast , speaking roughly. [Expr.cast] / 4: Conversions made by a const_cast (5.2.11), (5.2.9), a static_cast followed by const_cast , one const_cast , one rei...

Search Contact name from ABAddressBook using NSPredicate for iOS -

I am creating a custom phone book. In the search bar functionality, I need to find specific contacts using the text I entered. So what specific thing should I write that will filter the array using the addressbook array type ABrecord? There should be something like the name starts with "text" You can do something like this: NSArray * All People = CFBridgingRelease (ABAddressBookCopyArrayOfAllPeople (Address Book)); NSPredicate * predicate = [NSPredicate predicateWithBlock: ^ BOOL (ID person, NSDictionary * binding) {NSString * firstName = CFBridgingRelease (ABRecordCopyValue ((__ bridge ABRecordRef person, KABPersonFirstNameProperty)); If (first name & amp; amp; firstName rangeOfString: searchTerm option: NSCaseInsensitiveSearch] .post == 0) return TRUE; NSString * Last Name = CFBridgingRelease (ABRecordCopyValue ((__ bridge ABRecordRef person, KABPersonLastNameProperty)); If (Last Name & amp; amp; [Last Name Rangeoffstring: SearchEarth Options: NSCCINSiti...

regex - how do i extract the string 'myUIBean' from the string 'com.test.pkg1.myUIBean.getName' -

मैं स्ट्रिंग से ' myUIBean ' स्ट्रिंग कैसे निकालूं? ' com.test .pkg1.myUIBean.getName '। मेरे पास समान स्ट्रिंग्स का एक सेट है जिसमें com.test.pkg1.myUIBean1.getName com.test.pkg1.myUIBean2.getName com.test.pkg1.myUIBean3.getName मुझे आउटपुट होना चाहिए: myUIBean1 myUIBean2 myUIBean3 मैं पैटर्न का उपयोग कर रहा हूं और निकाले गए समूहों को प्रदर्शित कर रहा हूं, लेकिन यह अंतिम वाक्य में 'myUIBean' से पहले सभी पाठ का चयन कर रहा है। मैं उपयोग कर रहा हूँ पैटर्न है: (। *) "+" UIBean "+" (। *) धन्यवाद अग्रिम में। कोशिश करें: । * \। (MyUIBean। *) \ .. * मान लें कि आप जावा का उपयोग कर रहे हैं, ताकि आप निम्न का उपयोग कर सकें: पैटर्न पैटर्न = Pattern.compile ("। * \\। (MyUIBean। *) \\ .. * "); Matcher matcher = pattern.matcher ("com.test.pkg1.myUIBean1.getName"); If (matcher.find ()) {System.out.println (matcher.group (1)); }

Read object from form1 into a class vb.net -

I need to read the content of a text box present in form1. So far I have not had any wrong problems, I have created a function that works perfectly. The problem is now that this function has become very big to keep it in Form 1, so I created a square, which I imported in Form 1. This class was included in the function that was in first form 1, now the compiler gives me this message: "An non-shared member requires an object reference " Probably because he can not read the object in Form 1. So I wonder how to use this resource, I tried to import form1 class like this: Import App.Form1 Square of function public function export () oSheet.Cells (2, 2) .value = Oggettivo_1_1. Value 'oggettivo_1_1_.value is an object of form1 end function But I always get this error, is there anyone who can help me? Import Typically in a namespace type (Like classrooms) are used to make available. It does not provide an item reference that you have an important ...

asp.net mvc - Convert WebForm VB Web Application to MVC C# gradually -

We currently have a vb web form application and we want to migrate it to C # MVC in a complete rewrite Instead we want to move one project at a time. I know that there is a hybrid project with webform and MVC which is described below: But the problem I have is that the web application The vb / asp.net web form exists in the external page and when a user clicks on an area, a button that is rewritten in C # / Razor MVC. I Do I have a webform Can I provide a view of the razor inside? If I can not send to a new tab? > Any ideas how to do that? Thanks I currently work on the same hybrid project where I have The webform part and the MVC part. We strive to get rid of the webfamous part. The strategy I have come up with is: Get all the arguments on the BL layer from the webform in your solution All model dialogs Change the MVC + RAZER partial Vi EWS It's really easy to do via AJAX in your webform clickable element: OnClientClick = '& lt;% #...

java - Error to initialize the parse.com code in Android -

Image
I'm starting with Java / Android and parse today I need your help. I do not know what I do Am wrong See my picture My jar The file is in "Lib", but I am getting red lines in my project. Also, in Parse.in initialize you can see how it is not recognized. You should import the class Add this import statement to your code import com.parse.Parse; Import everything that you need, you can also import all sections import com.parse.blablabla ... ..; And if you've added the .jar files, then you can fix the import in Android Studio. Follow these steps 1) Add Pars Libs to Your Project. 2) clear your project 3) add import details Import com.parse.Parse; You can see that I did not get any error after those steps This is not my project

c# - Using try/catch to display errors depending on input -

I have an extraordinary assignment, using try / catch to show many names Including the number entered (using an array) If the number entered is too large then it can still display the name, but it also has to give a faulty error. If a word or something is used in such a way it needs to give a format error. My code works fairly well because it can display an error outside of a range, but when I put a word, I get the format error. I would also like to know if there is a possibility of an error, if the number is less than 5 (in such cases where only 5 are acceptable). Here is my code: class program {static zero main (string [] args) {string [] names = new string [5] {"Mary" , "John", "Tim", "Matt", "Jeff"}; Read String = console Readline (); Intel Apple; Try {int.TryParse (Read, Appel out); {Int a = 0; a & lt; apel; a ++) for {console}. Vidline (name [a]); }} Catch (formatException E) {console.lightline ("This is a ...

javascript - Canvas implementation on different images -

I am using the next sample in my code: var lasticon; Click (function () ($ (function (). $ (Function () (if (austicone! = This.id) {$ ('#' + old + 'L') Toggle (); AwwCicon = It is .id;} and {lasticon = null;} $ ('#' + this.id + 'L'). Toggle ();});}); .inonL {display: none; margin-top: 70px; Margin-left: 100px; height: 100 pixel width: 100px; position: full;} var forever; $ (function () {$ ('. Icon'). (Function () (if (aston;! .id) {$ ('#' + old + 'L') Toggle (); AwwCicon = it .id;} and {lasticon = null;} $ ('#' + this.id + 'L'). Toggle ();});}); Whatever I need, next I have to implement the next solution of my first code in the field: I have done some tests and have tried to apply it to me code, but nothing happens. I would like to be able to resize and move the second image that appears when clicking on the first image so you can click on the "e-mail icon" for example, and then change the s...

ubuntu - Boost.Thread Linking - boost_thread vs. boost_thread-mt -

It is not clear to me that the linking option exists for the library. I am at Ubuntu 8.04 and I have found that whenever using compile and running both using boost_thread or boost_thread-mt , but I do not see any documents Gives these or any other linking option in the link given above. Boost what. Link options are available and what do they mean? Good ... The first interesting thing is that in the name -MT Modifier indicates that the library is fine for multithreading. It can tell us to believe that boost_thread (without this modifier) ​​can be multithread-unsafe ... But the real thing is that (as my Is seen on your Ubuntu 10.04 box), there is a soft link for boost_thread boost_thread-mt , which means that both are same and are identical. If you want to verify it, you can open the console on your Ubuntu (console can make fullscreen because the name is too long), then type: Cd / usr / lib Go to the directory where Boost Libraries are I and then: ls -...

css - Primefaces 5.0 Chart Customization -

I have a problem creating a custom P: chart type = "pie" canvas. I have to change the background color of the pie chart, such as from white to second color. I found almost everything that I found I tried to override the principal of the class of principal classes, but it does not work. It turns all the canvas / frames into one color and the chart disappears. .xhtml file & lt; P: chart type = "pie" model = "# {dashboard controller. Model}" style = "width: 500px; height: 250px; margin: 0 auto;" / & gt; Bean Java file model = new PichortModel (); Model.setDataFormat ("value"); Model.setShowDataLabels (true); Model.setFill (true); Model.setTitle ("America"); Model.setSeriesColors ("62656a, a5a5a5,929397"); Model.setShowDataLabels (true); Model.setDiameter (200); This is the component that I need to change the background of the canvas. You can see the same chart from here: ** How can I ...

sql - Oracle create procedure privilege? -

If I have a procedure privilege and I do not have the updated privileges and if I wrote an updated statement in the process Will update or give me an error? By default, uses a fixed authority model to detect the available rights for Oracle Process is going on, this means that by default the process is executed with the privileges of the schema in which it is defined. So if your schema does not have the privilege of updating the table used in the process, you will get an error.

php - Phalcon "use Vendor\Package" pass to view -

I am currently a website developer using Laravel as my main framework for work. I would like to use the Falcons for any project, which is beneficial to me, but there are issues related to some things about my head. I would like to know how the vendor \ package is used to pass a controller to see again? Currently, the document shows that the 'use' case is being added to the scene which I do not want because I want to clear my thoughts and believe that it should be done in the controller . I have tried at present ... & lt; Use php Phalcon \ Tag; Class Index Controller ControllerBase {Public Function Index Action () {}} and then added to my view ... & lt; H2 & gt; The form below & lt; / H2 & gt; & Lt ;? Php echo tag :: form ("signup / register"); ? & Gt; & Lt; P & gt; & Lt; Label = "name" & gt; Name & lt; / Label & gt; & Lt ;? Php echo tag :: textfield ("name")? & Gt; &...

wcf - Notification Service in C# -

मैं एक अधिसूचना सेवा का निर्माण करने जा रहा हूं जो निम्न कार्य करता है: ग्राहक प्रारंभिक डेटा (क्लाइंट आईपी, क्लाइंट आईडी) के साथ स्टार्टअप पर नोटिफिकेशन सर्विस को कॉल करते हैं। सर्वर क्लाइंट्स को अपने आईपी की मदद से कनेक्ट किए हुए क्लाइंट्स सूची में सहेजता है। अगर एक क्लाइंट को सूचित करने की आवश्यकता है अन्य क्लाइंट्स को संदेश भेजें, यह अधिसूचना सेवा पर इस संदेश को अपने आईपी का उपयोग करके अन्य क्लाइंट को प्रकाशित करने के लिए कॉल करता है। क्लाइंट शटडाउन पर, सर्विस क्लाइंट सूची से इस क्लाइंट को निकाल देती है। मेरा प्रश्न यह है: 1- क्या यह ऐसी सूचना सेवा के लिए एक लागू डिजाइन है? 2- मुझे पता है सेवा और क्लाइंट के बीच कनेक्शन, WCF कॉलबैक, माइक्रोसॉफ्ट संदेश कतार और सॉकेट्स का उपयोग करके लागू किया जा सकता है। क्या कोई अन्य तकनीक / पद्धति है, जिसे सी # में इस्तेमाल किया जा सकता है? नोट: अब, क्लाइंट हैं .NET c # अनुप्रयोग, लेकिन भविष्य में ग्राहकों में मोबाइल एप्लिकेशन हो सकते हैं, इसलिए मुझे एक ऐसा तरीका चाहिए जो प्लेटफ़ॉर्म स्वतंत्र है। धन्यवाद

performance - Efficient alternative for "ismember" function for arrays - MATLAB -

यदि ए 2D में अंक की एक श्रृंखला समन्वयित है, उदाहरण के लिए: & gt पूर्व; ए = [1 2; 3 4; 5 6; 7 8; 9 0]; ए = 1 2 3 4 5 6 7 8 9 0 और बी दो कोशिकाओं में शामिल हैं जो प्रत्येक कक्ष 'ए' का एक भाग है और केवल एक्स मान (प्रथम स्तंभ), इसका मतलब है: & gt; & gt; बी = {[3; 7]; [5]} बी = [2x1 डबल] [5] मैं B कोशिकाओं को A और उन बिंदुओं के निर्देशांक दे। यह मेरा कोड है जो डेटा के बड़े सेट के लिए बहुत धीमा है: C = cell (लंबाई (B ), 1) मैं = 1 के लिए: लंबाई (बी) सी {i} = A (मेम्बर (ए (,, 1), बी {i}, 'पंक्तियाँ'), :); सी सही उत्तर है और 2 कोशिकाओं को शामिल करें जो कि बी के प्रत्येक कक्ष के निर्देशांक हैं: सी = [2x2 डबल] [1x2 डबल]> gt; & gt; सी {1} ans = 3 4 7 8 और & gt; & gt; सी {2} ans = 5 6 दोबारा, हालांकि सी सही उत्तर है, मैं एक अधिक कुशल समाधान की तलाश कर रहा हूं शायद सेलफ़न ? आपको ' पंक्तियाँ ' के साथ ismember वहां। तो, आप बस ऐसा कर सकते हैं - के लिए k = 1: numel (b) c {i} = a (ismembe...

javascript - How can create loop for below function -

Here webdriver should click on each element, but the action is the same, can you help me in javascript New! Public Zero ClickOffAffitters () {driver.findElement (by.cssSelector ("div.scroll-item.all")). Click (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.news")) (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.results")) (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.schedules")) (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.images")) (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.video")) (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.comment")) (); . Click on Driver.findElement (By.cssSelector ("div.scroll-item.activity")) (); } clickonfilter ("div.scroll-item.activity", "div.scroll -item.activity "); // You can add more, or just send an array of st...

php - Sorting on multiple values MYSQL Laravel -

I am currently working on a project where I need to sort a collection using MySQL, but I Actually can not find it working. I have a table with ingredients component related to a training. Therefore there may be several components in one training. I created an HTML table with the results along with the following columns: Date Time Component Component What sort of components do I need to sort: Sort the dates, all the dates ASC - time, the component must be the first time at that time Must have - components, based on time, the ingredients must be grouped by the same training. For example, a list with these components: Date: 4-11-2014 Time: 11:00 Training_ID: 1 Components : First Component Date: 4-11-2014 Time: 11:30 Training_ID: 2 Component: First component of Training_ID2 Date: 4-11-2014 Time: 12:00 Training_ID: 1 Component: Second Component: In order to be kept: first component, second component, training First component of 2 This is because the fir...

php - How to get deleted orders (trashed) in Woocommerce -

I'm trying to get the waste order list from the WooCommerce Shop Order. Earlier, I tried with the status of order to publish back properly for my needs. Now woocommerce version 2.2+ they added post status because wc-complete something. I can not find garbage post in this case. I tried function gettrashedorderlist () {$ args = array ('post_type' = & gt; 'shop_order', 'posts_per_page' = & gt; 1 ' ',' Post_status' = & gt; array ('trash')); Foreach (get_posts $$ as each order) {// something goes here}} I'm unable to get a trashed order list with the latest version. I also get function gettrashedorderlist () {$ args = array ('post_type' = & gt; 'shop_order', 'posts_per_page' = & gt; '- 1', 'post_status') Tried to do anything like that. = & Gt; Array ('wc-complete')); Foreach (get_posts ($ args) $ each) {// something goes here}} It is working but i...

AngularJS gives index as blank inside ng-repeat -

I have used the following code but I get the index space, I also do not use angle R and C. I am able to do JS expression {r} and {c}, what can be the reason this is also empty? (There are no errors on JavaScript console) I need to set the color of the div element on page load based on R and C The above code plankers run standalone tasks, though, when you do not use dragable instructions. I have used the instructions of this site, can it be due to those instructions? UPDATE: On further debugging I know that this module is due to the following modules when I make an indexed comment from the module, but still I do not know how to fix it module.factory ('uuid', function () {var svc = {new: function ()} {function_p8 (s) {var p = (Math.random (). ToString (16) + "000000000 "). Substrate (2,8); returns s?" - "+ p.substr (0,4) +" - "+ p.substr (4,4): p;} return _p8 () + _p8 (true ) + _p8 (true) + _p8 ();}, I do not think Problem. Onl...

php - when to update the tag @author in PHPdoc? -

This is really a novice question. I am trying to improve my skills with PHP, so I'm reading some libraries code I saw that many PHPdoc header (is this the correct name ? I mean: / ** * @complete $ configuration * @backword * @ Author Developer 1 * / ) @ author The tag is. Assume that developer 2 makes huge changes to developer 1 and then does Github. Should developer 2 update to @ ether tag? What is normal practice? phpDocumentor 2 support multiple @ ethern tags: / ** * Class User * @ Author Styx * Author @ Second Author @ Package Application \ Model * / Class User {}

python - PyPi description markdown doesn't work -

I uploaded a package to use POP: Register -r pypi dragon setup.py sdist upload -r pypi I am trying to modify decsription, I wrote (Please do not edit the formatting of the following part of the code For example, I've made it: `` `Dragon '@' RTR (this is the purpose of displaying my problem): ** nose-docstring-plugin ** This plugin lets you Half of their properties The test enables to modify the dosstring of tests on: section = 'miksaction', type = 'functional +', module = 'miamulude', id = 1) def test_function (self): "" "This is the original doccrusion pass However, the text appears to be, without marker formatting what I'm doing wrong? PyPI does not support, README will not be rendered in HTML If you want a rendered readme, stick with the reconstructed text; This is a good starting point. You probably want to install it so that you can test your document locally; You want to see the rst2html.py script ...

php - Create trigger after insert for user id -

Good day to everyone! I have 1 table (user) that I want to use to update the UID field in another table (recipes). Therefore, when the user prepares a recipe, the UD should be inserted in the Recipes table. This is a trigger created by me, after error message: After adding on recipes for each line update recipes, create user = url = users.uid trigger users_recipes where users.uid = Variants ('', '', 'inserted', '', '', '', '', '', '', '' ',' United States ',' Blah 1/2 and Blah ',' A: 1: {i: 0; s: 3: "Nut" ;} ',' Universal ',' ',' ',' ',' 2014-11-04 ') == -----> Table' recipes' can not be updated in stored function / trigger because it is already Used by the statement that applies this stored function / trigger If someone can help me understand what I did wrong, then I appreciate it. Thanks a long time ago!...

Copy XML for each specific child node keeping one complete copy for each child node using XSLT? -

itempop = "text"> I have the same XML I want to "record", if you do, XML based on the authors. So for every author kid node, I want all copies of all XML for all copies and just a one author hair node. I got it, but hanging me properly by generating authors. I have appreciated any help! Sample: & lt; Root & gt; & Lt; Book & gt; & Lt; Name & gt; ... some data & lt; / Name & gt; & Lt; Information & gt; ... some data & lt; / Info & gt; & Lt; Writers & gt; & Lt; Author & gt; Author 1 & lt; / Author & gt; & Lt; Author & gt; Author 2 & lt; / Author & gt; & Lt; / Authors & gt; Other nodes & lt; / Book & gt; & Lt; / Root & gt; ====================== Output: & lt; Root & gt; & Lt; Book & gt; & Lt; Name & gt; ... some data & lt; / Name & gt; & Lt; Information & gt; ... some data & lt; / Info & gt; & L...

How to List all test names in teamcity using REST API -

I'm trying to get a list of tests defined here. But can not get the list of examinations from the matamcity / app / rest / testecution? Locator = build type: (id: 1140)] Is there another way to get them / list of failed tests? I know that due to this question has long been past, but I err If you stumble upon, here it is if someone else has such a problem, then the answer. If you understand the team policy document correctly then you can not use buildType with the test. The supported locator is actually the exact creation id: But what you can do is get the list of builds for the build type: http: // myTeamCity: 100 / http: // // myTeamCity: 100 / guestAuth / app / rest / testOccurrences? Locator = build: (id: 109) Keeping in mind that you have written an integer in your example as an ID, maybe you already have the correct ID, but your Pass processing path is incorrect because it is not an id for buildType, but for build, because buildtips have wires for IDs ...

performance - jQuery addClass/Mouse-over timeout combo issue -

The block of code below works perfectly until I add the mouse over the timeout. The mouse works longer than the mouse but the classes are no longer connected. Is there a way to combine both and still classes are considered? $ (document) .ready (function () {var myTimeout; $ ('# nav-bar & gt; ul Li'). Myth (work () {myTimeout = setTimeout (function ($ ('. Drop-down-plates: visible') Hide (); $ ('# nav-bar ul li.current-menu- (' current-menu-item '); $ (' # navy Eq ($ (this). Index ()). AddClass ('current -menmen-item'); $ ('drop-down-plates'). Eq ($ (this) .index ( $ ('# Nav-bar ul li.current-dmenu-item'). RemoveClass ('current muclove (function () () {explicit timeout (my timeout);}); $ (' # Drop-down-box '). MUSELEVE (function () {$ (' .drop-down-p ('Current- dmenu-item');});}); Within the timeout, this element will not contain you. Caching the reference can be done in a variable outsid...

javascript - Content-Disposition:attachment not triggering download dialog -

I had to face some unexpected behavior while trying to create file download functionality on my NodesJS server. I have a space (API) API that calls for some export data function, which creates a CSV file on the server and res.download ('path / to / file') to trigger the download. . Response headers include Content-dispute: attachment; Filename = "indicators.csv" Content-Length: 30125 Content-Type: Text / CSV; Charset = UTF-8 So everything is in order. The thing is, I get a response from the server as plain text. In response, all the data present in the CSV file, but the browser file download dialog does not trigger as I wanted. I tried both on Chrome and FF Update I managed to work on creating a dummy form, and to make my AJAX call Using your submission but this is an ugly hack, and I'm still looking for a more elegant solution. No headers are problematic. The problem is that you are asking the download URL through an AJAX call, which wil...

non valid output of broadcast handler in Common Lisp Closure XML package -

After the answers given to my last question, I applied a subclass of cxml: sax-proxy handler (broadcast one Special case handler). Unfortunately, the library looks like a bug, but it tries to produce XML with definitions of internal document type, but the doctor is a non-valid XML That is, with the command of parsers Play: (open with-file) Xml ": if-present: go ahead: direction: output (let's create the make-instance ' Preproc .: Chen-Handler (CXML: Make-Character-Stream Sync Out))) (CxML: Pars # P "Harem.xml" h: valid t))) Where the file starts with harem.xml (see Principle): & Lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; DOCTYPE COLHAREM SYSTEM "harem.dtd" & gt; & gt; Coleman versao = "Segundo_dourada_com_relacoes_14Abril2010" & gt; & Lt ; DOC DOCID = "H2-dftre765"> The command produces the teste.xml file: & lt ;? Xml version = "1.0" encoding = ...

Jquery $.GET handling data -

I'm running a $. Receive a call to get the data from the Php file: $ .get ("test.php", {home_type: home_info [0], home_summy: home_info [1]}, function ( Data) {console.log (data);}); and returns this data: [{"id": "1", "title": "aaa"}, {"id" I tried to use a primary mechanism to use this data: "bbb" $ Each (data, function (y, z) {console.log (y); console.log (z);}); returns a number starting with y 1 and keeps counting and z data has every letter: (This is not what I was hoping for. What do I have to do To run foreach and use each item in one go. $. ("Test.php", {Home_type: home_info [0], home_community: home_info [1]}, function (response) {var data = JSON.parse (response); $ .each (data, function (index, value) {// every item with good Do ... console.log (index); console.log (value);}}});

How to identify when yammer is making a request for a page -

In our asp.NET code we see the user-agent perform the data. Yes, I know that the user-agent can be deceived. How can I identify when a web request for any of our pages comes from Yaman? It does not appear that the user agent is set to Yumor. If a yammer tries to share a link, then that user agent is set to When the link is accessed ... Mozilla / 5.0 (compatible; ambelie / 0.2; +)

angularjs - Displaying two tables within a loop -

I am very new to AngularJS, I am using it with the Firebase. I have a set of data like this: "userId1": {"name": "Bobby", "comments": {"-J_v90hh5sbJ2acmX4nq" : True}} and a comment list "- J_v90hh5sbJ2acmX4nq": {"CREATION_DATE": 1415110466568, "creator_id": "userId1", " Desc ":" dsqdsq "," type ":" suggestion "} So what I want to do is display all the comments of our friend Bobby. .controller ('CommentsCtrl', function ($ scope, $ firebase) {var creator_id = 'userId1'; // test objectives userCommentsRef = new Firebase ("https: // terrible. CommentsRef = new Firebase ("https://awesome.firebaseio.com/comments"); on userCommentsSync = $ firebase (userCommentsRef); commentsSync = $ firebase on firebaseio.com/users/"+creator_id+'/comments' (CommentsRef); UserComments = userCommentsSync $ asObject ();...

php - Weird behavior when using custom HTTP header -

My website uses AJAX to load pages in a div and each AJAX The following custom header sends the request: X-AJAXRequest . If the header is present then my website sends the body without the header and footer, otherwise it sends the whole page This is my PHP code: if (empty ($ _ server ['HTTP_X_AJAXREQUEST'])) {echo ($ head); Echo ($ body); Echo ($ script); } And (Include ("master.php");} Now, the problem is, when someone visits X, clicks on the Y link, then X on X Clicks on the X header and footer, such as the headers do not exist, even when Developer Tools (F12) is open! I think it can be caching, because IE11 (I am developing the browser), but still, why caching is mine It seems that this is actually caching, which is causing you problems. Once the user has visited X, your browser caches (depending on which caching rules are there and the server has been provided). When you go to Wi and try to load X through AJAX, browser knows The cache alrea...

json - Scala Play apps without a web UI? -

I have recently been writing scala apps, and for those who need a web UI, play frameworks are great I am struggling to define a sensible library stack for the back-end app without the UI, Play provides two very useful components for the UI-less app: via 'SBT Stage' Good JSON support and convenient app packaging. But it also brings very unused stuff, I want to stop these back-end apps. I know that JSON support has gone essentially in the Scala standard library, and options like Jackson / Jarkson or Argonaut are present, but I equally integrate into all applications rather than dealing with many libraries. I'm hoping to use the approach for purposes. I know that other packaging plugins exist for SBT, but this is the only problem. Is it meant to use play for app without a web UI? Are people actually doing this out there? If so, how do I configure play to work like this? (For example, do not start HTTP listeners: 9000). Many thanks in advance. Sure, play spray Good...

Migrate MoinMoin Wiki to MediaWiki -

I have MoinMonic Wiki (version 1.5.7), and I have MediaWiki (version 1.18.2). I found something that can help me import mediawiki pages from MoinMoine Wiki, but this is not the whole process, what is the best way to import all the pages of MediaWiki from MoinMoine Wiki? I have never done this before, so I really appreciate it if you can answer me all the steps. Actually can not help with it, but to clarify that the script is usually Why is not the complete solution: the owner of each wiki has a problem only once, so the hacks which work 80% quickly, are rather common. So the only thing I can advise is that Take one quick half of it, improve it slightly and contribute to upstream changes The rana.

linux - Create an ELF file where the section after the .text section is very distant from the .text section -

I need to test a program that I am writing against a case of a diseased angle. To do this, I want to compile an assembly file so that the .text section is too far from the section that follows it 12 Text 00000204 0000000000400400 That is, when I run objdump -h on the compiled file, then I have to do something like this: 0000000000400400 00000400 2 ** 4 content, alom, load , Readonly, Code 13 .Fini 00000016 0000000000500000 000000000000500000000 00000604 2 ** 2 Note that there is a very different difference between the end of a section. And the beginning of the second, I have modified the output of the command, what I want, so if the output does not do anything, then the reason is this. ... and you want to know how forced the linker to create a file like this Go? You can manually type the link script and the "T file name" option is "ld" (which is the "-v, -t, file name" option of "GCC").

cassandra 2.0 - opscenter can't connect to agents after enabling ssl -

I am setting up node-to-node encryption in AWS on Ubuntu in the 3-node Datastex Enterprise 4.5.2 cluster. [1] - [2] - [3] - [4] - I have created certs and keystore [1, 2,3] Added certs to truststore on each node to turn on node-to-node encryption [1,3] Edit cassandra.yaml (except The address edited to start the encryption for any day.AMLL [4] Restart all nodes 'nodesetool status 'Shows that all nodes are usually IOpscenter shows the nodes but the error message gives '3 agents are connected' opscenter to allow agents to talk to the ops center and what to do? Opsecenter is installed on a node, and it At the same box the agent will not talk. opscenterd daemon failed to start correctly. / P> Exception. Import: libssl.so.0.9.8: Can not open shared object file: any such file or not Not a directory P> First of all, I have ln -s /lib/x86_64-linux-gnu/libssl.so.1.0.0/lib/x86_64-linux-gnu/libssl.so Tried a simple solution to add .0.9.8 and ln -s /li...

redirect - input from console application to another c# console application? -

मैं एसी # आवेदन को विकसित करना चाहता हूं (a.exe) कोड> (बी.एक्सई) b.exe कोई भी तर्क नहीं लेता है। b.exe -call या b.exe कॉल और इतने पर काम नहीं करता जब मैं cmd ​​से b.exe खोलता हूँ तो इस तरह से तर्क लेता है: b: call b: कमांड 2 .... b: कमांड n मैं b.exe से a.exe कैसे फ़ीड कर सकता / सकती हूं? मैंने उपयोग किया है लेकिन यह काम नहीं करता है। var psi = new processstartInfo ("b.exe") {रीडायरेक्ट मानकआयात = सच, रीडायरेक्ट मानकऑप्टपुट = गलत, UseShellExecute = false}; Var p = नई प्रक्रिया {StartInfo = psi}; p.Start (); p.StandardInput.WriteLine ( "कॉल"); यहां आपके प्रश्न से मैं समझता हूं: a.exe शुरू होता है b.exe a.exe या तो कमांड लाइन तर्क या मानक इनपुट का उपयोग करता है कमांड / अनुरोध b.exe b.exe के लिए कमांड / अनुरोध प्राप्त और मानक ओटपुट के माध्यम से जानकारी पास करता है कमांड लाइन तर्क का उपयोग करना थोड़ा सरल है, सिवाय इसके कि आपको प्रत्येक अनुरोध / कमांड के लिए कई बार b.exe को चलाने की आवश्यकता होगी। // b.exe...

Android getting .apk file -

When I close my emulator and project and when the emulator is open it appears again, why my Are the apppeople disappearing in the bin folder? I do not know when copying .apk file is safe. When do I close the emulator (not clean project) and .apk is there? When my app is running on my emulator and copying .apk file? (Export) Saving unsigned application package and in separate location? (Import) Unsigned application "" Sometimes I have installed an APK file without any problems in my phone. Are you using Eclipse? There are some important settings: a Window> Preferences> Android> Build> "Packaging and Decking Until Exporting or Launching" - If it is selected If APK is launched, then only the APK is generated when the application is launched on the device / emulator. b. Project> Automatically create - This code will be created automatically after the code changes c (Only then the b is not selected) Project> Clean. .>...

Output from exec not writing to a file in java -

From inside my Java code, I have an external program, I use the following: full return CODEC = 0; String cmmd = "die-fa-fn rays" + file1; Last process processCC = Runtime.getRuntime (). Exec (cmnd); Buffer bufC = new buffed reader (new input stereo reader (Process.jet InputStream ())); ReturnCodeC = processCC.waitFor (); } Hold (Exception E1) {e1.printStackTrace ();}} External program diameter should be called from the call in the file called Output File 1 having had . I think the problem is that when the production is bigger than Diya, then I am not getting any output. Is there a size limit for buffer reader? Now when I think I understand the problem, then I will advise you to use Project Builder It allows you to provide exceptional control over the process output. Here's a link that can help you: The process gets a string array as a logic, so string [] cmd = {"dia", "-fa "," -fn "," res "};

c++ - Overcoming diamond ambiguity in different way -

I know the method of solving it using the diamond problem and the virtual base class. I tried to solve the diamond problem in a different way but did not succeed. I do not know why. #include & lt; Iostream & gt; using namespace std; Class A {Public: Zero Exposure () {cout & lt; & Lt; "Successfully printed"; }}; Class B: Public A {}; Class C: Private A / Display () will be the personal member of AC {}; Class D: public B, public C / Private member's performance (should not be legacy of C) {}; Int main () {D d; D.display (); Return 0; } As the private members have not inherited, class D will not inherit any function, and when the succession of class D square B and C, there is only 1 demonstration ( ) Should be in the function D, but when I try to use the class D object using the display () function, it shows the same problem that the display function is ambiguous. "Private members are not found" is a false base, it is not Java. Membe...

wif - Single Sign Off do not clear RP's own session -

I'm new to wif and now I have to face a problem when a single sign is turned off. The following is the background of my problem: First of all, I am working on two old A and B, which they store the user's information in it, after authenticating a user, their own sessions Variable And App A and B have their own local database. Now, my job is to use ADFS to enable SSO (Single Signon) between two applications. Now, I am creating a new Active Directory to store users centrally, when a user tries to log into the application A through ADFS, then the application can be used in the local names Need to check. If present, the user can log in to the AP. Otherwise, the app will reject the claim. Here is the technical section: I extend the WSFAdationActection module and check the incoming claim methodology onSessionSecurityTokenCreated in the local database. If the result is matched, then I retrieve the user's information from the local database and store it in the session va...

javascript - Filtering GeoJSON with JQ -

इस JSON को देखते हुए {"type": "FeatureCollection", "features": ["प्रकार": "सुविधा", "गुण": "ए"}, "ज्यामिति": {"प्रकार": "बिंदु", "निर्देशांक": [-69.23583984375, 45.460130637921004]}}, {"प्रकार": "फ़ीचर", "गुण": {"MODE": "D"}, "ज्यामिति": {"प्रकार": "बिंदु", "निर्देशांक": [-69.23651039600372, 45.4605388819 9 6 9]}}}}} मैं इनके माध्यम से फ़िल्टर करने के लिए और features का चयन करना चाहूंगा जो कि MODE: D संपत्ति वाले हैं जहाँ तक मैं बता सकता हूं, क्वेरी jq। [] | मुझे क्या याद आ रहा है? अग्रिम धन्यवाद। jq '.. | चुनें (है ("गुण"))? | का चयन करें (.properties.MODE == "D") ' प्रश्न चिह्न त्रुटियों को अनदेखा करने के लिए jq बताता है। .. वस्तु में recurse है jq '.features [] | आप तरीकों में मतभेदों को ध्यान में रखने के लिए बिना पुनराग...

python - py:choose with list of strings -

I am trying to select a statement inside a loop, I have to populate a table like this: & lt; Tr py: for = "i in category (0,25)" & gt; & Lt; Py: select my_list [i] = '0' & gt; & Lt; Py: When my_list [i] = '0' & gt; & Lt; Td> Not OK & Lt; / Py: When & gt; & Lt; Py: Otherwise & gt; & Lt; TD & gt; OK & lt; / TD & gt; & Lt; / Py: Otherwise & gt; & Lt; / Py: Select & gt; ... ... & lt; / Tr & gt; Let me line & lt; There is an error on py ... select ... & gt; : TemplateSyntaxError: Not good - Certified (invalid token): Line ... but I do not understand how Use the Select Statement! If I feel like C-like (and it seems more logical) I just have to write: Not OK & Lt; / Py: When & gt; & Lt; Py: Otherwise & gt; & Lt; TD & gt; OK & lt; / TD & gt; & Lt; / Py: Otherwise & gt; & Lt; / Py: Select & gt; ... ... ...

Running ffmpeg in Terminal Linux -

I downloaded the custom directory in my Ubuntu Linux and unziped ffmpeg now I want to run this terminal using FFPAP I like to walk on the windows using the command prompt. But every time it says "ffmpeg: command is not found" my question is how can i run ffmpeg using extracted libraries using the terminal thanks First you need to make sure that the file has the permissions executed ... or it only chmod + x filename You must either be on the executable path or you need it to execute Specify the Path to Eligible What I mean under Windows If you are in the directory with executables then you can type the executable name and this will work ... it is not in the case of Linux. If you are in the executable directory, then you implement this kind of command ./ command . Dot means that you are executing a file in the existing file

java - android: Set time from time picker in dynamic edit text in table row -

I have a table layout with went table rows created programmatically and a programmatic built in each row Editing Text is linked with one of the buttons on a line that has the name of 'EditTextTime' named under the Edit Text 'editTextTime' in each row Eligible, so when you click on it, the time picker dialog Happens after you select the Time Picker that appears in 'editTextTime'. But here's the problem, when the time is selected, then also appears in 'editTextTime' at the same time, if there are two rows selected. The only time I need to select is to set the text in the selected 'editTextTime' of the current row and it does not appear in any other 'editTextTime' than any other line. How will I go about this? The problem (I think) that you named all EditTexts same and setTimeToEditText function " The programmatic creation creation code is out of ", therefore, you have to set onClickListener for each on it. ...

java - JMockit - "Missing invocation to mocked type" when mocking System.getProperties() -

I'm definitely new to JMKit, but I'm getting the system due to some reason. GetProperties (). Thanks for the help of the following posts: I can successfully mock System.getProperty () using JMokit 1.12: @Test Public Zero Testing Systemproperty_string () {last string property name = "foo"; Last string property value = "bar"; New Requirements (System.class) {{System.getProperty (propertyName); Return (propertyValue); }}; AssertEquals (propertyValue, System.getProperty (propertyName)); } but getProperties () eerily similar code for junk jokes: @Test public void testAddSystemProperty_String () {last string propertyName = "foo"; Last string property value = "bar"; End Properties Property = New Property (); Properties.setProperty (propertyName, propertyValue); New Requirements (System.class) {{System.getProperties (); Return (attributes); }}; AssertEquals (1, System.getProperties (.) Size ()); } I get the following exception...

windows runtime - Rotate a CamerePreviewImageSource -

I am trying to rotate a camera preview source to display it (only) in portrait mode: Private async Task Initialisyes () {this.cameraPreviewImageSource = New CameraProjectSource (); Device Information Clearing Tool = Wait. Windows.Devices.Enumeration.DeviceInformation.FindAllAsync (Windows.Devices.Enumeration.DeviceClass.VideoCapture); String Backcamera ID = Devices Frstor default (X = & gt; X. Point Location! = Null & amp; x. Location. Panel == Vindojhkdiwais. Antrtenmentkpanl. Wait back. ID, camera Krenpriwuijhessors. Early Aesink (Bakkamraid); Video encoding properties properties = this hodge preview Image source. Startprwyuesaiansisi (); double width = 1280; double height = 720; This.writeableBitmap = new writable bitmap ((int) width (integer) height); Thiskc apturePreview.Source = this.writeable bitmap; This.writeableBitmapRenderer = new writable bitmap renderer (); This.jpegRenderer = new JPEGRenderer (); available This.cameraPreviewImageSource.previewFrameAvailable...

c# - Search Query with Nest ElasticSearch having AND operator -

I'm trying the following text: "Women were organized" (note " "Has been added for text presentation) All the items I need from the above text include the word" woman "and" organized "from the area stored in elastic index. Did I try: string searchText = "women were organized"; Var filterQuery = Query & lt; T & gt; Rule ("summary text", searchText.Split ('')); Var Results = Client Search & lt; T & gt; (S = & gt; s.Index (IndexName) .Query (filterQuery). Size (1000)); But the result of the above query is found in the form of "woman" or "organized" from the "summary" field, but what do I need is "women and organized" means both lessons "summary text "Be present in the field. Please tell me what it means, I have tried many combinations, but still have not succeeded. Can anybody help nest guru? If you want an exact match for ...

php - CodeIgniter: Connecting two mysql instances -

I want to use two database instances in my CodeIgniter application. I have installed DB1 and DB2 in the application but it always uses the first database socket. $ this-> Db2 = $ this- & gt; Load-> Database ('D2', TRUE); Message: mysqli :: real_connect (): (HY000 / 2002): not connected via local MySQL server via socket '/var/run/mysqld/mysqld.sock' (2) But the second server runs on '/var/run/mysqld/mysqld2.sock', I do not know where it is to use another socket. Please note that even though I still have the first database, I need to merge two replicas, so setting up the defalut socket in php.ini is not an option. To add additional settings, you also need to edit your database configuration file. Example: $ db ['default'] ['hostname'] = 'localhost'; .. $ db ['second_db'] ['hostname'] = 'localhost';

In javascript, is there a way to turn a url into a data-url? -

I want to get a regular old URL and would like to convert it into a data url which encodes the whole file. Is there any way to do this? Alternatively, the question may be: Is there a way to get file object for a given url? (Because then I could use readAsDataURL to call FileReader ). take a regular old URL and convert it into a data url which is full file Encode ... This means that you need to get data from the file. This can be done using a XMLHttpRequest (unless the URL points to you). Then take the loaded data, pass it, and insert it with the feedback header.

javascript - Use same image for link for each row of a table -

I found a link on each line in a table I am trying to add the same image to link The image is only added to the first line and not for the other rows. This is what I have to do. $ (document) .ready (function () {$ ('. Is selected'). Click (function () {var pdtname = $ (this) ARTR ('Data-product name '' ($ (This) .prop ("check") {$ ("# result"). Show (); if ($ (". Is selected: checked"). Length = PRO (" Disabled ", true);} var table = $ ('& lt; table & gt; & lt; table & gt;') AddClass (" .tar "(" data-product name ", PDTNA); var line = $ ('& Lt; tr & gt; & lt; / tr & gt;') AddClass ('rfoo'). Text (PDTNA); ** var link = $ ("#ImgLogo"). Wrap ('& lt ; A href = "javascript: zero (0);" & gt; & lt; / a & gt; '). AddClass (' lfoo '); * * Line .append (link (click on 'click', function) ($ {'...

Implementing a low-overhead interval timer with C++ in Linux -

I am trying to implement a background user-space program that works for every 100ms in Linux, Will do I can do this by using an alarm signal in Linux and the following structure is a way to implement my interval timer. zero timer_handler (int sigm) {printf ("in timer handler! \ N"); } Int main () {struct sign s_action; Straight immirivir timer; / * Set timer * / / * set timer_handler as signal handler for SIGVTALRM * / mimet (& amp; s_action, 0, size (s_action)); S_action.sa_handler = & amp; Timer_handler; Signtion (SIGVTRM, and S_Action, Faucet); / * Timer configuration for 100ms * / timer.it_value = v_sec = 0; Timer.it_value.tv_usec = 100000; Timer.it_interval.tv_sec = 0; Timer.it_interval.tv_usec = 100000; / * Set timer * / statimeter (ITIMIvTual, and timer, tap); While (1); } However, this approach is not the best way to perform an endless loop (in terms of performance). This enhances CPU usage significantly After the start of the background, the perform...

Android: How to/Tutorial for changing ActionBar to ActionBarCompat (Toolbar)? -

I got stuck on this, examined official guidance, etc. What are the steps to replace with any tutorials / actionbars? ActionBarCompat (for toolbar and to support older versions? I've imported AppCom-V7: 21.0., Try getSupportActionBar (); and Toolbar Toolbar = (toolbar) Find ViewById (R.id.toolbar_actionbar); setSupportActionBar (toolbar); Changed theme for the theme in aesthetic theme ... Any common errors or ideas to note? Keep an error like this: JavaklangkRuntimeException: Unable to start the activity ComponentInfo {com.battery.plusfree / com.battery.plusfree .MainCollectionActivity}: android.app.ActivityThread.access android.app at $ 800 (ActivityThrea. on ActivityThread.performLaunchActivity (ActivityThread.java:2212) on android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2271) java.lang.NullPointerException d.java:144) android.app.ActivityThread $ H.handleMessage (ActivityThread.java : 1205) android.os.Handler.dispatchMessage (Handler.java:1...