Posts

Showing posts from January, 2015

jailbreak - Install my .ipa on a Jailbroken iOS device -

OK, basically this is what I need (and I'm not an expert in IOS related stuff, so I / O> My iOS Developer Account has expired (Therefore, I can do it I want to get my compiled .ipa and I'm installing it on my jailbroken iPad (iOS 7 is running) Is there any proper way to do this? This Step 1. Launch Cydia, Search for AppSync (Match Versions for your iOS: Example: AppSync 7.0+) Step 2. Install it. (Now iTunes will allow you to sync any IPA on your phone) < strong> (If search results do not show episodes 7.0+, do the following) Tap on the Manage button. Now Click on the Sources button. Edit Touch the switch to button and then tap Add. Now the application for this repo ???? & Gt; repo.hackyouriphone.org Once the repo has been added, tap Return to Cydia. Tap on newly added repo. Search for AppSync for iOS 7.0+ and just touch it to start the installation process. Step 3. Now sync your IPA to your phone using iTunes.

java - Apache HTTPClient HttpGet returning nothing -

I am requesting a GET with version 4.3.3 of Apache HTTPER, such as: HttpGet httpGet = New HttpGet ("http://www.revenue.ie/en/tax/it/forms/med1.pdf"); CloseableHttpClient Client = HttpClients.createDefault (); CloseableHttpResponse response = client.execute (httpGet); Client.close (); The response status code tells me 200, and the content length returned by response.getEntity (). GetContentLength () 1213954, but returned from the call as "InputStream" : response.getEntity (). GetContent () reporting of 0 bytes is available. I have been receiving such calls to successfully recover and parse the other URL's HTML but there is some difference in it because here is the file content in which I am interested? client.close () Tried to retrieve InputStream before reacting response.getEntity (). GetContent () .

c# - Attribute 'SelectQuery' is not a valid attribute of element 'SqlDataSource' -

I work on a project and now I get an error. I have a table userata and I want to connect to a database for registration. Want to see data from databases on espx page and page manager This error is: Type 'System.Web.UI.WebControls.SqlDataSource' is not a public property named 'SelectQuery' ... \ Manager .aspx Code: & lt; asp: SqlDataSource id = "SqlDataSourceRegistration" runat = "server" connection string = "& lt;% $ connectionString: Registration extension string% & gt;" SelectCommand = "SELECT * FROM [UserData]" SelectQuery = "& lt;% $ Connection: Strings: Registration Connection% & gt;" & Gt; & Lt; / ASP: SQLDataSource & gt; Here you have an example where you can see that SqlDataSource & lt; asp: sqlDataSource id = "SqlDataSourceRegistration" SelectCommand = "Select *" connection string = "& lt;% $ connection from use

javascript - Use native node name for a Polymer custom element? -

I have a custom polymer element in which there is an array of items, they provide them in the form of a table. I have a custom Want to add element which handles the rendering of each row in the table, but the custom element is not allowed in HTML at that point where & lt; Tr & gt; will usually be added. / P> Permission: & lt; Table & gt; & Lt; Tbody & gt; & Lt; TR & gt; & Lt; TD & gt; Example & lt; / TD & gt; & Lt; / TR & gt; & Lt; / Tbody & gt; & Lt; / Table & gt; Not allowed: & lt; Table & gt; & Lt; Tbody & gt; & Lt; Custom line & gt; & Lt; TR & gt; & Lt; TD & gt; Example & lt; / TD & gt; & Lt; / TR & gt; & Lt; / Custom line & gt; & Lt; / Tbody & gt; & Lt; / Table & gt; I have seen (like "custom-row"> ), but. I present the whole table in a custom presentation or div s ( display: table , displ

c# - How can I use a different ToString method in a derived class? -

I have a list of cars and I display a list in a list box using an overridden tooling method. I have received classes for cars (like hatchbacks), I need to display more information about the derived car model without losing the base tostring method. I list the cars in a listback How can I show and how can I show "hatchback" details in a separate list box? If I override the toasting in the model class, then I override the details, I am also trying to display for cars. Thanks Sorry, C # My Cars Method Public Override String Toasting () {Return Name + "[" + this.GetType () Name. Toastring () + "] is called" + type; } But when I make a derivative class, I sometimes want to use toasting from the forum and not always from the same base class. The answer in brief is that what you describe can not be done in a derivative class virtual After override the method, you can not use the version in the original class from the derived class. I would c

C++ typedef, map, iterator -

Can someone with a repeater problem help me? I'm getting something like this: SomeClass {public: creator creates a new t_Records // destroyer m_RefPtr deletes or decreases m_RefCnt // copy creator gives new obj to m_RefPtr m_RefPtr provides //, increases m_RefCnt bool search (const string & amp;;); Private: // some private variable structure t_Records {// int m_RefCnt for reference calculation; // References Counter Typingf Vector & lt; Int & gt; M_Vec; Typedef Map & lt; String, m_Vec & gt; M_Map; m_Map m_RecMap; T_Records (zero) {m_RefCnt = 1; }}; T_Records * m_RefPtr; }; // Finds m_RefPtr's map, TRUE gives bool SomeClass :: search (constants string & keyword) {// How to create and use an iterator of m_Map ??? Back true; } How do I mention, as I am having problems with creating struct (outside map) struct outside the map itater. The map is initalized and has some records in it. Thanks for your reply like this:. // think m_RefPtr starts

ios - Capture UIView without using renderInContext: -

I want to make video from my screen and for this I am going to capture the scene, but I do not want to Due to use renderincontex: I am now using drawViewHierarchyInRect: , but it is limited to iOS 7 and my app also supports earlier versions of iOS I drawViewHierarchyInRect: ? UIGraphicsBeginImageContextWithOptions (self.bounds.size, NO, 0); [Self DrawHearActinator: After Self Screen BoundUpdates: Yes]; UIImage * image = UIGraphicsGetImageFromCurrentImageContext (); UIGraphicsEndImageContext (); I think you do not want to use renderInContext Because it is less efficient, but for iOS versions before 7 years, you should use this technique (because if you try to use drawerearyer in iOS versions before 7.0, The app will crash). Therefore, there is a presentation that uses drawViewHierarchyInRect , but when it is available, but not renderInContext when: UIGraphicsBeginImageContextWithOptions (Self.bounds.size, no, 0.0); If: ([self answer: TSE: Selector: @Sillecto

memory management - Where is object reference variable (inside a ) stored? -

Now I am learning JVM memory models. I have a question: package com; Public Class Test Allocation {Private Static Final Ent _1 MB = 1204 * 1024; Public static zero main (string [] args) {testAllocation (); } Public static zero test ratio () {byte [] allocation 1, allocation 2, allocation 3, allocation 4; Allocation 1 = new byte [2 * _1 mb]; Allocation 2 = new byte [2 * _1 mb]; Allocation 3 = new byte [2 * _1 mb]; Allocation 4 = new byte [2 * _1 mb]; }} So, where is reference allocation 1, allocation 2 stored? Since testAllocation () is a stable method, therefore, the variable method fields inside this function? But Stack is said every time in a function, it is stored in push / pop operation. So, allocation1, allocation is stored in the heap testAllocation () ? But one thing is clear, that is, array values, is not it? After the the Java Stack is stored in the static method where its variable are stored. At the end of the stack testAllocation () there will be f

android - How to change text in host application from sony smartwatch 2? -

I'm trying to trigger a button click on a smartwatch and then want to change the text in the host application in Android phone . I tried to send a broadcast intent to the broadcast receiver and started a service that includes a way to change the text in a host application. However, the changeText () method is not working. I am able to start a service, but I am not able to change the text. Please see what is wrong with my code. It would be nice if you can give a brief example of how to broadcast the host application from smartwatch to the best practice. My control extension class class SampleControlSmartWatch2 provides control extension {// Other code Object Elements on Public Zero (ControlObjectClickEvent Event) {Intentional Intent = New Intent (Sample Connection Service .INTENT_ACTION_BROADCAST); Intent.putExtra ("name", "something"); MContext.sendBroadcast; }} My broadcast receiver extends the public class extension ratio broadcasts receiver {

jquery - When the content of Thickbox is bigger than browser size - no scroll bar appear in browser -

How to handle, when content of Thickbox is large, browser size - no scroll bar appears in the browser when the thickbox Showing itself big browser size and it does not display scroll bars, then there is no way to display previous sentences in Thumbar such as Submit or Cancel button? I solved an Internet search - I did not find anything that I applied I have put this code in thickbox.js, but ignored it: / P> TB_with = 750; TB_height = 750; Try with overflow: scroll down; Or overflow: auto; On the original element.

javascript - copy checkboxes marks to another form -

मेरे पास 2 रूप हैं: foo: < पूर्व> & lt; फ़ॉर्म आईडी = "foo_form" method = "post" action = "foo" & gt; & lt; इनपुट वर्ग = "foo चेकबॉक्स" id = "foo_select_1" नाम = "आईडी []" प्रकार = "चेकबॉक्स" मान = "1" / & gt; & lt; इनपुट वर्ग = "foo चेकबॉक्स" id = "foo_select_2" नाम = "आईडी []" प्रकार = "चेकबॉक्स" मान = "2" / & gt; & lt; इनपुट वर्ग = "foo चेकबॉक्स" id = "foo_select_3" नाम = "आईडी []" प्रकार = "चेकबॉक्स" मान = "3" / & gt; ... & lt; इनपुट प्रकार = "सबमिट करें" मान = "एक्शन 1" / & gt; & Lt; / प्रपत्र & gt; बार: & lt; form id = "bar_form" method = "post" action = "bar" & gt; & lt; इनपुट वर्ग = "बार चेकबॉक्स" id = "bar_select_1" नाम = "आईडी []" प्रकार

Copy files and folders in several Powershell versions (2.0, 3.0-4.0) -

I have a PowerShell script in version 2.0 (Windows 2008) but this is for me in PS 3.0 - 4.0 (Windows 2012) Fails Fails because no files are found when there is no files. And I have a PowerShell script in version 4.0 (Windows 2012). But it fails for me in PS 2.0 (Windows 2008). Fails because the directory switch is not recognized. The script contains files-folder copy functions. This code for Powershell 2.0 function CopyWithFilterOlder ($ sourcePath, $ destPath) {$ Exclude = @ ('ThumbS.DB.') #This function Call again, using the hair folder of the current source folder. Include Get-ChildItem $ sourcePath- $ Excluded | Where-object {$ _. Length-EC $ faucet} | % {CopyWithFilterOlder $ _. Full name (join-path-path $ destPath -ChildPath $ _. Name}} # create the destination directory, if it is not already present (! (Test path $ destPath)) {new item path $ destPath -ItemType directory | Out-null} # Copy hair files from source to destination Get-ChildItem $ sourcePath- $ E

Funs names in Erlang 17 -

Erlang 17 was released. And according to this: Fun now can be named No examples given. Any idea how to assign a name to fun in 17? Which Armstrong explains about it with an example 1 & gt; F = Funny F (0) - & gt; 1; F (n) - & gt; N * F (N-1) End # Fun You must first pass an anonymous recursive call to the function as an ARG (think of Y-coordinator). 1> F = Funny (F, 0) - & gt; 1; (F, N) - & gt; N * F (F, N-1) End # Fun

javascript - get value of input in casperjs -

Hi all I would like to know how to get an input value with the capacitors This is my html element & lt; Input type = "hidden" name = "key" value = "new" and gt; This is what I've tried: visible = 'user / registered'; casper.test.begin ("activation account", 5, function register (test) {casper.start (webroot + view, function () {}). then (function () {retrieve data from this.echo ("hidden input") ActivationKey = this.evaluate (function () {return __utils __. GetFieldValue ('key';;}}}} then (function () {this.echo ("account with key" ActivateKey + "\" "," COMMENT "); window.location = webroot + activationKey;}); casper.run (function () {this.echo ('account successful activation', 'success' ) Exit (); test.done ();});}); Casper.viewport (page wide, p. Hi); In this case return null I have also tried: activationKey = __utils__ getFieldValue (&

python - Check if IP is in list of IPNetworks using netaddr -

If I have many problems without statements I pseudo code: < pre> ips = [... list of approximately 1000 IP] cidr_list = ['192.168.10.0/24', '10.10.10.0 / 24 for IP in IP ',' 192.168.3.0/ 24 ']: If the IP is cidr_list: Print IP Does anyone know that this is the correct way to use IPadresser and IP networkwork from NetAdractor? You can use the Google ipaddr package for this < pre> pipe installation ipaddr from the command line

c# - Socket receive timeout throws a delayed exception -

In C #, I have a very simple server / client that is set to the timeout when getting the customer upto 500 ms This is the time, I hope that it throws an exception and does this, however, I hold it after 500ms, which is total up to a total of seconds. To check that I might have a slow machine, I test how long it takes to throw an exception, it's true that there are some snippets here. Server thread: zero serverTradeProject () {(socket server = new socket (Address Family.InterNetwork, SocketType.Stream, ProtocolType.Tcp)) {server.Bind (New IPandpoint (IPADress percie ("127.0.0.1"), 12345)); server.Listen (10); (Socket Acceptable = Server. Accept ()) using {// Wait Waiting time is so that customer times out System.Threading.Thread.Sleep (5000); accepted.Shutdown (SocketShutdown.Both); accepted.Close (); }} Receive trial timeout (failed): public should shouldnotExceedConnectionTime () {thread s = NewTrreadProc; s.Start (); (Var client = new socket (using Family

python - How do I define a class where the arguments given to it on instantiation becomes its instance variables? -

I want to create a square where the properties of its frequency are defined immediately. At first I thought I should do something like this, class testdata (object): # through example http://stackoverflow.com/questions/2641484 / class-dict-self-init-args def __int___ (auto, * args, ** kwargs): super (testadata, self) .__ init (__) for arg in arg: self.arg = arg But this argument will not do the same property as self.arg and all arguments. With revised comments with suggestions, I came to the solution that works for me: class testdata (object): # http://stackoverflow.com/questions/2641484/class-dict-self-init-args def __init __ (self, * args, ** kwargs): Super (testadata, self) .__ init (__) (self) .__ dict __. Update for arg in args (kwargs): setattr (self, arg, arg) And if further characteristics are needed then can be added after urgency, which is (Instant, AGR, VAL)

eclipse - Import android project into new workspace -

How do I import a new project into my new workspace with a new installed version? Just a complete workspace Simply copy the folder to your workspace folder, Go to the small project and import the exposures on the left and import it. This is about it.

kineticjs - Detect collision between shape and Kinetic.Group -

The shape I am taking with width: 40 and with height There is a rectangle: 4 , and it is made that hard to find width = height (you can see the collision between large rectangles) when it becomes easy My cases In, I have to find out the collision between this rectangle, and add another rectangle group, then add a small one to the group. Here's a fiddle to understand more: It detects collision from bottom, and on the right side of the group, but left and upper boundaries are not well "detected". OK, now you've re-applied your code to predefine your code. . You can use this code. To assign a handler to a group, or to move the clone back to the top of the original window element. A demo: clone.on ("dragend", function () {var pos = stage.getPointerPosition (); var x = parseInt (pos.x) ; Var y = parseInt (pos.y); var GPO = group.position (); var gSize = group.getSize (); if (x> GPEx & amp; amp; amp; amp; & amp; x & lt; GPos.x

java - Creating word pairs, triplets etc for evaluation in Bleu -

I need to create a list of words, triples, etc. to evaluate in the BUL metric. I Bullu Unigram (one word) Begins with and goes to N-Gram - N is being specified at runtime For example, the sentence "Israeli officials are responsible for airport safety" < P> This will be a list of words for unigrams Officials of Israel Officers Airport are responsible for airport safety There are relevant trigrams Officials of Israeli officials are responsible for the airport's responsibility for the AIPAR. I've coded the working blade, which forces hard code 4 to NGR and compels the calculation of cruelty Unigram. It's ugly hell, and besides, I should be able to supply n at run time. Snippet trying to generate pairs / triples etc. - string current = ""; Int temp = 0; (Current = current: "+ + Goldwords [i]; while (temp & lt; N_GRAM_ORDER) {current = current + ":" + goldwords [temp + i]; temporary ++;} gold.grams.add (current

javascript - Changing navigator.userAgent using Chrome Extension -

I am trying to overload Navigator.User Agent using a simple Chrome extension. As content scripts work in different EVs, I tried to create a script element and write arguments in this one. It comes from the background page of the extension chrome.tabs.query ({active:! 0}, function (tab) {var x = "window.navigator .__ definedgator___ ('useragent "," ("+" Back) Mozilla / 5.0 (Linux; Android 4.2.1; N-US; Nexus 5 Build / Jop 40D) "+" Apple WebKat / 535.19 (KHML, like GECO) Chrome / 18.0 .1025.166 Mobile "+" Safari / 535.19 ';}); console.log (navigator.userAgent); "(var i = 0; i & lt; tabs.length; i ++) {var code =' var s = document.createElement ("script"); s.text = "'+ x +'"; document.head.insertBefore (s, document.head.firstChild); '+' Vigator.usergent = "s"; console.log (navigator.userager); '; // Injected in the tab of choice - currently everything in. Chrome.tabs.e

jdbc - Searching a integer type database field through java -

I want to search the database by giving the voucher number as the criteria search criteria, but the required number is integer, so I do not Suggest the following code, some other code for it. Try {string sql = "item type"}, select item type as MD, by MD_, model 'model', sell_price 'sailing Price ', buy_price as' Buy Price', the date of purchase as' purchase date ',' voucher no. ' As the vouchers, vouchers as the voucher date, record_no as 'record number' From purchase "where vouch_no = ?; Ps = con.prepareStatement (SQL); ps.setstring (1, txt_vouchno_p.getText ()); Rs = ps.executeQuery (); Table_p.setModel (DbUtils.resultSetToTableModel (Rs)); } Hold (pre-SQLException) {JOptionPane.showMessageDialog (empty, "error:" + east);} hold (exception before) {JOptionPane.showMessageDialog (zero, "error:" + east);} Change the value of txt_vouchno_p.getText () using an int and according to your the

c++ - Retrieve feature type from OpenCV FeatureDetector -

In OpenCV, it is very common to name a cv :: FeatureDetector feature : cv :: Ptr This is a factory pattern, cv :: FeatureDetector is an abstract class. Then, given a variable type of cv :: Ptr , is it possible to retrieve the feature name? This is "SURF" in my example. class = "post-text" itemprop = "text"> cv :: algorithm one name () gets the method which gives the algorithm name in the string. In the case of your surf detector, named () returns Feature2D.SURF which is a human-readable form In general, this string is algorithm-type . Example-Name , although there is only one-word description in many things, for any feature detection algorithm, the algorithm-type prefix always Feature2D < / code>. If you need an exact string match, you can parse it manually. Auto Surf = CV :: Feature Detector :: Create ("Surf"); Auto en = surf-> Name (); Std :: cout & lt; & Lt; N & lt; & Lt; Std

c++ - Pointers getting allocated the same memory space -

I am writing a program in C ++ which uses the following function that has two character pointers (of course Working as a telegram) Its formal argument: zero-techward (four * dstr, const char *) {int i = 0, j = 0; printf ("\ n% s", dstr); getch (); Exit (0); While (i.lifa (from [i]) // before the positioning I ++ in line; do {dstr [j] = to [i]; J ++; I ++; } While (from Islafa ([i])); dstr [j] = '\ 0'; // terminating a word with a nonsense character}; My problem is that the two strings are DST and they are allocated to the same memory space. As a result, the changes being made in DST are being reflected in which I do not want to don. So, to make sure that they have allocated different storage spaces? The only case that does not handle the code that you provide satisfactorily is the case that is dstr> From & amp; Amp; dstr & lt; + strlen (to) to . To fix this, you have three options: You write your function in a manner that ensures tha

php - One mysql query between three table -

मेरे पास तीन तालिकाओं हैं 1. उपयोगकर्ता - उपयोगकर्ता _id 2. पुस्तकें- book_id-book_name -यूसर_आईड 3. पसंद -अन्य_यूसर_आईडी-बुक_आईड मुझे केवल 'users.user_id' पता है और मुझे पुस्तकों की सूची में पसन्द की गई तालिका से बुक नाम और प्रत्येक पुस्तक की गणना करना है। / p> नोट: उपयोगकर्ता पुस्तकों और अन्य उपयोगकर्ताओं को पसंद करते थे। इसलिए परिणामस्वरूप JSON सरणी को पसंद आएगा .. I इनपुट mysql केवल user_id = 10 और यह प्रिंट करता है .... {उपयोगकर्ता आईडी: 10, उपयोगकर्ता नाम: cemsitcan, बुक नाम: नमूना, बुक पसंद आया: 120 बार।} {उपयोगकर्ता आईडी: 10, उपयोगकर्ता नाम: cemsitcan, बुक नाम: नमूना 1, पुस्तक पसंद है: 10 बार।} {उपयोगकर्ता आईडी: 10, उपयोगकर्ता नाम: cemsitcan, बुक नाम: नमूना 2, किताब पसंद है: 123 बार।} आपको इस के लिए उपयोगकर्ता तालिका की आवश्यकता नहीं है अगर आप इस क्वेरी का उपयोग करते हैं: SELECT *, (SELECT COUNT (`अन्य_यूसर_आईडी`)` पसंद 'कहां से `पुस्तकें'। 'बुक_आईडी` =' पसंद '।' बुक_आईडी`) एएस` Likes_Count` `पुस्तक से` `उपयोगकर्ता _id

reverse - How to make a fact work both way in Prolog (takes arguments in any order)? -

I want to define the facts that are correct in both ways (they all have the faith of 2). I found success with the fact that the "opposite" relationship was expressed by this fact: Contrast Deficiency (Plus, Loans). Contrast (X, Y): - Contrast Deficit (Y, X). Contrast (X, Y): - Inverted decline (X, Y). I am trying to create a simple equation solver, and I would also like to define if A = B then B = A I just can not write: < pre> equal (a, b): - equal (b, a). Because I exit the local stack error. Although I can not do that as I did with the "opposite" fact because on some rules it is necessary to work "equal" ("opposite" only got input from the facts). Is there any way I would like to avoid defining the two rules of "equal"? Edit: I just want to declare general mathematical facts to see if I have to solve other more complex tasks. I can use Prolog, where I do not know the mechanism to solve the simple facts only.

How to upload files to EC2 using a C# .NET application -

मैं scp को एक निजी कुंजी ( .pem ) scp -i & lt; पथ निजी कुंजी के लिए & gt; "स्थानीय फ़ाइल" "उपयोगकर्ता @ होस्ट": / पथ यह लिनक्स पर ठीक काम कर रहा है, लेकिन मुझे इसे नेट अनुप्रयोग में एकीकृत करने की आवश्यकता है। एक विकल्प कमांड लाइन का उपयोग करना है, लेकिन Windows पर scp के लिए कोई सटीक विकल्प नहीं है जो कि SSH-2 निजी कुंजी स्वीकार करता है। आप एसएफटीपी को फ़ाइलों को ईसी 2 में अपलोड करने के लिए उपयोग कर सकते हैं, आपको एससीपी को प्रतिबंधित करने की आवश्यकता नहीं है। वैसे भी, WinSCP। NET विधानसभा एससीपी और SSH-2 निजी कुंजी। WinSCP के साथ EC2 से कनेक्ट करने के विवरण के लिए, देखें: उदाहरण कोड को यहां देखें: कमांड लाइन समकक्ष के लिए, आप PSCP का उपयोग कर सकते हैं: WinSCP में भी कमांड-लाइन इंटरफेस है:

linux - Problems setting CPU affinity in C -

I am trying to take the time to run the CPUID instruction. Source: #include & lt; Stdio.h & gt; # Include & lt; schedule.h & gt; Cpu_set_t mask; CPU_ZERO (& amp; mask); CPU_SET (0, and mask); Shade_setfinity (0, size, and mask); Static inline unsigned long tick () {unsigned long d; asm volatile ("rdtsc": "= a" (d)); Return D; } Zero cpuid (zero) {int i; For (i = 0; i! = 5; i ++) {ASM vapor ("CPUID"); }} Int main () {long long beef; Long back; Long time different; bef = tick (); CPUID (); Back = tick (); dif = back-bef; Printf ("% d \ n", beef); Printf ("% d \ n", behind); printF ("% d \ n", dif); Return 0; } I am now compiling using the following GCC-D_GNUI-source -O test test.c Get errors on the code that is not a file! For example: test.c: 6: 1: error: expected identifier or '(' first 'to' test.c: 6: 1: error: expected identifier or '(' First 'while' tes

php - (SOLVED) Little issue with Yii CDbCriteria Joins -

I have the following tables aliados (trying to recover the archive from the main table and i) aliados_direccion whose aliados_id is a The foreign key is in the form of aliados_centro_medico which also has aliados_id as a foreign key and could possibly make many UK connections with the following table. centro_medico aliados_direccion and centro_medico have a column called "parroquias_id" which comes from a separate table that does not have any value for this query. I grid depends on me on some of the "Aliados" show if they aliados_direccion or pertaining to a aliados_centro_medico where aliados_direccion.parroquias_id or centro_medico.parroquias_id an array that user logs in that is. The array is fine and mysql reads it without any problem, the issue is in the actual query. $ criteria = new cdccitrea; $ Benchmarking & gt; Selection = 'one *.'; $ Benchmarking & gt; Aka = 'one'; $ Benchmarking & gt; '. (From the Aliados_dire

javascript - Advance internal array pointer to next record to fill jquery function to use insertAfter -

I am a jquery newbie and I am trying to create a jquery function with the information supplied with php. I'm sorting the div to display in the order of value with the insert object. (What's an easy / easy approach?) My point is that I can not advance the pointer to advance on the next record to fill my foreclosure loop. My PHP: $ my_array = array ("peter" => "100", "LOIS =>" 75 My jquery: > $ (Document) .ready (function () {var peter = $ ("# peterDIV"); var lois = $ ("# loisDIV"); var brian = $ ("# brianDIV"); & lt ;? php foreach ($ my_array as $ x = & gt; $ x_value) {echo strotler ($ x) ".interval (". strtolower ($ x) ");";}}? "gt;}); Result: peter.insertAfter (peter); lois.insertAfter (Lois); Brian.insertAfter (brian); I have the next () and array_shift () but I think my syntax is off. Edit Desired Results lois.insertAfter (peter); Brian.ins

jquery - What is the difference between long and regular polling? -

Here, every 30 seconds , I make an AJAX call to update my DB I am setInterval (function () {$ .ajax ({url: "server", success: function (data) {// update your dashboard gauge salegadget.Setview (data.value); }, Data type: "Jason"});}, 30000); Another question - if the server takes more than 30 seconds to give a negative feedback, what will be the negative side? Call sends another request to # 1, while Call # 1 is being updated - updating DB in latest value. long polling (function survey () {$ .ajax ({Url: "server", success: function (data) {// your dashboard gauge sales update PleaseGuage.setview (data.value);}, datatype: "Jason", complete: selection, timeout: 30000});}) (); The AJAX call is sent, invites itself every 30 seconds, and once the call is completed it calls itself again, whereas it looks more synchronous, What if we send a call, at the end of 30 seconds (when I'm waiting to come back for the first time)? We now

java - Validating the amount of command line arguments -

I'm trying to validate that there are only three arguments passed in this program I use two line integers I'm trying to pass that looks like 23 23+. But I want an error, if they debate less than three or more than three logic as it is now, this error message gives a message when there are more than three arguments but less than three, no help will be great. Public class arithmetic {public static zero main (string [] args) {// variable first set number and second number int firstNumber = Integer.parseInt (args [0]); Int secondNumber = integer Paracet (Argos [1]); String arithmetic = args [2]; Int length = args.length; If (length! = 3) {System.out.println ("You seem to enter an int, int then, +, - sign an operation like x or /."); Return; } If (arithmetic.quals ("+") {int addition = firstNumber + secondNumber; System.out.println (Args [0] + "+ + Arg + 2 + + + + Args [1] +" = "+ Extra); Int total = String.valueOf (extra) .length (); System.ou

sql - Selecting all with a length of less than 8 characters, and not null, and not empty -

How do I select all the values ​​that are in length less than 8 characters, and not a zero value and not empty Is value? This is what I have, but it is still pulling in empty values ​​ select different alphax, case when LAN (termdatex) 8 then the termdatex end termdatex as the table where the termetax is zero and the termdatex is not! = '' Your problem is in your case expression Clearly, when is not returned as null in any of the sections, then nothing is handled. Here, since you do not filter them in where , return any string with 8 or more characters as null as case Expression To correct this, you can move all of your logic to the where section: select alphabetically, some decad termetaxes, Where the termdatex is not and nor the wording! = '' And LAN (termdatex) & lt; 8

Reduce a sparse matrix in numpy -

It seems that I'm missing something very basic. I have a large square matrix, which is mostly zero. What I want to reduce is the matrix in which all rows and columns can be with zero-zero entries. For example: 1 1 0 1 1 1 0 1 0 0 0 1 1 0 1 The following should be done in the following: <<> 1 1 1 1 1 1 1 1 1 Is there a quick way to do this? How about something like this: & gt; & Gt; & Gt; arr Array ([[1., 1., 0., 1.], [1., 1., 0., 1], [0., 0., 0., 0.], [1., 1 ., 0., 1.]])> Gt; & Gt; & Gt; Mask = (arr == 0) arr = arr [~ np.all (mask, axis = 0)] arr = arr [:, ~ np.all (mask, axis = 1)]> gt; & Gt; & Gt; arr Array ([[1., 1., 1.], [1., 1., 1.], [1., 1., 1.]])

r - Objective function of an SVM -

I used the svm function in the e1071 package of RF software, using the variable selected by my feature selection method To model the data. I have received predictions from this model using the predict.svm function in the same package. I want to calculate the value of the objective function of SVM model using R software. how can I do this? Below is my code for my first feature selection technique P1 < -Fold1T $ Class_NASQ InfGainF1 & lt; - info.gain (p1 ~., Fold1T [, -20]) subset & lt; - cutoff.k (InfGainF1, 8) f & lt; As.simple.formula (subset, "P1") ModelInGF1 & lt; -svm (as.factor (P1) ~ NSDQ.COMP + SP 100 + SP500 + NYSE.COMP + NYSE.AMMKT + RSEL.2000 + Allward + HG.SEGN, Data = Fold 1 AT [, - 20], Colonel = "Radial", Gamma = 0.5, Cost = 16) Estimated GF1 and LT; -Predatekate (Model INGF1, NewData = Fold 1V [, - 20]) ######## Accuracy ######## Illusion Matrix (Estimate Engineer 1, P1) < / Pre> thanks In 2010, learning about

User annotation overlay in HTML5/JavaScript -

I have an application that generates a report page automatically. To wit. An HTML5 webpage with plots and tables. In some cases users need to mark certain details in the report, so they take screenshot / copy paste content in Microsoft Word or similar and then edit it. I would like to enable the user to make annotations at the top of the report in the browser. For example, draw a circle at the top of a spike in a plot. Or pointing to something important, insert an arrow and add a comment next to it. They can save reports for PDFs, including print / their annotations. It should not be so difficult to do this by using canvas for drawing and so on. But I think there should be some framework / library which I can not find. Do you think it is understandable and do you know any library that supports it? I think you mean something.

vbscript - Allow uploaded SharePoint files to be marked as "Checked-In" -

I just wrote a VBSPTP that uploads files to a shared folder. It works. The problem is that the default status of these files is "check out" so manually select these files "check in" on the front-end. It is my belief that defeated the purpose of my script is there a way around it? Any kind of help would be greatly appreciated. Thank you. Jake P.S. Here is a sample code. Set url = "http: // portal / projects /" objXMLHTTP = CreateObject ("Msxml2.ServerXMLHTTP.3.0") objADOStream = CreateObject ("ADODB.Stream") of ObjADOStream with. open. Type = 1 Load Framefile ("C: \ VBScripts \ SP \ 2014_Test_IC.txt") with termination content = objADOStream. Read objXMLHTTP.open "PUT", URL & amp; "2014_Test_IC.txt", Wrong, "Username", "Password" objXMLHTTP.send Content WScript.Echo objXMLHTTP.status & amp; ":" & amp; ObjXMLHTTP.statusText objADOStream.Close This can be

python - Django, replace adding an extra ? -

In my demo model, I am doing some HTML input. HTML is showing fine except during an output except for an output Ive using some shortcuts for things like "extra spaces" to use admin for less technical wishing people: Ie: If they have a & amp; Call it & amp; Emsp; is replaced with .replace ("& amp;", "& amp; emsp;") Hoover, My queries are being output instead: & amp; Emsp; Emsp; Who has confused me Any ideas why I am getting an additional EMSP ;; It's not looping and place & amp; A second time. Thank you. Assume that you have "& amp; emsp" already in your html? OK, .replace ("& amp; e," & amp; emsp; ") will be created : & amp; Emsp; EMSP; You need to make sure that you replace that method which is already called "& amp; emsp".

Matlab cell2mat error: all contents of the input cell array must be of the same data type -

I'm trying to apply the cell2mat function to a cell with a string that is empty or integer I get this error That the contents of the cell are not the same data type, even when I run "iscellstr" on an index with an empty string and an index with an integer sting, returned both 1, to the right. What else can be caused by this error? Try to use instead of cell 2 mat. You have empty cells [] instead of the empty string '' . Example: & gt; & Gt; ; M = {'123'; ''; []; '-2'} M = '123' '' [2] Notice is empty cells and empty string. Cell2 matte increases this error: & gt; & Gt; All the contents of the error input cell array using cell2 matte (M) cell2 matte (line 46) should be of the same data type. but str2double returns: & gt; & Gt; Str2double (M) ans = 123NNNN-2

python - have some wondering about matplotlib -

आयात के रूप में nppy आयात matplotlib.pyplot plt xx1 = np.random.randint (1,7,100) xx2 के रूप में = np.random.randint (1,7,100) पासा = xx1 + xx2 plt.hist (पासा, मानद = सच) plt.show () क्या मानदंड = सच है एक कथानक करते समय, हमें plt.figure () के साथ पहले खोलना होगा? matplotlib का उपयोग करके एक ग्राफ आकर्षित करने में सक्षम होने के लिए, क्या इसे एनपी सरणी होना चाहिए या यह नियमित सूची के साथ काम हो सकता है? जैसे। श्रेणी (100) । यहां दस्तावेज़ देखें: आपको हमेशा plt.figure () को कॉल करने की ज़रूरत नहीं है। आपके एक उदाहरण के रूप में प्रदर्शित करने के लिए आपको इसे एक एकल आकृति का पता लगाने की आवश्यकता नहीं है। हालांकि कई आंकड़ों के लिए (उपखंडों के विपरीत) आपको इसके उपयोग की आवश्यकता होगी। हां, यह नियमित सूचियों के साथ काम करेगा। < / Ol>

Store paragraph of text in variable C++ -

I am trying to write a program that takes the user's input and stores the entire paragraph in a variable . However, if the user enters: "Hello, this is some text." It only gives "hello" anybody can help? Thank you! #include & lt; Iostream & gt; # Include & lt; iomanip & gt; using namespace std; Class GetText {public: string text; Zero user text () {cout & lt; & Lt; "Please type a message:"; Cin & gt; & Gt; Text; } Zero to_string () {cout & lt; & Lt; "\ N" & lt; & Lt; "User text:" & lt; & Lt; "\ N" & lt; & Lt; Text & lt; & Lt; Endl; }}; Int main () {GetText test; test.userText (); Test.to_string (); Return 0; } You can use the user to read the entire line from the input: / p> std :: string text; Std :: getline (std :: cin, text);

php - This exec() is secure? -

मेरे पास यह कोड है: $ cmd = escapeshellcmd ($ _ GET ['command' ]); $ Cmd2 = escapeshellcmd ($ _GET ['कमांड 2']); Exec ("प्रोग्राम"। $ सीएमडी। $ Cmd2); और मुझे पता है कि किसी भी व्यक्ति को इसे html फॉर्म के साथ उपयोग करने की अनुमति देने के लिए सुरक्षित है? नहीं , escapeshellcmd या escapeshellarg का उपयोग न करें आपको सुरक्षा का एक गलत अर्थ प्रदान करें। यदि आप दृढ़ हैं तो मैं निम्नलिखित चर्चा को पढ़ने की सलाह देगी: P>

C fork not exiting -

I am quite new to C and I have given the code below for some shell scripts (nsdc.sh) every 10 Written in seconds. For some reason this shell script is calling multiple times (in a loop) It seems that _exit is not being called, can anyone explain this behavior to me? #include "dynzone.h" void dynzone_run (struct nsd * nsd) {while (1) {pid_t pid = fork (); If (pid == -1) {log_msg (LOG_ERR, "Fork zone failed to reload"); } And if (pid == 0) {/ * CHILD * / log_msg (LOG_NOTICE, "exec reload"); If (system ("/ home / edns / jarno / v1 / nsdc.sh reload") == -1) {printf ("reload error:% s \ n", strerror (errno)); } _ext (1); } Sleep (10); }} Void dynzone_spawn (struct nsd * nsd) {pid_t pid; Pid = fork (); If (pid == -1) {log_msg (LOG_ERR, "fork dygen failed"); } And if (pd == 0) {/ * CHILD * / log_msg (LOG_NOTICE, "spanned dyonjon"); Dynzone_run (NSD); / * ENOTREACH * / Exit (0); } / * Parent * / return; } Thanks

node.js - Templates are not removed once they are replaced -

So I'm using the meteor for a while and after updating 0.8, a large amount of my template failed Are happening because already sung in the background are active in the background How can I remove a template with blaze? I'm getting the effect of flicker (the template renders and 4-5 times actually re-presents faster.)

javascript - Accessing audio files from an array of Objects -

I'm trying to add an audio aspect in an HTML / Javascript quiz (see JSFiddle :) I have an empty audio tag: & lt; Audio id = "myAudio" src = "" control & gt; & Lt; / Audio & gt; Which I want to play with my array 'question' property: var allQuestions = [{Question: "http: //www.w3schools. Com / html / horse.mp3 ", option: [" 3 "," 5th "," 4th "], correct answer: 2}, This is the format of my audio player Does not work in. My function is clearly incorrect in some way to send data to the audio player from the object that does not load anything. Can someone help me in some amount of light but I am doing something wrong? This is not the full answer but see if it takes you in the right direction. Actually you can change the audio src via javascript. So I changed it with an object property when the user clicks on the next button. The first source default for the initial source of the

php - Why does assetic generate multiple copies of my asset in development? -

मेरे Symfony2 परियोजना में AssetBundle है जिसमें एक छवि है, जो / bundle / AssetBundle / Resources / images / logo.svg । यह मेरे किसी एक दृश्य में संदर्भित है: {% image '@ AssetBundle / Resources / images /logo.svg '%} & lt; img src = "{{asset_url}}" चौड़ाई = "130" / & gt; {% Endimage%} हालांकि जब php ऐप / कंसोल आस्तियक: डंप चलाते हैं, तो मैं अपने लोगो के दो समान संस्करणों में / web पर समाप्त होता है / छवियों फ़ोल्डर: /web/images/3cf3f78.svg/web/images/3cf3f78_logo_1.svg ऐसा नहीं होता है मेरे उत्पादन के माहौल में, तो यह विकास में क्यों जरूरी है? मेरा लोड किया गया दृश्य केवल बाद का उपयोग करता है। मुझे पता है कि यह एक पुराना सवाल है, लेकिन मैं सिर्फ कुछ घंटे बिताता हूं उसी मुद्दे को हल करने की कोशिश कर रहा है मेरी सिमफोनी प्रोजेक्ट कई बंडलों का उपयोग करती है जो एसेटिक में प्लग करती थीं और इसलिए मैंने प्रत्येक व्यक्ति को यह देखने की जांच की कि क्या उनके पास एक बग है जो डुप्लिकेट की संपत्ति है ठीक है, मैं अंत में उसी निष्कर्ष

how to calculate dissimilarity in R without using function? -

मेरे पास निम्न के रूप में डेटा है: वर्ग atrribute1 attribute2 attribute3 1 21362 97 437 1 312312 3123 341 2 9 7 9 7 7227 112 3 8398 333 333 मैंने trity1,2,3 पर आधारित class की असमानता गणना करने की कोशिश की और एक 3x3 असमानता मैट्रिक्स उत्पादन करने के लिए मान लीजिए। मैंने ऑनलाइन जाँच की है बहुत सी कार्य है, लेकिन कोई भी इस तरह के डेटा से निपटने में नहीं है क्या कोई मदद कर सकता है? आप प्रत्येक वर्ग के सभी टिप्पणियों में औसत विशेषता मानों की गणना कर सकते हैं और फिर गणना कर सकते हैं वर्गों के बीच जोड़ों की दूरी: # एकत्रित डेटा एकत्रित करने के लिए बस (। ~ वर्ग, डेटा = दिनांक, माध्य) # वर्ग atrribute1 attribute2 attribute3 # 1 1 166837 1610 389 # 2 2 97987 7227 112 # 3 3 8398 333 333 # गणना की दूरी पर दूरी (कुल (~ वर्ग, डेटा = दिनांक, माध्य) [2: 4], डायग = टी, ऊपरी = टी) # 1 2 3 # 1 0.00 69079.30 158444.16 # 2 69079.30 0.00 89854.13 # 3 158444.16 89854.13 0.00

ruby on rails - Scoping behavior around find_each -

I have a lot of records in a table that I'm trying to change to use find_each. Is that if I have an opportunity with which I am using a find_each and I think that for some records I am changing that value, will those affected records also be found? For example, if I do something like this: User.where (classification: zero) .find_each do | U | If u.age & gt; 21 u.update! (Classification: "Accepted") User.where (Classification: Zero). Where (age> 21) .each do | Others | Other users will know that I was updated even while processing the previous user, still can be processed in search_elected on which scod has been changed on the value they were? I do not think it will end after the search_each list has been updated. It uses the primary key as sort and does not kill the ID again in subsequent loops. Edit Sorry - I think what you are asking now. Yes, it will affect all the classifications so that they can remain zero because no one will return an extern

python - Which backend should I use for animations with matplotlib? -

I have an animation work that takes a long time and I want to store it in the queue, but I Can not use x on machines. Since "default" matplotlib requires X, I have to import it like this: Import matplotlib matplotlib.use ("AGG") as import matplotlib.pyplot plt. .. The method that has been passed () is called the backend, the documentation can be found on the backend. If I am using matplotlib.animate () and want to save the API as MP3 or Theora, which backend should I use? author objects in . module and you have the set of backend set using usage If you need to run your script without X, then set the Usage ('AG') to do the right thing and see the animation . Author module attribute (which is a registry of articles found on your system)

c - Gdb repeated "no symbol table is loaded" -

OK, I can not use gdb to try despite a lot of solutions. My makefile cc -g _________ and myfilesys & gt; gdb breaks myfilesys (gdb) my_linked_list.c: 90A symbol table is not loaded, read the symbol from the "file" command ... (gdb) file myfilesys / home / jsexton / work / cs492 / hw3 / myfilesys ... Use (No debugging symbols found) ... done. (GDB) break my_linked_list.c: 90 A symbolic table is full, use the "file" command ... Can anyone see a problem? My program is 30C C is broken into files, so I really need to use the file: [line number] thing. Although you have myfilesys on your executable cc -g < If you claim to be compiled with / code>, then there is no proof in your attempt to use GDB, code> file command: (gdb ) File myfilesys /.../ Reading symbols from myfilesys ... (no debugging signal found) ... done. You have to take on your word that you have actually used cc -g to compile the code myfilesys It means tha

Using javascript to make header buttons click thru -

I have created a child theme for my site, tdotargetmarketing.com. If you look, you'll have three buttons in the header. I broke the table down at the top Slice 3, 5 and 7 are buttons on the site through which I need to click through. I have created pages for those three buttons so that I have URL / page. I added this table below to the editor section of the hair-theme CSS file. Now, I think I need to add javascript code but this is the place where IF is trapped. Not sure about the correct sequence. Don "Ti laughs, Lola ?? I have just finished the original HTML / CSS / Javascript codec, so IIM is getting it but it is not enough yet. & lt; table cells = "0" cellpadding = "0" limit = "0" & ​​gt; & lt; tr colspan = "8" & gt; & Lt; td & gt; & lt; img src = "slice_01 jpg" width = "1600" height = "171"> & lt; TR & gt; & lt; TD & gt; & lt; img src = "

java - How do I change button labels in a grid? -

I am trying to create a game that involves dragging the skid from the slides to the square and leaving it piece. However, I am trying to do this so that the button (with the label) can be used as an exercise. Therefore, for example, a button "W" with the label should change its label to "blank" when I press the mouse over it and leave it on the other with a valid button (with another empty label). Then the second button "" (empty) should replace "W". Using graphics in Java is completely new to me. It is enough to say, I'm not sure how to accomplish the above mentioned work here: My code is still here: import javax.swing. *; Import javax.swing.JButton; Import java.awt.GridLayout; Import java.awt.event. *; Class boardgame implements JFrame MouseListener {JFrame frame = new JFrame ("board game"); Jebton [] [] Bogrud; Public board game () {frame.setLayout (new grid layout (8, 8)); Bogrid = New Zebutan [8] [8]; For (Int i = 0; i

lex - Is there a way to get current number of tokens parsed in stack in yacc -

I'm running in parser stack overflow in yacc. I'm not sure how the current parser stack size determines how to present the current parser stack size is one way, so that the number of tokens should reach the depth of the maximum stack, an error can be reported? Is there a variable in yacc that holds this information? There is no standard way of obtaining a parser stack size, although it is clearly available internally Because the parser is capable of producing a stack overflow error (without exception, or otherwise implementing undefined behavior). You do not need to check it yourself; You just have to print the error message provided for yyerror ; If the stack overflows, the error message will mention that fact. There are a few ways that you can end up with the version of UCC which can not resize the size of the stack. One, public domain Berkeley Yak, often called byacc , is used; The version I'm kicking (from 1993) sets the default stack size to 500. Another