pid
int64
2.28k
41.1M
label
int64
0
1
text
stringlengths
1
28.3k
21,306,235
0
<p>I suggest you use expressjs. Using <code>nodejs</code> to create web application is quite low-level. You have to install express via node <code>npm install express</code> and go from there.</p> <p><strong>Some code snipped to help</strong></p> <pre><code>var express = require('express'); var app = express(); app.us...
16,822,170
0
Convert Excel .xls to .csv, .xml or JSON in Javascript <p>Using <code>Javascript</code>, specifically <code>Google Apps Script</code> (GAS), I need to convert an <code>.xls</code> file to <code>JSON</code>; but I would settle for <code>.csv</code> or <code>.xml</code>.</p> <p>Does anyone know any way to do this? Some l...
37,026,590
0
<p>if your text box coming dynamically then you should try </p> <pre><code>$(document).on("keyup", ".typeahead" , function() { getAllActiveUsers(); }); </code></pre> <p>try this and let us know if its works or not.</p>
34,817,983
0
<p>It doesn't violate IEEE-754, because IEEE-754 defers to languages on this point:</p> <blockquote> <p>A language standard should also define, and require implementations to provide, attributes that allow and disallow value-changing optimizations, separately or collectively, for a block. These optimizations might inc...
40,617,475
0
<p>I found this to be a difficult thing to figure out. I already had an HTML editor installed as part of Eclipse, but it wasn't getting loaded.</p> <p>Go to Preferences > General > Editors > File Association and click on *.html (and do the same for *.htm). If you have an HTML editor installed, you should see it in the...
13,313,304
0
I want to draw a line and fill it with a repeating image in Objective C <p>I don't need code, just a starting point. I have a drawing app on iPad where you draw a line from point a to point b. Between the 2 points the line is replaced with a repeating image.!</p>
21,740,108
0
ExtJS debugging "[E] Layout run failed" (in a custom component) <p>I have developed a <a href="https://github.com/rixo/GridPicker">custom kind of combo box</a> that uses a grid instead of the standard combo picker (mainly to benefit from buffered rendering with huge data sets). I am now trying to make it compatible wit...
17,684,938
0
<p>Something like this should give u all the filenames in the folder, for you to manipulate:</p> <pre><code>Dir["Tel/**/**/*.csv].each do |file| * update attribute of your model with the path of the file end </code></pre>
29,049,704
0
Constructing a JavaScript Array prototype method <p>I am new to constructing a JavaScript Array prototype. Please only paste previous links that are directly appropriate as I have been sourcing on SO and on w3school. <a href="https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/prototype"...
39,677,844
0
<p>Its in your gradle file, and gets written to your manifest (if you aren't using gradle).</p>
35,980,651
0
<p>for start mod-rewire start from the your domain. then on localhost if you want your mod_rewrite work you should pass it to your project address, <br /> before all above thing, you should check your mode_Rewire be enable<br /> redirect:<br /> <code>http://localhost/ConnectMyProfile/ViewProfile.php?id=CMP26944</code>...
36,738,478
0
Searching a custom list view in android? <p>I am using a custom list view and I get unexpected results on search.I would ideally like to search on particular columns in the list for example I would like to search on a Invoice number or a contact number or by name of the person. The following is my code.</p> <pre><code>...
26,598,445
0
<p>Check this:</p> <pre><code>seq 12 | xargs -i echo "256 * 2 ^ ({} - 1)" | bc | xargs -i echo ./a.out {}.txt </code></pre> <p>If it's OK, then drop <code>echo</code> and add <code>&gt;&gt; output.txt</code></p> <pre><code>seq 12 | xargs -i echo "256 * 2 ^ ({} - 1)" | bc | xargs -i ./a.out {}.txt &gt;&gt; output.txt <...
1,202,039
0
<p>Two ways:</p> <pre><code>System.IO.FileInfo fileInfo = new System.IO.FileInfo(filePath); fileInfo.IsReadOnly = true/false; </code></pre> <p>or</p> <pre><code>// Careful! This will clear other file flags e.g. FileAttributes.Hidden File.SetAttributes(filePath, FileAttributes.ReadOnly/FileAttributes.Normal); </code></...
19,394,036
1
Django ModelForm - Allowing adds for ForeignKey <p>I'm trying to mimic the functionality from the Django Admin tool where it allows you to add objects for foreign keys (a little plus icon next to a dropdown). For example, let's say I have the following:</p> <pre><code>class Author(models.Model): first_name = models.Cha...
38,458,655
0
How to make paths clickable in Visual Studio Code Terminal <p>I have VSCode vs. 1.3. and I would like to be able to click in any valid path showed inside the integrated Terminal and get the file opened. </p> <p>Do you know how can I achieve it?</p> <p>Thanks!</p>
3,434,906
0
<p>TWebBrowser is a wrapper around IE ActiveX interface. So, in the end,</p> <pre><code> TWebBrowser = Internet Explorer </code></pre>
8,226,513
0
<p>The solution to your problem greatly depends on your code. You should definitively include the relevant code bits in your SO questions if you want to get help.</p> <p>I'm going to make a guess and assume that your code looks similar to the MapView example:</p> <p><a href="http://developer.anscamobile.com/reference/...
33,672,202
0
Xcode 7.1 certificate issue and invalid profiles <p>We are two devs working on the same ios project, using same developer id. When one of us runs app on device, xcode offers to fix a certificate issue. After agree, xcode kills all existing certificates and invalidates provisioning profiles. This kills each other provis...
25,518,020
0
<p>Here is an additional option:</p> <p>The way I solved this problem for my app was to define the colors in values/color.xml. </p> <pre><code>&lt;resources&gt; &lt;color name="blue"&gt;#ff0099cc&lt;/color&gt; &lt;color name="dark_grey"&gt;#ff1d1d1d&lt;/color&gt; &lt;color name="white"&gt;#ffffffff&lt;/color&gt; ... &...
12,005,022
0
<p>See the equal height function. <a href="http://www.catswhocode.com/blog/8-awesome-jquery-tips-and-tricks" rel="nofollow">http://www.catswhocode.com/blog/8-awesome-jquery-tips-and-tricks</a> Hope this help.</p> <pre><code>function equalHeight(group) { tallest = 0; group.each(function() { thisHeight = $(this).height(...
27,144,047
0
<p>Java (at least JavaEE 6) has an <a href="https://docs.oracle.com/javaee/6/tutorial/doc/gjddd.html" rel="nofollow">Expression Language</a> built-in.</p>
32,615,341
0
Why is R prompting me and failing on `update.packages()`? <p>I'm new to R and I've compiled it myself on Ubuntu 14.04.3 (x64). Note, I am up to date with the R source: </p> <pre><code>blong@work:~/Documents/Work/REPOS__svn/R/R-3-2-branch$ svn info |head -n 7 Path: . Working Copy Root Path: /home/blong/Documents/Work/RE...
5,386,519
0
<p>There are four kinds of Class relationships</p> <ol> <li>Association: <strong>uses a</strong><br> Ex:a Class Man uses a Class Pen</li> <li>Aggregation: <strong>has a</strong><br> Ex:a Class Man has a Class Car ( Car is still there when Man die )</li> <li>Composition: <strong>owns a</strong><br> Ex:a Class Man owns ...
19,587,903
0
<p>In a Terminal window type <code>man ld</code> and you'll get a description of the <code>ld</code> command and the arguments it takes. There you'll find <code>-F</code> specifies a directory to search for frameworks in. The Xcode generated command line contains:</p> <pre><code>-F/Users/thomaswickl/Development/Git\ P...
6,967,136
1
Is there any good alternative for python's webkit module that works on windows? <p>Is there any official good alternative for webkit that works on windows?</p>
1,329,817
0
<p>.NET certainly allows you to use Visual Basic to write a Windows Service. I believe there is even a default project template to do so. Here is an tutorial as such: <a href="http://www.vbdotnetheaven.com/UploadFile/mahesh/Winservvb11172005233242PM/Winservvb.aspx" rel="nofollow noreferrer">http://www.vbdotnetheaven.c...
8,887,896
0
Why does my KISS FFT plot show duplicate peaks mirrored on the y-axis? <p>I'm a beginner with FFT concepts and so what I understand is that if I put in 1024 signals, I'll get 513 bins back ranging from 0hz to 22050Hz (in the case of a 44100Hz sampling rate). Using KISS FFT in Cinder the getBinSize function returns the ...
29,892,858
0
How to deep link an app from the Facebook App builtin browser? <p>I have a link that when clicked loads a dynamic webpage (which performs some operations on the server), and then redirect the user to an installed app. So far, opening the link in the following apps/browsers works fine:</p> <ul> <li>Android's default bro...
18,294,547
0
<p>You should probably first check if it is not a case issue: STATS vs Stats ...?</p>
12,800,513
0
<p>You could do the fallowing...</p> <pre><code>var GroupSelectView = Backbone.View.extend({ el: $("select"), initialize: function() { var that = this; this.collection = new UserGroups(); this.collection.on( 'change', this.render, this ); // You could try this too, 1 is for 1 item is added, the other, when all items a...
34,371,935
0
How to have separate urls for the same app in Django 1.9 <p>I have an app that will have 2 kinds of urls, one that will be included in other apps and one will be included in the settings app. I want to have a way to include only part of the urls without creating a seperate file for it. </p> <pre><code># records app -- ...
18,560,341
0
Accessing Protected Variable Of An Instance Of A Class That Extends An Abstract Base Class? <p>I have an abstract class called MyAction which contains a protected enum variable. The class is defined as follows:</p> <pre><code>package mypackage; public abstract class MyAction { public enum ActionId { ACTION1, ACTION2; }...
21,317,940
0
Performing calculations on Django database values: views.py, template or Javascript? <p>I have a Django project that interfaces with a PostgreSQL database; one of my tables is about 450 rows long and each row contains about a dozen columns.</p> <p>Each column's value must be put into a different formula to produce the ...
5,733,800
0
<blockquote> <p>if the dialog gets wider, but stays the same height, the number of rows should lessen, while the number of columns increases. </p> </blockquote> <p><a href="http://tips4java.wordpress.com/2008/11/06/wrap-layout/" rel="nofollow">Wrap Layout</a> might be what you are looking for.</p>
5,209,918
0
<p>try </p> <pre><code>strtotime(now()) </code></pre> <p>And you should definitely use <code>timestamp</code> or <code>datetime</code> as a type for your column.</p>
24,024,605
0
<p>There seem to be spaces in the file path:</p> <pre><code> New%20folder%20(2) </code></pre>
23,019,966
0
<p>give it a try</p> <pre><code>window.location.href.split("?")[0] </code></pre>
13,781,982
0
<p>Why not just make evey different view a different site, ie give the ads in each view a different id. It is a little bit of a pain to set this up if you have several applications/or lots of views, but I think that it should work.</p>
4,840,534
0
<p>You can get straight into programming with ruby.</p> <p>In terms of generic things to know I suggest you read a book, so you get one consistent message explaining all the basics.</p> <p>This is a great book to teach you programming in general and it teaches you using ruby. <a href="http://pragprog.com/titles/ltp2/l...
16,839,452
0
<p>I solve it with ajax call. </p> <pre><code> &lt;script type="text/javascript"&gt; $(document).ready(function () { $("input[type = radio]").each(function (index, value) { $(value).click(function () { $.ajax({ type: "POST", url: "http://localhost:2782/TestPage.aspx/GetBank", data: "{id:" + value.defaultValue + "}", c...
6,305,711
0
<p>Wrap your content inside a ScrollView</p>
14,072,017
0
Iterating over records in an ExtJS store and filtering on a specific field <p>I am iterating over records in a store as they come in like so:</p> <pre><code>Ext.create('Ext.data.Store', { model: 'Message', storeId: 'Staging', proxy: { type: 'memory', reader: { type: 'json' } }, listeners: { add: function(store, records...
36,278,026
0
Multithreading extended panel <p>I'm trying to allocate a <code>JPanel</code> that implements <code>Runnable</code> interface in a <code>JFrame</code>. I'd made this sample for interpret my idea. I want to add a multi-threading panel that shows a text as demo to a window with a <code>String</code> as parameter of a new...
3,154,488
0
How do I iterate through the files in a directory in Java? <p>I need to get a list of all the files in a directory, including files in all the sub-directories. What is the standard way to accomplish directory iteration with Java?</p>
9,110,259
0
<p>I've never used swfobject but from what I'm seeing you've created a swf object and are asking it to be added to the videoDiv element. Are you sure you want this behaviour ?</p> <p>Because from where I'm standing I think you should have used the createSWF method and added the returned object to your html array.</p>
2,848,401
0
Selecting all tables with no records <p>I need to display all tables that have zero records.</p> <p>I tried,</p> <pre><code>select * from user_all_tables where (select count(*) from user_all_tables)=0; </code></pre> <p>But it doesn't seem to work. How should I go about redesigning this query? Thanks.</p>
33,824,549
0
<p>This is what you want:</p> <pre><code>echo "$line" | sed -E 's/(QA.|DEV.)(.*)/&lt;!-- \1\2 --&gt;/' </code></pre> <p>The <strong>first group</strong> could be prefixed by <code>QA</code> or <code>DEV</code> , use the <code>|</code> <em>or</em> operator.</p> <p>A <em>few</em> <strong>alternatives</strong>:</p> <pre>...
3,429,523
0
What does this line of C/C++ preprocessor mean? <p>This is Line 519 of <code>WinNT.h</code> (BUILD Version: 0091)</p> <pre><code>#define DECLARE_HANDLE(name) struct name##__{int unused;}; typedef struct name##__ *name </code></pre> <p>Why do we need a pointer to an struct with a single int member with a weird name call...
18,600,509
0
<p>You need put the code bellow:</p> <pre><code> ClassicEngineBoot.getInstance().start(); </code></pre> <p>Inside your bootstrap. It's worked for me, in Grails.</p>
17,006,528
0
<p>You can configure IntelliJ to use a lot of different application containers, but each of them must be downloaded and installed separately. I currently have mine configured to serve via jetty, like eclipse, and also tomcat, tc-server, jboss, and node.js. It's pretty easy to set up.</p>
35,531,950
0
<p>Refer the sample <a href="https://jsfiddle.net/shashank2691/kx4s6pq0/2/" rel="nofollow">here</a>.</p> <p><strong>Code:</strong></p> <p><em>HTML:</em></p> <pre><code>&lt;div ng-app="app" ng-controller="test as vm"&gt; &lt;div test-dir="user" ng-repeat="user in vm.users"&gt; &lt;/div&gt; &lt;/div&gt; </code></pre> <p...
31,255,971
0
<pre><code>func itemMutableArray() -&gt; NSMutableArray { return NSMutableArray(array: (item.allObjects as! [Item]).sorted{ $0.date.compare($1.date) == NSComparisonResult.OrderedAscending } ) } </code></pre>
33,020,711
0
Showing alert panel when inventory reaches critical <p>I'm trying to show when an inventory is lower than critical. It doesn't seem to get there when I debug the system </p> <p>This is my code behind </p> <pre><code>protected void Page_Load(object sender, EventArgs e) { GetInventory(); TotalCount(); CriticalItem(); Pan...
9,192,507
0
analyzing sequences matlab <p>I am trying to write a short matlab function that will recieve a vector and will return me the index of the first element of the longest sequence of 1s (I can assume that the sequence consists of 1s and 0s). for example: </p> <blockquote> <blockquote> <p>IndexLargeSeq([11000111110000000000...
32,116,366
0
<p>The full method is pasted below. When calling JTable::getInstance you must pass $type as an argument. The getInstance method then uses $type to define $tableClass as you can see below. </p> <pre><code>// Sanitize and prepare the table class name. $type = preg_replace('/[^A-Z0-9_\.-]/i', '', $type); $tableClass = $p...
5,661,392
0
<p>You can't actually modify/save the image in javascript/jquery (as far as i know). You'll have to use server-side image manipulation libraries like gdlib (http://www.boutell.com/gd/) which is usually activated by default in php, or imagemagick (http://www.imagemagick.org/script/index.php)</p>
6,398,767
0
Is it possible to define the asset name in a custom XNA content processor? <p>Normally, when loading content using XNA's Content Pipeline, the compiled .xnb files are accessed using an assigned "Asset Name" that can be defined in the Visual Studio GUI. By default, this name is the same as the content's filename sans ex...
28,815,064
0
<p>My favorite method is to add a <code>text-align: center;</code> to the parent element, then use <code>display: inline-block;</code> instead of <code>float: left;</code></p> <p><div class="snippet" data-lang="js" data-hide="false"> <div class="snippet-code"> <pre class="snippet-code-css lang-css prettyprint-override...
38,279,184
0
<p>I too faced same error today in my website where i use TCPDF Library to generate PDFs. It was working fine but suddenly i started to get the following error today </p> <pre><code>Severity: 8192 Message: Imagick::clone method is deprecated ..... </code></pre> <p>Might be the hosting provider updated PHP or Imagick. ...
26,055,668
0
<p>I would prefer to do like this:</p> <pre><code>if (window.onpopstate != undefined) { window.onpopstate = locate; } else { window.onhashchange = locate; } </code></pre> <p>so if "msie" add this functionality you do not depend on old code</p>
25,804,331
0
<p>You have an quite common mistake.</p> <p>In your collection, the field is named <code>listname</code> (note the lowercase) whereas in your query the field is name <code>listName</code> (note the camel case). Field names are case sensitive. so when adjusting the first query to</p> <pre><code>db.testcol.find({ "msgs....
14,273,974
0
<p>If you want to save modified source as html you can use different aproaches, depends on what you want to mainupulate. Sadly with javascript saveing file is tricky and depends on many things, so you could use option to copy paste file source manually or write your browser and settings specific file saver. I would pr...
29,623,000
0
Enable form based login in Jboss EAP 6.3 <p>Following the <a href="https://access.redhat.com/documentation/en-US/JBoss_Enterprise_Application_Platform/6.3/html/Security_Guide/Enable_Form-based_Authentication.html" rel="nofollow">official tutorial</a> form-based auth is achieved by simply adding this to web.xml:</p> <pr...
35,938,700
0
<p>Pointers do not keep information whether they point to single objects or for example first elements of arrays.</p> <p>Consider the following code snippet</p> <pre><code>char *p; char c = 'A'; p = &amp;c; putchar( *p ); char s[] = "ABC"; p = s; putchar( *p ); </code></pre> <p>Thus you have to provide yourself the in...
3,445,157
0
<p>Give this version a shot:</p> <pre><code>public void onDrawFrame(GL10 gl) { gl.glClear(GL10.GL_COLOR_BUFFER_BIT | GL10.GL_DEPTH_BUFFER_BIT); gl.glLoadIdentity(); GLU.gluLookAt(gl, 0, 0, 100, 0, 0, 0, 0, 1, 0); for (int i = 0; i &lt; obj.size; i++) { // obj is an array of positions obj = mObj[i]; gl.glPushMatrix(); ...
5,599,010
0
Defining Trending Topics in a specific collection of tweets <p>Im doing a Java application where I'll have to determine what are the Trending Topics from a specific collection of tweets, obtained trough the Twitter Search. While searching in the web, I found out that the algorithm defines that a topic is trending, when...
13,959,172
0
Issue with JSON sending <p>Hey guys so I am trying to have a JSON send over a value to another page in wordpress to create a session once a image is clicked on. </p> <p>Here is the JSON code:</p> <pre><code>$('.item-post a').click(function() { var prodname = $('#hiddenpostitle'); $.post('/overviewcheck-515adfzx8522', {...
23,753,604
0
Add "Rubber Band" effect in android while changing background of application <p>I am working on the application in which:</p> <p>User will have a control to change the background and text (multiples) by doing horizontal swipe for BG and vertical swipe for text. In this case, if I am changing BG, text should remain cons...
40,997,145
0
Ruby hash access value from string array <p>I have an hash like below:</p> <pre><code>hash = {"a": [{"c": "d", "e": "f"}] } </code></pre> <p>Normally we can access it like <code>hash["a"][0]["c"]</code>.</p> <p>But, I have a string like:</p> <pre><code>string = "a[0]['c']" </code></pre> <p>(This can change depending up...
24,604,385
0
<p>You can prevent it by setting rule for semester_id as follows</p> <pre><code>$this-&gt;form_validation-&gt;set_rules('semester_id', 'input_name', 'trim|required|is_unique[TABLENAME.COLUMNNAME]'); </code></pre>
6,094,073
0
<p><a href="https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/String/replace" rel="nofollow">https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/String/replace</a></p> <p>You might use a regular expression with the "g" (global match) flag.</p> <pre><code>var entities = {'&lt;': '&am...
32,301,294
0
<p>Here's another vectorized approach. It tries all permutations of rows of <code>B</code>, and produces the optimal row-permuted <code>B</code> in matrix <code>Bresult</code>.</p> <pre><code>[m, n] = size(A); ind = perms(1:m); % // all permutations of row indices BB = permute(reshape(B(ind.',:),m,[],n),[1 3 2]); %'//...
20,429,150
0
<h2>Regex</h2> <pre><code>^\&lt;[^\&gt;]+\&gt;.*$ </code></pre> <p><a href="http://regex101.com/r/iU2qX3" rel="nofollow">Demo</a></p> <p>Is what i'd switch to or</p> <pre><code>^\&lt;pstyle\:Chapter\&gt;.*$ </code></pre> <p><a href="http://regex101.com/r/aV0rH3" rel="nofollow">Demo</a></p> <p>or</p> <pre><code>^\&lt;p...
40,744,181
0
Client Credential Flow without Admin login <p>Following <a href="https://blogs.msdn.microsoft.com/exchangedev/2015/01/21/building-daemon-or-service-apps-with-office-365-mail-calendar-and-contacts-apis-oauth2-client-credential-flow/" rel="nofollow noreferrer">these</a> instructions on implementing client credential flow...
10,844,111
0
<p>You specified <code>fill_parent</code> for both the <code>layout_width</code> and <code>layout_height</code> of your <code>RelativeLayout</code>, therefore it fills up it's parent view. By default, a relative layout arranges it's children to the top-left corner, regardless you use <code>fill_parent</code> for the s...
17,474,616
0
<p>There was nothing wrong with the angular directives it just that CHROME was seeing the request as the same therefore not executing it... and just binding the same data to every ajax request... </p>
8,264,627
1
How to deal with a Class generated exception from within Main <p>I'm having some trouble getting my head around how best to solve this situation (mostly due to lack of experience I think). I have written a couple of definitions in a single class that are called from a Main to perform certain tasks. It is assumed the Ma...
17,219,355
0
<p>use the attributes['xxx'].value</p>
27,099,914
0
<p>I have face the same issue before but I do not understand that why this occur.But I have solve it by declaring variable using $ sign instead of var.</p> <pre><code> $('#numberOfItems').keyup(function(){ $items = $('#numberOfItems').val(); $weightitem = $('#weightitem').val(); $totalweight = $items * $weightitem; $(...
24,710,728
0
<p>you need to set these attributes of elements as as:</p> <pre><code>$(document).ready(function () { $('#group').on('click', '.add_subgroup', function () { var i = $('div.subgroup').length; var where = $('#group'); var subgroup = $('#subgroup_hidden').clone(); var j = i + 1; subgroup.attr({ 'id': 'subgroup_' + j, 'cl...
22,396,045
0
Post a image into facebook app using app id <p>I need to post the image using the image url in my facebook app is that possible? How to post image to Facebook on button click? I have stored imageUrl in variable image and the facebook URL in the variable shareUrl, </p> <pre><code>following is the complete facebook URL :...
27,886,245
0
How to change the URL after a navigation using jQuery Mobile's $.mobile.navigate <p>I'm new to jQuery Mobile and I've been trying so hard (been googling for 2 days straight) to understand how the navigation to external pages works but finding it really hard so hopefully I can get a proper explanation here. From my sear...
5,553,782
0
<p>You'll need </p> <pre><code>XMLNode.InsertAfter(newChildNode,referenceChildNode) </code></pre> <p>This should kickstart you:</p> <p><a href="http://msdn.microsoft.com/en-US/library/system.xml.xmlnode.insertafter%28v=VS.80%29.aspx" rel="nofollow">http://msdn.microsoft.com/en-US/library/system.xml.xmlnode.insertafter...
34,613,825
0
<p>I just had to close the assistant editor and the debug area and then it magically showed up. If you don't have the assistant editor open then all you need to do is open it, then close it again. That should fix it too.</p> <p>If you don't know what the assistant editor is I have highlighted it in red:</p> <p><a href...
40,260,171
0
Woocommerce Product Price change(free) based on warranty status <p>I want to set few woocommerce product price free based on warranty status.</p> <p>Products are: <code>$target_products = array('2917','1229','1277');</code></p> <p>for Example : <code>$warranty_status = 1</code> mean, valid for warranty .</p> <p>if a cu...
12,575,402
0
Split jQuery cycle pager into divs <p>I have a jQuery cycle slider working fine, but the pager I need split into different places. The paging itself works, but the active slide is the same for each div - i.e. for the first slide, the first pager in each div will show as active. I'm having a hard figuring out how to sol...
15,872,236
0
<p>Your code works fine for me. What error you might be having is in processFile function you are creating a file object from the fileName, which is not existing. Then might be trying to read the contents of the file which might be throwing you FileNotFoundException. just comment processFile function and your code wil...
13,824,883
0
<p>I have a suggestion. You can use the Customer Groups feature in PrestaShop 1.5 and only allow logged in customers to see the prices. For every Customer that is grouped in Visitor, they would see your website in Catalog Mode. </p>
12,092,356
0
<p>A short perl script that should do what you need, explained in comments:</p> <pre><code>#!/usr/bin/perl -p $ast = '*' x 75; # Number of asterisks. if (m{//=+}) { # Beginning of a comment. $inside = 1; s{.*}{/$ast\\\nDescription:}; next; } if ($inside) { unless (m{^//}) { # End of a comment. undef $inside; print '\\...
12,299,543
0
<p>You can do multiple inserts like this though,</p> <pre><code> INSERT INTO LOCATIONS (Location_ID,Postal_Code,City,State_Province,Country) VALUES ('L0001','19121','Philadelphia','PA','USA'), ('L0002','08618','Trenton','NJ','USA'); </code></pre>
24,291,156
0
<p>I had a similar issue. In my case it was the client system that had a virus scanner installed. Those scanners sometimes have identity theft modules that intercept <code>POST</code>s, scan the body and then pass it on.</p> <p>In my case <code>BitDefender</code> cached about 5MB before passing it on.</p> <p>If the wh...
31,709,865
0
<p>The code bloat they are talking about in the article (as it is about the out of memory issue in the IDE) is related to the generated DCUs and all the meta information that is held in the IDE. Every DCU contains all the used generics. Only when compiling your binary the linker will remove duplicates.</p> <p>That mea...
2,268,541
0
<p>When I try this: [MarshalAsAttribute(UnmanagedType.SafeArray, SafeArrayUserDefinedSubType = typeof(Inner))]</p> <p>I get: An unhandled exception of type 'System.ArgumentException' occurred in Driver.exe</p> <p>Additional information: The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))</p...
24,242,932
0
<p>The <code>copy</code> method is defined in <code>NSObject</code>. If you custom class does not inherit from <code>NSObject</code>, <code>copy</code> won't be available.</p> <p>You can define <code>copy</code> for any object in the following way:</p> <pre><code>class MyRootClass { //create a copy if the object imple...
12,245,152
0
<p>The equality operator(==) checks the refernce of string first then checks value of string. While equals method checks the value first. So,in this case equals method should be used instead of equality operator.<code> String s="hello"; String s1="hello"; String s3=new String("hello")</code> In the above code snippet ...
30,131,063
0
<p>The <code>myCar</code> variable is not visible in <code>displayMenu()</code> method. Try passing it in as parameter like:</p> <pre><code>public static void displayMenu(Car[] myCar) </code></pre> <p>Also, @ryekayo's suggestion will give you accurate results.</p> <p>Also make sure that <code>Car</code> class has a <c...
17,204,373
0
<p><a href="http://developer.apple.com/library/ios/#documentation/AssetsLibrary/Reference/ALAsset_Class/Reference/Reference.html#//apple_ref/occ/instm/ALAsset/valueForProperty">http://developer.apple.com/library/ios/#documentation/AssetsLibrary/Reference/ALAsset_Class/Reference/Reference.html#//apple_ref/occ/instm/ALA...
23,783,038
0
<p>its because the json you are using is not valid. and the parsing you are doing is not valid too</p> <p>here is a good link to start off with android json parsing</p> <p><a href="http://www.androidhive.info/2012/01/android-json-parsing-tutorial/" rel="nofollow">http://www.androidhive.info/2012/01/android-json-parsin...
21,555,653
0
Hiding <p> field in javascript <p>Here's my code for gathering titles/posts from reddit's api:</p> <pre><code> $.getJSON("http://www.reddit.com/search.json?q=" + query + "&amp;sort=" + val + "&amp;t=" + time, function (data) { var i = 0 $.each(data.data.children, function (i, item) { var title = item.data.title var url...