Unnamed: 0
int64
65
6.03M
Id
int64
66
6.03M
Title
stringlengths
10
191
input
stringlengths
23
4.18k
output
stringclasses
10 values
Tag_Number
stringclasses
10 values
120,859
120,860
Why my index == "string" is not working in JS?
<p>I have a problem with an equal statement in Javascript. Look at this screenshot:</p> <p><img src="http://i.stack.imgur.com/cCLpA.png" alt="enter image description here"></p> <p>I am trying to check whether index is the same as "Delete", but it is never true. It also is not true if I try <code>index === "Delete"</c...
javascript
[3]
3,984,072
3,984,073
We Have a countdown timer in java script
<p>We Have a countdown timer in java script ,the problem we are facing right now is when a other user opens the same page he is not able to see the updated version or timer which r running right now ,can you pls suggest some solution </p>
javascript
[3]
5,506,106
5,506,107
How to create javascript function lookup object?
<p>I'm attempting to create a function lookup in Javascript essentially mapping a data type to a function that does something for that data type. Right now I have something similar to:</p> <pre><code>var Namespace = Namespace || {}; Namespace.MyObj = function () { var stringFunc = function(someData) { //Do...
javascript
[3]
557,523
557,524
Simplify a Fraction
<p>How can I simplify a fraction in PHP?</p> <p>For instance, converting <code>40/100</code> to <code>2/5</code>.</p> <p>The only way I could think of is to do a prime factorization on both numbers and compare like results, but I'm not really sure how to do that either.</p>
php
[2]
5,382,987
5,382,988
Disable button unless bot selectors have value
<p>OK, I have two HTML select elements and a button. I need to disable the button unless <strong>both</strong> of the selectors have any but default (na) values.</p> <p>I've got this so far, but it doesn't really work. What am I missing? </p> <p><strong>JS</strong></p> <pre><code>function toggleBtn() { if($(".my...
jquery
[5]
5,783,473
5,783,474
Play RTMP video streaming on android videoview
<p>I just wanna play an rtmp video streaming in android videoview or android default player.ex "rtmp://cp67126.edgefcs.net/ondemand/mediapm/osmf/content/test/akamai_10_year_f8_512K ".How could i do tht?Examples are much better..</p> <p>Thanks.</p>
android
[4]
2,698,674
2,698,675
Java search functionality
<p>There is a requirement in my Java project where the user will enter the customer name/ number in the front-end screen and hit search button, the system should display all the matching customer names with links to the customer details. I have been asked to write </p> <p>a web service to implement this functionality...
java
[1]
2,808,688
2,808,689
preg_match returns empty array
<p>i always use preg_match and it always works fine</p> <p>but today i was trying to get a content between two html tags <code>&lt;code: 1&gt;DATA&lt;/code&gt;</code></p> <p>And i've a problem</p> <p>my code will explain my problem</p> <pre><code>function findThis($data){ preg_match_all("/\&lt;code: (.*?)\&gt;(...
php
[2]
1,953,229
1,953,230
need a jquery code example: connect a sortable list to another sortable list located in an iframe
<p>I need a simple and clear JQuery code example (using Sortable UI) of how to connect two sortable lists, one of which is located in an iframe. </p> <p>Please consider the below example. One sortable list (#sortable1) is in the main document. The other sortable list(#sortable2) is in the iframe. I need to be able to ...
jquery
[5]
3,042,440
3,042,441
unix timestamp conversion results not accurate php
<p>I am trying to convert a unix timestamp into readable text. The timestamp is stored in a database and shown in a table. The problem is the results are not accurate. <hr /> <strong>Code:</strong></p> <pre><code>&lt;td&gt;'.date("F j, Y, g:i a", strtotime($row['expire'])).'&lt;/td&gt; </code></pre> <p><hr /> <strong...
php
[2]
5,866,185
5,866,186
How to identify data is Encoded using Server.UrlEncode() Asp.net
<p>Can we identify whether input data is Encoded using <strong>Server.UrlEncode()</strong> method or not? <br /> I am looking for something like "<strong>Server.IsUrlEncoded</strong>"?</p>
asp.net
[9]
559,009
559,010
date_default_timezone_set showing incorrect time
<p>I uploaded the following to a server in the US:</p> <pre><code>date_default_timezone_set('Asia/Calcutta'); echo date("Y-m-d H:i:s"); // time in India </code></pre> <p>The time displayed is 15 minutes prior to that of the actual time in India. </p> <p>What am I doing wrong here? What code will <strong>always</str...
php
[2]
1,961,890
1,961,891
How to know when a View has scrolled into view
<p>We are currently developing an app that displays large data sets in "registers" and in rows. We are using a TableLayout as the base view and then adding table rows for every item (with a LinearLayout in each row).</p> <p>I have noticed that once the amount of records get beyond a certain point (1000+ records), the ...
android
[4]
1,874,663
1,874,664
How to create a list of all built-in PHP functions a project makes use of?
<p>Background: PHP allows providers to disable functions (directive "disable_functions"). So in order to get to know if your project is running on a specific server you'll have to check:</p> <ol> <li>What built-in (=excluding user-defined) functions is your to-be-deployed project using?</li> <li>Are the functions avai...
php
[2]
4,113,546
4,113,547
how to use if else conditon on button press based on image of button?
<p>I am trying to use some logics on the base of button click.i use button as checkmark and when i click on this check mark the image of button changed into checked.png or unchecked.png.On that basis i use this code...</p> <pre><code>if([UIImage imageNamed:@"checkbox_ticked.png"]) { isActiveStr=[arrayPicke...
iphone
[8]
514,507
514,508
java Inverse BigInteger?
<p>I know : p,b,g,</p> <pre><code>(g^(a*b)) mod p = X </code></pre> <p>b,p,g is BigInteger</p> <p>Now I want compute : <code>g^a mod p</code></p> <pre><code>{X^(b^-1)} mod p = g^(a*b*(b^-1))) mod p = g^a mod p </code></pre> <p>In java <code>BigInteger</code> have only <code>modInverse(BigInteger m)</code> Return...
java
[1]
3,945,378
3,945,379
Sticky jquery selected option
<p>I have a page that shows users info like address, phone, name, etc., but the phone field is a select option where I can choose between (Phone,<br> For each user I have a select option:</p> <pre><code>&lt;select class="smpullinput" id="middle_column_type&lt;? echo $idtable; ?&gt;"&gt; &lt;option id="Phone" value...
jquery
[5]
3,903,229
3,903,230
Javascript,auto refresh
<p>i currently am using the below javascript code below, </p> <pre><code> &lt;script type="text/javascript"&gt; function PrintWindow() { window.print(); CheckWindowState(); } function CheckWindowState() { ...
javascript
[3]
4,460,417
4,460,418
Java - is `null` an instance of `object`?
<p>I read that null isn't an <code>instanceof</code> anything, but on the other hand that <strong>everything</strong> in Java extends <code>objects</code>.</p>
java
[1]
1,200,667
1,200,668
Cumulative count of unique values in a dictionary
<p>I have a huge dictionary dd{} where I have people and sets of fruits they prefer:</p> <pre><code>A set(['Apple', 'Orange', 'Strawberries']) B set(['Banana', 'Strawberries', 'Orange', 'Kiwi', 'Dates']) C set(['Apple', 'Kiwi', 'Grapes']) A set(['Banana', 'Orange', 'Apple', 'Lemon']) </code></pre> <p>I want a cumulat...
python
[7]
5,813,022
5,813,023
Inserting HTML as a last child of a selected tag using JQuery
<p>I am new to JQuery. I'm reading JQuery in action, but only up to page 39 and need some quick help!</p> <p>Please note: I'm simplifying my actual requirement, so what I'm asking for may sound odd but I'm just tryin to get to the crux of the JQuery expression and not my situation (related to an animation plugin).</p>...
jquery
[5]
2,819,533
2,819,534
iPhone-SDK: Adding Image on Navigation Bar:
<p>I have a navigation controller which also has a table view. I want to add an image left side of the navigation bar on top programmatically. When i tried to add by the below code in viewDidLoad:</p> <p>CGRect frame = CGRectMake(0.0, 0.0, 94.0, 33.0); UIImageView *image = [ [UIImageView alloc]initWithImage:[UIIma...
iphone
[8]
5,796,287
5,796,288
How to read line (from a file) and then append + print in python?
<pre><code>for line in file: print line </code></pre> <p>In the code above when I change it to:</p> <pre><code>for line in file: print line + " just a string" </code></pre> <p>This only appends "just a string" to the last line</p> <p>PS: Python newbie</p>
python
[7]
1,236,141
1,236,142
Creating An HtmlTable Using An ASP.NET Repeater Dynamically Bound to an Object List using ExtensionMethods.WebControls;
<p>I'm trying to create a repeater control and create the template programattically in webform. I found the post <a href="http://stackoverflow.com/questions/11110594/creating-an-htmltable-using-an-asp-net-repeater-dynamically-bound-to-an-object-l">here</a> <a href="http://stackoverflow.com/questions/11110594/creating-a...
asp.net
[9]
3,949,592
3,949,593
Mouseenter not working with div jquery
<p>I have this div that when the mouse enters it, I want it to show a button within itself. For example here's the code for the div:</p> <pre><code>&lt;div id="menuitem1" style="height: 50px;" class="menuitem"&gt; &lt;input type="button" class="menuclear" value="Clear" style="margin-left: 10px; display: none;"/&gt...
jquery
[5]
4,094,665
4,094,666
parsing MonthDate string in a leap year
<p>please consider the following snippet:</p> <pre><code> SimpleDateFormat parser = new SimpleDateFormat("MMdd"); parser.setLenient(false); try { Date date = parser.parse("0229"); System.out.println(date); } catch (ParseException e) { e.printStackTrace(); } </code></pre> <p>...
java
[1]
4,865,008
4,865,009
How to pass a method to qsort?
<p>There is a class that contains some data and it sorts them at some point of time. I use <code>qsort()</code> and I'd like to keep the comparing function within the class as a method. The question is how to pass a method to <code>qsort()</code> so that the compiler (g++) don't throw any warnings?</p> <p>Attempt 1:</...
c++
[6]
305,176
305,177
How do I store complex objects in javascript?
<p>I need to be able to store objects in javascript, and access them very quickly. For example, I have a list of vehicles, defined like so:</p> <pre><code>{ "name": "Jim's Ford Focus", "color": "white", isDamaged: true, wheels: 4 } { "name": "Bob's Suzuki Swift", "color": "green", isDamaged: false, wheels: 4 } { "name...
javascript
[3]
2,778,382
2,778,383
Abstract class and operator!= in c++
<p>I have problem implementing the operator!= in a set class deriving from an abstact one. The code looks like this:</p> <pre><code>class Abstract { public: //to make the syntax easier let's use a raw pointer virtual bool operator!=(const Abstract* other) = 0; }; class Implementation { SomeObject impl...
c++
[6]
2,398,503
2,398,504
selecting items in a listview
<pre><code>i have got a difficult task in my hand i dont knw how to do it,and my question is </code></pre> <p>i want to select a particular subitem in a row of a listview.for ex if the row contains 5 subitems,if i click the 3rd subitem it only gets selected.can anybody help me out</p> <p>thank you very much dude.i so...
c#
[0]
4,320,106
4,320,107
How to remove "," in end of text in php?
<p>I have a text:</p> <pre><code>"2G Network":"GSM 850","3G Network":"HSDPA 850", </code></pre> <p>How to remove "," in end of text in php </p> <pre><code>"2G Network":"GSM 850","3G Network":"HSDPA 850" </code></pre>
php
[2]
1,566,533
1,566,534
Private functions / Variables enforcement in python
<p>I see a lot of python code that does "loose" private variables / functions. They'll declare functions / variables with one underscore (eg. _foo) and then use it just in the class / file. It really annoys me that they don't use the double underscore because eventually, someone will call this "private" member from out...
python
[7]
3,734,717
3,734,718
Using ltrim(); to take away '0's from the start of my users input
<p>I ask for a user to input 4 numbers or letter from 1 - 9 and a-f. </p> <p>i then take these numbers and letters and <code>str_replace</code> them with 4 byte values. </p> <p>So if the user inputs <code>00FF</code>, the value would be <code>0000 0000 1111 1111</code>, as <code>0000</code> is the 4 byte value of <co...
php
[2]
2,466,322
2,466,323
How to play multiple video in Gstreamer using java
<p>I am currently trying to play multiple videos in java using netbeans. I am able to play multiple videos using multiple gstreamer players but how do i use one player to play multiple videos instead so that it will not lag? </p>
java
[1]
511,549
511,550
Graceful Handling of Technical PHP/SQL errors
<p>I'm developing a PHP web application that is heavy on the database interactions. My question is, how do I display "Pretty" errors. I've got all kinds of exceptions and what not in pretty much every aspect of the app, but they still just awkwardly post the error text (which I currently have working perfectly) eithe...
php
[2]
5,413,495
5,413,496
Script with which I can change the font dynamically when the page is live using JavaScript
<p>I want a JavaScript with which I can change the font dynamically when the page is live (Arial to Times). But when I click Arial or Times, the page should not get refreshed. Can anyone please help me in this? Or can anyone please provide a script for this?</p>
javascript
[3]
5,528,618
5,528,619
updating date "day/month/year" in DatePicker in Android
<p>I want to update the date picker to a given date (day,month,year) I used this code </p> <pre><code> date.updateDate(year, month, day); </code></pre> <p>where day,month and year are of type int. I have an exception while debugging "source not found" at this line. what's the wrong with my code?? thanks</p>
android
[4]
1,350,655
1,350,656
Web application runs very fast but don't know why?
<p>I've a web application. It runs slow. But if I load the Sql Server Mgmt Studio in the server side with database [use] and [go]. The web application responses very fast. Why ?</p> <p>My question is I didn't do anything but the my website response is greatly improved (approx 5~10 times faster) by launching the sql se...
asp.net
[9]
2,821,327
2,821,328
Not able to use new resource identifiers in Android with targetSdkVersion defined in manifest
<p>I'm developing an Android application that I'd like to be compatible with 1.5 (SDK version 4). I'm testing the application on 2.2 (SDK version 8). To do this, I'm including in the manifest file the line</p> <pre><code>&lt;uses-sdk android:minSdkVersion="4" android:targetSdkVersion="8" /&gt; </code></pre> <p>I thou...
android
[4]
644,313
644,314
Convert a string array to byte array
<p>I want to make a file which reads String array but initially I am having only byte array so first I want to convert it into string array, so how can I do so. </p>
c#
[0]
3,788,261
3,788,262
Switch focus between opened dialogs
<p>is there any way to programmatically switch focus between shown dialogs? To resume... I need method dialog.requestFocus(), but there is no some like that...</p> <p>Thanks...</p>
android
[4]
3,934,321
3,934,322
Stay logged in on a website in an application lifecycle
<p>I was able log in through my android app to <a href="http://yearbook08.com/" rel="nofollow">http://yearbook08.com/</a> using this code:</p> <pre><code> String URL="http://yearbook08.com/login.php"; HttpClient httpclient = new DefaultHttpClient(); HttpResponse response = null; HttpPost httppost = n...
android
[4]
5,151,464
5,151,465
Python 2 + Python 3 + library
<p>I have both Python 2 and 3 in the same machine and installed a library (requests) through my package manager. I am only able to import it in Python 2, is it meant to be like that? If not how can I import it in Python 3? </p>
python
[7]
24,506
24,507
Statement in "except" tag not working in python
<p>I have written the following code to save an album from a website.</p> <pre><code>import urllib2 import webbrowser import os page=1564848 fileno=1 for fileno in range(1,24): pages=str(page) filenos=str(fileno) picture_page = "url-to-the-website"+pages+".jpg" page=page+1 os.chdir("/home/comrider/...
python
[7]
2,816,007
2,816,008
How to only show some of the values in an array in an textbox?
<p>I have come across a problem that i cant salve, What i have is an string array with 60 values in it and they concists of either "vacant" or "reserved". Now what i need to do is to show only those arayy index that are either vacant or reserved and i have no clue on how to go about it. :/ I am stumped to say the least...
c#
[0]
2,157,440
2,157,441
Create array from dynamically generated select textfields jquery
<p>I have a repeating table row with a select list. I want to create an array from the number of select textfields a user has generated. I am using .each function to iterate through all the select textfields. Here is the code I am using. The id of the dynamically created list is "countrylist" </p> <pre><code>$("#Subm...
jquery
[5]
5,242,916
5,242,917
Upload application to android market with same version name and code
<p>I have created my app in android and for checking the in-App purchase, i uploaded the app in market as a draft application.Everything i checked regarding the in-app purchase.Now i want to publish my app in the market.Can i use the same version name and version code for that? </p> <p>Note: I tested my app as a draf...
android
[4]
942,604
942,605
Getting started with jQuery
<p>What is a good place to start playing with jQuery, besides the jQuery website. I'm having trouble with the way the site is set up - I dislike it. </p>
jquery
[5]
364,623
364,624
XMLHttpRequest error: Origin not allowed by Access-Control-Allow-Origin
<p>Basically I want to create an AddOn for Firefox which will fetch only RSS feeds from particular website. But I am getting an error:</p> <blockquote> <p>XMLHttpRequest cannot load <a href="http://www.-" rel="nofollow">http://www.-</a>** Origin <code>http://localhost:59382</code> is not allowed by Access-Control-...
javascript
[3]
4,923,656
4,923,657
how to remove an element from a nested list?
<p>if i have an nested list such as:</p> <pre><code>m=[[34,345,232],[23,343,342]] </code></pre> <p>if i write <code>m.remove(345)</code> it gives an error message saying element not in the list.</p> <p>i want to know how to remove an element from the nested list,easily??</p>
python
[7]
1,953,035
1,953,036
performing the same query on two different servers but one seems to fail
<p>I have shared hosting with two different hosting providers.</p> <p>I have the smallest DB query ever (no stress)</p> <p>all I do is simply echo out some info from a table, nothing crazy:</p> <pre><code>$loop_query = "SELECT * FROM my_table"; $sl = mysql_query($loop_query, $db_connect); while ($db = mysql_fetch_...
php
[2]
2,884,947
2,884,948
iphone EXC_BAD_ACCESS caused by emergency_mutex
<p>My iphone app occasionally crashes on the simulator and device with this message in the debugger:</p> <pre><code>Program received signal: “EXC_BAD_ACCESS”. Data Formatters unavailable (Error calling dlopen for: "/Developer/Applications/Xcode.app/Contents/PlugIns/GDBMIDebugging.xcplugin/Contents/Resources/PBGDBIntr...
iphone
[8]
3,496,992
3,496,993
Grid view data export to text file its not working in IE 9
<p>when its in local system its working fine..i can download\open\save everything its working bcoz its http:..when it come to production is https:so its not working...my code is below</p> <pre><code> Response.Clear(); Response.AddHeader("content-disposition", "attachment;filename=sample.txt"); R...
asp.net
[9]
4,315,551
4,315,552
Add image from database after building jar
<p>So, I have a java program which reads a MySQL database. It reads lots of things from there and, one of them, is the path for images.</p> <p>Is there a way I can add an image path in this database and make a built jar show it without rebuilding?</p>
java
[1]
2,505,958
2,505,959
Converting classes to an library
<p>Hi experts i have created a set of UItableviewcustom cell classes. Now can i group those classes to an static library so that i can include that library in whichever project i want and i can use it.</p>
iphone
[8]
2,460,908
2,460,909
including jquery
<p>I know that wordpress ships with jquery. I have built my site first in html and every script that I have running in the html version works fine running version 1.4.2. I included this same jquery script and now one of my features don't work. This is how I am loading jquery into the head of my site</p> <pre><code>fun...
jquery
[5]
3,880,348
3,880,349
How to represent a bitmask using DebuggerDisplay attribute
<p>I have a class with 8 bool's, and I want to represent those bools as 1 or 0 in the debugger, how can I achieve this?</p>
c#
[0]
514,225
514,226
Is there any way to display a portion of an external web site into my site?
<p>Can we do this using jQuery? if so, how? </p>
jquery
[5]
4,395,388
4,395,389
Finding and changing the value of a single "href" value using Simple Html DOM Library
<p>i need help in parsing a href attribute of a single anchore tag and then changing its value in a php file using "simple html dom" library. Below is the html code:- </p> <pre><code>&lt;li id="toggle"&gt; &lt;a id="open" class="open" href="#" style="display: block; "&gt;&lt;/a&gt;&lt;/li&gt; </code></pre> <p>Now i ...
php
[2]
1,302,335
1,302,336
'live' responses on time consuming php scripts?
<p>Many times i run time consuming PHP scripts that echo status updates like 'batch 1 finished', 'batch 2 finished' etc. </p> <p>i've noticed that sometimes the server responds in a 'live' manner and you can see these status updates as the 'jobs' finish, printed on the browser.</p> <p>But in other times you have to w...
php
[2]
2,321,892
2,321,893
I am getting errors in php
<p>I am getting this error and I have done everything I can think about. Can someone help me out I have been working on this all day. I am still a little newbie at it. Thanks.</p> <p>Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'username'@'localhost' (using password: YES) in C:\wamp\www\me...
php
[2]
3,552,681
3,552,682
jQuery Storing Element in a Variable
<p>I have the code below which when a list item is clicked an animation occurs.</p> <p>What I'm having trouble with is making the list item when clicked again reverse the animation effect.</p> <p>I'm trying to store the clicked list item in a variable but having trouble with this as my variable never stores the eleme...
jquery
[5]
3,308,650
3,308,651
Java: How to delete all the characters after one character in the String
<p>I have a String which contains a date for exemple 01-01-2012 then an space and then the time 01:01:01. The complet string is: "01-01-2012 01:01:01"</p> <p>I would like to extract only the date from this string so at the end I would have 01-01-2012 but don't know how to do this.</p> <p>Thank you</p>
java
[1]
5,636,442
5,636,443
Javascript ++ vs +=1
<pre><code>var a = "ab"; var b = "ab"; a+=1; // "ab1" b++; // "NaN" </code></pre> <p>(Tested on chrome's V8)</p> <p>Can someone explain why the results are different based on the internal atomic actions of the <code>++</code> arithmetic operator and the <code>+=</code> assignment operator with argument <code>1</code>...
javascript
[3]
4,227,235
4,227,236
Creating AVD screen based on physical device
<p>I have a Android tablet and I want to create an Android Virtual Device (AVD) whose screen is as close to the physic device as possible (in terms of size and resolution).</p> <p>I tried copying the resolution from the device settings, but the size of things in the emulator screen still look different. The device rep...
android
[4]
3,070,756
3,070,757
Remove line break for csv import
<p>I have a text field in the database with datatype also as text. It holds comments and stuff. Now when I read this and export in a csv if it finds a new line in that comment such as</p> <pre><code>This is a comment This is another line </code></pre> <p>The csv import show "This is another line" in next line and th...
php
[2]
204,193
204,194
Sometimes print_r() dies
<p>I know this is not so precise question. Sometimes <code>print_r ($something, true);</code> results in stopping request. No error happens, but its like I used the <code>die();</code> function. May it die on larger datas?</p>
php
[2]
217,249
217,250
Javascript event for dragging file onto input type=file
<p>Ok, I got drag &amp; drop upload working correctly when dragging files onto some div element, but what if the user drags the file onto the input type=file field? I have to include that field for people who want to use the regular file select, but the change event attached to that field doesn't fire when I drag a fil...
javascript
[3]
1,953,938
1,953,939
The height of text between different browsers
<p>I made an easy example and try to get the height of string.</p> <pre><code>jQuery(function () { var jqSpan = $('span'); jqSpan.css({ 'font-family': 'Arial', 'font-size': '24px', 'font-weight': 'bold' }); $('#result').text(jqSpan[0].offsetHeight); }); </code></pre> <p><a href...
javascript
[3]
4,698,370
4,698,371
Getting error: Uncaught TypeError: Object .thumbnail has no method 'hover'
<pre><code>&lt;script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"&gt;&lt;/script&gt; &lt;script type="text/javascript"&gt; $(document).ready(function () { ('.thumbnail').hover( function () { $('.hovImage').css('display', 'block'); }, function () {...
jquery
[5]
2,366,381
2,366,382
Inform Class(A), when Class(B) delegate methods complete execution using Notification in iphone SDK?
<p>I have written custom delegate methods in ClassFile(B), now i am calling them from ClassFile(A), now i want to notify Class(A) when class(B) delegate methods complete its execution. </p> <p>How can i do in Objective C (in Iphone SDK) ?? </p> <p>A working sample example will be more appreciable.</p> <p>Thanks</p>
iphone
[8]
1,886,187
1,886,188
how to get the value of the hidden list in javascript
<p>I've a hidden field in my jsp</p> <pre><code>&lt; s: hidden id ="lstId" value = "obj.lstVendors" / &gt; </code></pre> <p>Is it possible to get the list in javascript using </p> <pre><code>document.getElementbyId(lstId)? </code></pre>
javascript
[3]
3,661,225
3,661,226
Android App Developer console: Backtrack to previous version?
<p>Is it possible to backtrack to a previous version of a released Android app - if so will this version be replaced as part of the phones update service - or will I need to release a new version of the old app with a incremented version number?</p> <p>Cheers Paul</p>
android
[4]
2,096,377
2,096,378
How to get the default homepage from the default browser
<p>how can i get the default homepage from the default browser (IE, firefox,...) in C#.</p>
c#
[0]
3,453,116
3,453,117
How to create a Loading Data splash screen in C# windows Forms Application?
<p>i have an C# Windows Forms application project.and there's a form with a datagridview and a button.when user click on the button a huge amount of data will be loaded to datagridview that takes time. i want to show a simple animated gif image like "Loading Data" while data is loading, on the center of screen.like t...
c#
[0]
2,751,581
2,751,582
OO Javascript and this keyword. Object Literals
<p>I'm having issues with Javascript properties and "this" keyword. Forgive me here for asking my third and final JS OOP question. OOP in Javascript has been a headache for me today.</p> <p>I'm trying to set the property 'source' but the error console is saying it's undefined in parseSource method.</p> <p>After a lit...
javascript
[3]
4,696,978
4,696,979
validating html color codes JS
<p>i am looking for code to validate html color codes. wanna check if user typed valid color code, can you guyz help ?</p> <p>i know i need that regex stuff but i cant understand a think about that regex things :S</p> <p>thanks</p>
javascript
[3]
3,362,569
3,362,570
deleting the file (FileInfo) in asp.net
<p>in my page. when i upload image i did image management. after that i want to delete the original image but i am getting error that the file is already using, like below <strong>(The process cannot access the file 'D:\sasiweb\myimage\Images\jalsa.jpeg' because it is being used by another process.)</strong></p> <p>a...
asp.net
[9]
1,391,540
1,391,541
Get folders name from Assets directory
<p>I'm trying to get the names of my folders in "assets". I can get the names of the files with an AssetManager by using the method assetManager.list(). But the problem is that it return only files' name and not folders' names. So I'm trying to use the listFiles() method but i can't access to the Assets directory; I've...
android
[4]
2,436,287
2,436,288
accessing super class in java
<p>Am I using the superclass correctly to access the <code>title</code>, <code>minutes</code> and <code>price</code>?</p> <pre><code> public class Video extends CollectionItem { public Video(String title, int minutes, double price) { super(title,minutes,price); } public String ...
java
[1]
5,224,201
5,224,202
Javascript advanced topics
<p>Where could I find a list of descriptions of all advanced topics of Javascript? I am preparing a learning or training topics of Javascript, targeted for the users who has basic Javascript knowledge (know grammar, wrote basic function before and know basic debugging skills). And they want to learn how to proceed next...
javascript
[3]
3,147,246
3,147,247
change the value of the button of the button clicked
<p>On inserting the new <code>&lt;li&gt;</code>, I have to set the value of the button clicked to Delete. How can I do that? </p> <p>With the actual code, it`s working only once, and on adding other list, the button no more has the the value 'Delete'. </p> <pre><code>$("#mylist :button").click( function() { v...
jquery
[5]
1,719,236
1,719,237
Loading form2 many times from form1
<p>I have c# form1 with random numbers created and show those numbers in form2, and I again create new random numbers in form1, and when I try to show form2 for the secnd time I have seen the first time created numbers not the second time ( the data in form2 are not changed). I would appreciate If some one can help. T...
c#
[0]
2,400,941
2,400,942
CustomAttributes not behaving as expected
<p>I would expect there to be three lines of output from this code, but there are none:</p> <pre><code>[AttributeUsage( AttributeTargets.Property )] public class FieldAttribute : System.Attribute { public String FieldName { get; set; } } public class Host { [Field] public String FieldOne { ge...
c#
[0]
3,088,474
3,088,475
Rusty/Beginner C++ compiler error
<p>I'm a relatively experienced programmer, coming back into some C++ review for a class. We have an assignment to write a couple relatively simple c++ programs. Getting an odd error that I'm not used to, but I'm sure it's child's play for this community.</p> <pre><code>int pull_next_element (int r, std::vector&lt;i...
c++
[6]
4,465,338
4,465,339
Best way to do jquery form validation?
<p>Okay, so we have input boxes for the following:</p> <pre><code>firstname, lastname, email, password, city, state, captcha, terms and conditions </code></pre> <p>I've done the validation for all of these input boxes.</p> <p>This validation is seperate for each ID, and works via <code>change()</code></p> <p>The e-...
jquery
[5]
4,013,364
4,013,365
Get the value of a URL after the last slash
<p>All, Say I have the following URL values:</p> <p><a href="http://website.com/tagged/news/" rel="nofollow">http://website.com/tagged/news/</a> <a href="http://website.com/tagged/news" rel="nofollow">http://website.com/tagged/news</a> <a href="http://www.website.com/tagged/news/" rel="nofollow">http://www.website.com...
php
[2]
5,563,542
5,563,543
Android HttpPut example code
<p>could anyone give me a httpPut request example code?</p>
android
[4]
5,267,043
5,267,044
Need to try and count repeated lists within a list
<p>Im trying to count how many repeated lists there are inside a list. But it doesnt work the same way I could count repeated elements in just a list. Im fairly new to python, so apologies if it sounds too easy.</p> <p>this is what i did</p> <pre><code>x= [["coffee", "cola", "juice" "tea" ],["coffee", "cola", "juice...
python
[7]
135,831
135,832
Prevent horizontal scrolling with javascript?
<p>Does anyone know if there is a way to prevent the user from being able to scroll horizontally? ive used overflow-x:hidden css, but it can still sometimes scroll (but only sometimes, its weird..)</p> <p><a href="http://www.kaiserroof.com" rel="nofollow">http://www.kaiserroof.com</a></p> <p>Would it be possible to d...
javascript
[3]
3,435,933
3,435,934
Capturing the contents of native prototypes
<p>Try and do the following:</p> <pre><code>for (var key in String.prototype) console.log(key); </code></pre> <p>It gives you...nothing (well, unless you defined some foreign stuff yourself.) However, you still have <code>String.prototype.split</code> for example. I tried it on every other native object (<code>Nu...
javascript
[3]
4,847,057
4,847,058
Header location redirect after logout to remove ?q=logout
<p>As it says I need to remove the ?q=logout. First I tried this </p> <pre><code>if ($_GET["q"] == "logout") { $user-&gt;user_logout(); header("location:".$_SERVER["SERVER_NAME"]); } </code></pre> <p>The second thing i tried:</p> <pre><code>if ($_GET["q"] == "logout") { $user-&gt;user_logout(); header("location:...
php
[2]
4,772,055
4,772,056
Doing 2 things at the same time in Java
<p>Well, I'm working on an online game in Java. I have a client and a server. And the speech system waits for a new message to be displayed like this:</p> <pre><code>public void addSpeech(String msg) { String newMsg = parsel10n(msg); m_narrator.addSpeech(parsel10n(newMsg)); while (!m_narrator.getCurrentLin...
java
[1]
5,676,126
5,676,127
display images from a folder in a specific order
<p>In my php project I have a folder named Gallery1 (path is images/gallery1). Which contains images named 1.jpg, 2.jpg, 20.jpg, 8.jpg etc. I want to display all the images from that folder in ascending order (1.jpg, 2.jpg, 8. jpg, 20.jpg etc). Does anyone know this?</p> <p>Thanks in advance</p>
php
[2]
895,050
895,051
Are there other Type in addition to the class to be called by hasattr
<p>For code:</p> <pre><code>class a(object): a='aaa' b=a() print hasattr(a,'a') print hasattr(b,'a') </code></pre> <p>who can be called by hasattr except 'class somebody'?</p> <p>Thanks!</p>
python
[7]
4,043,645
4,043,646
Android SOAP issue
<p>i m calling soap web service in my application. i m getting an image URI as a response. i want to set it to the image view. i m not able to do that.</p> <p>how can i do that?</p> <p>pls help me..</p>
android
[4]
3,191,448
3,191,449
android list contents notifications
<p>how to calculate total number of items in a listbox and display in a text box?</p> <p>I want to dynamically add the number of items in the list and display in front of the heading in brackets and also in front of its image like a notification showing the pending requests</p>
android
[4]
5,652,316
5,652,317
After using the jQuery ".css" method, how do you change it back to normal?
<p>This is my original CSS for my <code>#frame</code> div.</p> <pre><code>....#frame{ position:relative; top:35px; } </code></pre> <p>Then, I use jQuery to change the CSS of my div...</p> <pre><code>$('#frame').css("position","absolute"); $('#frame').css("left",50); </code></pre> <p>Now, how do I clear a...
jquery
[5]
1,619,377
1,619,378
Gridview does not comes up using custom class
<p>My gridview does not renders if I am using my derived GridClass, It does render when I add GridView object to myLayout but not when I add My Grid Object/ :( .Here's is the code</p> <pre><code> public class parentClass extends MyotherClass { Grid _gridV = null; public void createG...
android
[4]
3,892,397
3,892,398
Traversing through a generic collection
<p>Lets say I have function </p> <pre><code>void sell(Collection&lt;? extends T&gt; items) { for (? e : items) { stock.add(e); } } </code></pre> <p>as you can see i want to iterate through the items, but I cannot use the notation <code>? e</code>, because it spits out the error "illegal start of expressio...
java
[1]