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
518,656
518,657
little jquery calculation
<p>I need some simple calculations done using jquery.</p> <p>This example <a href="http://jsfiddle.net/tbL5r/" rel="nofollow">http://jsfiddle.net/tbL5r/</a> is pretty close. It just needs a little tweaking:</p> <ol> <li><p>the user should input the price.</p></li> <li><p>I need the sum of the all prices calculated.</...
jquery
[5]
2,258,581
2,258,582
how to import a project's package into an android project?
<p>how can we import a project's package into an android project?</p>
android
[4]
3,639,930
3,639,931
php for "high-traffic" websites
<p>I have read that PHPs "probable" weakness is how it handles "concurrency". With only sessions and cookies to keep track of user state, how can PHP handle the following situations with high accuracy:</p> <ol> <li><p>multiple users check out with one item that has only 1 stock in inventory (sorry for grammar mistakes...
php
[2]
175,014
175,015
Jquery Insert HTML
<p>I'm using: <a href="http://jquery.malsup.com/form/#getting-started" rel="nofollow">http://jquery.malsup.com/form/#getting-started</a> to submit my form, Ajax styleee.</p> <p>However the form submits correctly and the data is sent however the fields on the form continue to have data in them. How can I clear them on ...
jquery
[5]
3,463,917
3,463,918
Find real url of masked image in php?
<p>If theres n image hidden like this:</p> <pre><code>?ID=578 </code></pre> <p>insteadof its real url, is there a way to find out?</p> <p>I tried looking at the web console to see if its downloaded but i only found the php request.. url is nowhere , help me please</p>
php
[2]
5,193,498
5,193,499
Search a string for newlines within a string just containing "\n"
<p>I have a really annoying issue that I can't fix :(</p> <pre><code>private static final String NEW_LINE = System.getProperty("line.separator"); text = "\n"; int count = text.split(NEW_LINE).length; </code></pre> <p><code>count</code> keeps returning 0 when it should return 1 I think its because <code>\n</code> isnt...
java
[1]
4,613,668
4,613,669
How to find out a^b of very large numbers in python?
<p>I am trying to find out <code>a^b</code> in python, of really large no.s </p> <p>My code is this:</p> <pre><code>t=raw_input() c=[] for j in range(0,int(t)): n=raw_input() a=[] a,b= (int(i) for i in n.split(' ')) c.extend(pow(a,b)) for j in c: print j </code></pre> <p>And I am getting an error...
python
[7]
3,597,654
3,597,655
MPMusicPlayerController doesn't respect device mute switch?
<p>I'm using the MPMusicPlayerController application music player, created like:</p> <pre><code>appMusicPlayer = [MPMusicPlayerController applicationMusicPlayer]; </code></pre> <p>The issue is that it will play music no matter which setting the device mute switch is in, it doesn't seem to care either way. Is there so...
iphone
[8]
3,925,179
3,925,180
Is there any way to optimise this code?
<p>I have a piece of code which will invert all the checkboxes on my form. I have multiple elements (not just checkboxes but also <code>&lt;input type='text'&gt;</code>'s) in it. The reason I need it to be optimised is because it takes about two to three seconds to select all the checkboxes (275 right now).</p> <p>He...
javascript
[3]
2,636,879
2,636,880
Should I dispose of an object such as Hashtable or a string by setting it to null?
<p>I have a Hash table that takes strings. What is the best way to dispose them ? After using the hash table, should I call clear and then set the object to null ? Or would just setting the hash table object to null suffice ? </p>
c#
[0]
464,616
464,617
how to detect when a shortcut key is pressed in javascript
<p>How can i detect a shortcut key, [ in my case [ ctrl + shift + k ] ] in javascript? Like, i have to show a dialog if user presses this key.</p>
javascript
[3]
1,864,923
1,864,924
jQuery - parseJSON not a function?
<p>I'm using Wordpress 3 and jQuery 1.4.2. Firebug tells me $.parseJSON is not a function and I'm stumped as to why. </p> <p>Any suggestions are appreciated.</p> <pre><code>$(document).ready(function(){ $('#subscribe_form_submit').click(function(){ function updatePage(theResponse, textStatus, XMLHttpRequest){ ...
jquery
[5]
5,009,133
5,009,134
How to root android device, Emulator?
<p>I'm making an application in android. In which I want to show Punjabi text in my view, most people told me we can add different fonts through rooting. After that I'm able to show Punjabi text in device. Can you tell me how I can root my emulator or android device so I can show Punjabi font in my application.</p> <p...
android
[4]
2,740,659
2,740,660
Error: 'template<class T> class Two' used without template parameters
<p>Hey so I'm trying to compile:</p> <pre><code>//ASSIGNMENT #include &lt;iostream&gt; #include &lt;string&gt; using namespace std; template &lt;class T&gt; class Two { private: T x,y; public: Two (T a, T b); friend void Show (Two p); ~Two(); }; //ASSIGNMENT template &lt;class...
c++
[6]
1,014,816
1,014,817
How to search the children of a HTMLDivElement?
<p>I have an HTMLDivElement, and my goal is to find a div nested beneath this. Ideally, I'd want something like getElementById, but that function doesn't work for HTMLDivElement. Do I need to manually traverse the graph, or is there an easier way?</p> <p>Thanks</p>
javascript
[3]
2,454,024
2,454,025
How can I get one variable to equal 0 by using another variable to define that variable?
<p>In Java, suppose I have two variables, <code>x1</code> and <code>xName</code>.</p> <p>How can I get <code>x1</code> to equal 0 by using <code>xName</code>?</p> <p><code>xName</code>'s value is <code>"x1"</code>. How can I change <code>x1</code>'s value with <code>xName</code>?</p> <p>I have my reasons for not jus...
java
[1]
4,250,874
4,250,875
How can i sort the dictionary using keys in c#---Is it possible using LINQ?
<pre><code> Dictionary&lt;string,string&gt; l_dictData = new Dictionary&lt;string,string&gt; </code></pre> <p>the above dictionary contains data like this:</p> <pre><code> (1)key = "4" value"122" (2)key = "8" value"1772" (3)key = "0" value"166" </code></pre> <p>Required output:</p> <pre><code> (1)ke...
c#
[0]
20,033
20,034
extend SplFileObject with fread method
<p>PHP5 introduced an object-oriented file wrapper, <strong>SplFileObject</strong>. I guess I just found out why hardly anybody is using it. It's purely line-oriented, there is no fread() method - which the corresponding frwite seemed to suggest.</p> <p>So now I'm wondering if I can extend it. I'm however not sure wha...
php
[2]
781,170
781,171
jQuery that works inside of a function ... but not outside?
<p>In the following jQuery code:</p> <pre><code> $(document).ready(function(){ function parse(document){ $(document).find("entry").each(function(){ $("#items").append( '&lt;h3&gt;&lt;a href="#"&gt;'+$(this).find('title').text()+'&lt;/a&gt;&lt;/h3&gt;'+ '&l...
jquery
[5]
4,140,604
4,140,605
how will this cout statement run
<pre><code>int a[10][5]; for (int i = 0; i &lt; 10; i++) { for (int j = 0; j &lt; 10; j++) { cout &lt;&lt; i[j[a]]; cout &lt;&lt; j[i[a]]; } } </code></pre> <p><em>Edit</em>:assume the values are already initialized to the array and is this cout valid then? </p> <p>please explain the <co...
c++
[6]
5,327,549
5,327,550
How can I tell if a certain key was pressed in Python?
<pre><code>import sys print (sys.platform) print (2 ** 100) input('press Enter to exit') </code></pre> <p>Suppose I wanted to use the number 1 as the button that must be pressed to exit. How would I go about doing this?</p>
python
[7]
227,394
227,395
How to use jQuery mouseover from an array?
<p>I have a sample code:</p> <pre><code>&lt;a href=""&gt;&lt;/a&gt; &lt;textarea&gt;&lt;/textarea&gt; &lt;object&gt;&lt;/object&gt; &lt;img src="" /&gt; &lt;div id="content"&gt;&lt;/div&gt; </code></pre> <p>I had using this:</p> <pre><code>jQuery("a").mouseover(function() { alert(); }); jQuery("textarea").mous...
jquery
[5]
934,593
934,594
now() returns wrong value when date() and server time are correct
<p><code>now();</code> = 1319959284</p> <p><code>date("Y/m/d");</code> = 2011/10/30</p> <p>if I run <code>date</code> on my server, the time is spot on</p> <p><strong>edit 3</strong> I'm an idiot</p> <p><strong>edit 2</strong> I am thinking that the UNIX timestamp is not the same as the MYSQL timestamp</p> <p><str...
php
[2]
2,957,886
2,957,887
How to fetch a select tag value from child page javascript?
<p>I have a parent page where a select tag is there. It has a number of options. Now the user can select one of the options.</p> <p>But the problem is the select tag doesnt have an id instead it has a name which is generated in runtime.</p> <p>Now i want to fetch the selected value from child page javascript. Can an...
javascript
[3]
5,417,188
5,417,189
Ordered function defenitions | Benefits
<p>Jslint will call out errors if functions are defined out of order.</p> <p>Obviously jslint is strict, but I wonder if there are any benefits to putting functions in order. </p> <p>By that I mean defining them before they are called.</p>
javascript
[3]
5,584,079
5,584,080
Why am I getting null when trying to retrieve a value from a ContentValues object?
<p>I am getting a NullPointerException when trying to retrieve/insert values from a ContentValues object that I'm a passing to my database method. I have several columns in my db table and instead of passing all those as params to the method, I'm trying to simplify it a little bit.</p> <p>Here's a sample of the code:<...
android
[4]
2,730,996
2,730,997
Starting video capture on one click in android
<p>I want to start camera and also to automatically start recording just by clicking an app in android. I have the code to start the camera but I do not know how to start auto capture of the video. Please help. the code I have for launching camera- </p> <pre><code>@Override protected void onCreate(Bundle savedInstanc...
android
[4]
2,940,176
2,940,177
Define a temporary dir under www to upload files
<p>I'm trying to upload a file to the apache public_html directory. Well I believe it deserves to mention that I'm on a virtual hosting environment running on a VPS with a few domains and sub-domains.</p> <p>Usually on my XAMPP server I wouldn't have any problems loading files to temporary folder but on the new server...
php
[2]
4,835,210
4,835,211
can't go back button
<p>I have a problem with my Android app. I have three Activities that all connect with one another with a Image button. </p> <p>My problem is I can't go back on any of the pages, just forwards. I have been reading about the back button and how to keep its state and not kill (End) it, so the user can click back if need...
android
[4]
5,022,453
5,022,454
Display image intent rebuilds cache
<p>When I create an intent and pass it a URI of the path of the image on the <a href="http://en.wikipedia.org/wiki/Secure_Digital" rel="nofollow">SD card</a>, like this:</p> <pre><code>Intent intent = new Intent(); intent.setAction(android.content.Intent.ACTION_VIEW); intent.setDataAndType(uri, "image/*"); start...
android
[4]
1,176,792
1,176,793
Option to create new contact from pick list
<p>My application wants a functionality of picking a contact from the phone contact, I have achieved this using the following intent </p> <pre><code>Intent intent = new Intent(Intent.ACTION_PICK, People.CONTENT_URI); startActivityForResult(intent, 001); </code></pre> <p>How do i start pick contact activity with an ...
android
[4]
2,223,945
2,223,946
gwt in netbeans
<p>can i install GWT in netbeans?</p>
java
[1]
848,845
848,846
How to display session values in php
<p>I used session as a array and stored user selected values in that session array. I want to check particular value present in that session array, if user selected value present present in that session ignore it otherwise add in that session array.</p>
php
[2]
5,770,695
5,770,696
does onCreate fire any listener - android
<p>I am creating a android library, In that I want to find if the OnCreate of the main application is running? . I dont know whether oncreate fire any listener. Anybody knows will oncreate fires any listener. Any ideas? Thanks.</p>
android
[4]
4,797,068
4,797,069
Javascript Conflict ajax mail and scriptaculous
<p>I've added a javascript element I found in a guide. It is as follows</p> <pre><code>$(document).ready(function () { $('.dropdownbutton').click(function () { $.post("send.php", $(".mycontactform").serialize(), function (data) { }); $('#success').html('...
javascript
[3]
4,392,771
4,392,772
Android shake detection on emulator
<p>I am pretty new to android. I have a use case where I need to detect a shake and show some images in my application. Can I test shake functionality on android emulator ? What are the other alternatives apart from testing it on a real phone ?</p>
android
[4]
3,336,050
3,336,051
Why is my function not working?
<p>Now that I have my other questions answered, this function isn't working. What's wrong?</p> <p><a href="http://stackoverflow.com/questions/5461425/weird-javascript-statement-what-does-it-mean">Weird JavaScript statement, what does it mean?</a></p> <p><a href="http://stackoverflow.com/questions/5460733/how-to-handl...
javascript
[3]
597,575
597,576
Why is the output of `echo true ? 'a' : true ? 'b' : 'c';` 'b'?
<p>I have this bit of PHP code:</p> <pre><code>echo true ? 'a' : true ? 'b' : 'c'; </code></pre> <p>The output of this is:</p> <blockquote> <p>b</p> </blockquote> <p>But the output I expected was:</p> <blockquote> <p>a</p> </blockquote>
php
[2]
211,938
211,939
How to define two dependent generic interfaces?
<p>I encountered a problem while using a generic interface. Initial condition was as follows:</p> <pre><code>interface Itemplate1 { ... } interface Itemplate2&lt;T&gt; where T : Itemplate1 { ... } </code></pre> <p>It works like a charm! But when I kept going to do rest of my application design, I noticed tha...
c#
[0]
2,442,824
2,442,825
multiple spans in a charsequence
<p>when ever I set a span in a charsequence, then set the text in a text view its fine, it comes out right. I am using this</p> <p>Ssb.setSpan(new StyleSpan(Typeface.ITALIC), start, end, 1);</p> <p>Then set the text of the TextView.</p> <p>But when I get the text from the text view and then get the text from it usin...
android
[4]
575,838
575,839
Javascript will not load the pictures
<p>I want to load these banner.png files to the screen but all it prints out is the actual text from the banner array?</p> <pre><code>function randImg(){ var banner = new Array(); banner[0] = 'banner1.png'; banner[1] = 'banner2.png'; banner[2] = 'banner3.png'; maxImg = banner.length; randNum = Math.floor(Math.random(...
javascript
[3]
4,754,295
4,754,296
Eclipse is not recognizing my android phone
<p>I am using eclipse on windows i want to run application on my samsung android phone but eclipse is not recognizing my device pease somebody help me</p>
android
[4]
3,742,632
3,742,633
How can I add commas to numbers in PHP
<p>I would like to know how can I add comma's to numbers. To make my question simple.</p> <p>I would like to change this:</p> <pre><code>1210 views </code></pre> <p>To:</p> <pre><code>1,210 views </code></pre> <p>and :</p> <pre><code>14301 </code></pre> <p>to</p> <pre><code>14,301 </code></pre> <p>and so on fo...
php
[2]
2,585,766
2,585,767
Accessing method and parameter history with Java
<p>I'm currently working in a project in Liferay in which i'd like to be able to access my method and parameters these methods were given, in the history. This is done in case there is an exception being thrown in certain blocks of code.</p> <p>I've already searched and it is easy to get the method name history (Threa...
java
[1]
3,578,947
3,578,948
ASP.NET Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack
<p>I have problem with that code:</p> <pre><code>HttpContext.Current.Response.Redirect("~/Examples/my.aspx"); //or HttpContext.Current.Response.Redirect("~/Examples/my.aspx",true); </code></pre> <p>the code above generates the error as I mentioned at this topic's title. </p> <p>I simply need to refresh my ASP.NET pa...
asp.net
[9]
3,635,454
3,635,455
Saving XML file content to String or StringBuilder
<p><BR></p> <p>I want to save The whole content of XML file to a string or stringbuilder. Please let me know how can i achive that??<BR></p> <p>My Function needs to copy or Save a XML file content Completely to string or stringbuilder.<BR> It is External Content(XML File).After that I need to change the Content(onf f...
c#
[0]
3,101,552
3,101,553
OutOfMemoryError while rendering in libgdx
<p>I have to render mesh array in using libgdx in render(). I used handler because every time I'm getting new data in getMeshToRender() method in meshArr array.</p> <pre><code> onCreate() { handler.removeCallbacks(sendUpdatesToUI); handler.postDelayed(sendUpdatesToUI, 1000); // 1 s...
java
[1]
2,583,337
2,583,338
ASP.NET: Best way to grab a file path from a form thats residing in network share (UNC path)
<p>In our intranet environment I am trying to have a way of (like file upload / telerik file explorer) selecting a file using a browser and then returning the path only. I need to save the path in database and users need to select the file from network shared drive.</p> <p>For telerik explorer u need to implement cust...
javascript
[3]
1,850,122
1,850,123
How to export html form data to json file
<p>How do I save html registration form data into a JSON file then log in based on it, without using any server side scripting languages? I want to use only Javascript and jQuery.</p> <p>HTML file "simple form" contains:</p> <p>First Name, Middle Name, Last Name, User Name, Password, Confirm Password, E-Mail, Phone</...
javascript
[3]
1,967,549
1,967,550
ArrayList : How does the size increase?
<p>I have a basic question on Java Array List.</p> <p>When a Array List is declared and initialized using default constructor, memory space for 10 elements will be created. Now, When I add 11th element, what happens? Will a new memory space created with 20(or more ) element capacity(This requires copying elements fro...
java
[1]
2,499,658
2,499,659
Can I add ready() in the top of a jQuery plugin?
<p>I am trying to write a plugin, following the guidelines from jQuery site. </p> <p>I am also trying to incorporate everything into it, including creating new div elements. </p> <p>Those div's need to be created on document ready, so I am trying to figure the best options here.</p> <p>This is what I currently have ...
jquery
[5]
3,167,010
3,167,011
store different objects
<p>I want to create different classes and they should be all stored in one ArrayList. If i use:</p> <pre><code>interface ProgramInterface { void someMethods(); } public abstract class CustomProgram implements ProgramInterface { // stuff } </code></pre> <p>Then i can make my own class like</p> <pre><code>cla...
java
[1]
5,633,543
5,633,544
collections in C#
<p>I am coming from a C++ background and i am trying to teach myself C# I am still a student and this isnt a school project and that i am on break right now. My main focus has been C/C++, java</p> <p>I have an old school project from 2 years back that i did in C++ that stores DVD, book, DVD, info in a container and th...
c#
[0]
6,001,091
6,001,092
Take screenshot from UIVIEW+ipad
<p>I want to take the screenhot of viewcontroller I had write this:-</p> <pre><code>- (UIImage *)captureScreenInRectWOScroll:(CGRect)captureFrame { CALayer *layer; layer = self.view.layer; UIGraphicsBeginImageContext(captureFrame.size); CGContextClipToRect (UIGraphicsGetCurrentContext(),captureFra...
iphone
[8]
5,418,333
5,418,334
android Runtime Exception
<p>When i run my android application it shows an exception "android runtime exception" with a message "Error: thread attach failed". it happens before the execution of "OnCreate" mathod of main class. what will be reason for that error?? anybody please help. </p>
android
[4]
2,028,352
2,028,353
php mkdir, folder name and structure
<p>I need to make an new folder on my server, and this also works just fine using mkdir()</p> <p>But can someone tell me how to make both folder name and structure using mkdir()??</p> <p>Folder name will be = $_SESSION['username']; </p> <p>and structure inside the new folder should be = /folder1/folder2/folder3/fold...
php
[2]
1,636,722
1,636,723
text editor for android - how to hook into other applications
<p>Can you please point me into the right direction please.</p> <p>Basically I would like to code up a text editor application to suite my personal needs (would like it to specially handle some keyboard combination - as shift + x, etc).</p> <p>The first question - is to how to implement the text editor itself - I kno...
android
[4]
301,502
301,503
Designing an asynchronous task library for ASP.NET
<p>The ASP.NET runtime is meant for short work loads that can be run in parallel. I need to be able to schedule periodic events and background tasks that may or may not run for much longer periods.</p> <p>Given the above I have the following problems to deal with:</p> <ul> <li>The AppDomain can shutdown due to change...
asp.net
[9]
3,083,310
3,083,311
jquery with radio button
<p>whats wrong with this code? Why don't show value?</p> <p>Thanks</p> <pre><code>&lt;script&gt; $(document).ready(function() { $('#radio_div').change(function(event){ var value = $("input[@name='rdio']:checked").val(); $('#update_text').html('Radio value:' + value); })...
jquery
[5]
538,684
538,685
php validate integer
<p>I`m wonder why this not working</p> <pre><code> echo gettype($_GET['id']); //returns string if(is_int($_GET['id'])) { echo 'Integer'; } </code></pre> <p>How to validate data passing from GET/POST if it is integer ?</p>
php
[2]
2,234,083
2,234,084
Searching list of lists
<p>I have a list of data like this</p> <pre><code>data = [['A',11],['A',22],['B',14],['C',23],['C',31],['B',12]] </code></pre> <p>I put the unique items in an other list like this:</p> <pre><code>search=[] for item in data: if search.count(item[0]) == 0: search.append(item[0]) # search contains ['A', 'B...
python
[7]
5,865,177
5,865,178
Android fingerpaint canvas color
<p>I'm messing about with Fingerpaint.java in the SDK <a href="http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/graphics/FingerPaint.html" rel="nofollow">http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/graphics/FingerPaint.html</a></p> <p>I've ma...
android
[4]
4,811,934
4,811,935
Simple dropdown and ie6 problem
<p>I have created a dropdown menu with jquery: <a href="http://www.designer-depot.com/lgn/index.html" rel="nofollow">here</a> Everything is ok but in ie6. I know ie6 not supported z-index, but is there any solution for ie6? Thanks in advance</p>
jquery
[5]
256,180
256,181
Why my androiv virtual device only opens the google page in my WebView?
<p>If I write </p> <pre><code>webView.loadUrl("http://www.google.com"); </code></pre> <p>The google page opens normally, but if I put another addres, like</p> <pre><code>webView.loadUrl("http://www.android.com"); </code></pre> <p>The page does not open. Is this a bug with my AVD? It does not appears anyone error me...
android
[4]
2,328,045
2,328,046
php - not able te receive the email
<p><strong>Below is the code</strong></p> <pre><code>&lt;?php ini_set('display_errors',1); error_reporting(E_ALL|E_STRICT); include('config.php'); // table name $tbl_name="temp_members_db"; // Random confirmation code $confirm_code=md5(uniqid(rand())); // values sent from form $name=$_POST['name']; $email=$_POST[...
php
[2]
4,442,571
4,442,572
How to find error occurring in getScript in jquery
<p>I am using getScript function to fetch and execute a js file. </p> <p>Whenever there is an error, execution stops and I don't see any error message in firebug. No description of error. </p> <p>I even tried surrounding try catch around getScript, even that doesn't work. So how to find what error occurred while runn...
jquery
[5]
4,997,481
4,997,482
Javascript "cannot read property "bar" of undefined
<p>I've got a function that takes 3 parameters. The problem I have is one of the parameters is a property of a sometimes undefined value of an Object (i.e. it takes in <strong>thing.foo.bar</strong>, and sometimes <strong>thing.foo</strong> is undefined, so it can't access <em>bar</em>). </p> <p>What's a way around th...
javascript
[3]
2,731,132
2,731,133
Go back to start or repeat raw input a number of times
<p>I have written a code and it works, now as there are variable in the code I want at the end to ask the person if they wish to quit/continue, they say continue it goes all the way back to the first question. Also is there a way to ask at the start how many times the question is to repeat itself. Sorry can't upload co...
python
[7]
4,743,656
4,743,657
How can I check through a string array of roles and return the most senior role?
<p>The following code returns an array of roles for my user:</p> <pre><code>var userRoles = Roles.GetRolesForUser(); </code></pre> <p>The possible roles are:</p> <pre><code>public enum RoleType { Default = 10, Guest = 20, User = 30, Admin = 40, Super = 50 } </code></pre> <p>How can I make my cod...
c#
[0]
5,493,128
5,493,129
JavaScript + Reference object in another function?
<p>If I create an object in an onLoad function, then attempt to reference that object within an onChange function, the object is 'undefined'... how do I reference it?</p> <p><strong>HTML:</strong></p> <pre><code>&lt;body onLoad="loaded()"&gt; &lt;select onChange="updateObject(event)"&gt; &lt;option value=...
javascript
[3]
5,223,841
5,223,842
Forced to use jQuery instead of $
<p>I'm was doing my page with jquery scripting all of then written like <code>$.</code> , <code>$(</code> My sample code like here</p> <pre><code>&lt;script src="http://code.jquery.com/jquery-latest.js"&gt;&lt;/script&gt; function dome(){ $.ajax({ async: false, type: 'POST', url: 'test.php', suc...
jquery
[5]
3,218,897
3,218,898
Android: SearchView
<p>this is what I have in xml file </p> <pre><code> &lt;SearchView android:id="@+id/searchView1" android:layout_width="fill_parent" android:layout_height="fill_parent" android:iconifiedByDefault="false"&gt; &lt;/SearchView&gt; </code></pre> <p>This is how its looks on device</p>...
android
[4]
2,237,615
2,237,616
how to make video player fluid width and height?
<p>how would you make these video players height and width 100% and resize with the page <a href="http://scripts.reloadlab.net/customYtPlayer/" rel="nofollow">http://scripts.reloadlab.net/customYtPlayer/</a></p> <p><code>&lt;a class="youtube" href="http://www.youtube.com/watch?v=CD2LRROpph0" style="width: 100%;"&gt;&l...
jquery
[5]
2,729,250
2,729,251
Why c++? Where to start?
<p>I know there was many questions like this one, but please hold on one more. All programming languages I know now are made for web purposes. I've been learning ActionScript, php and a bit of Javascript, AJAX, etc.. I've liked php very much but I'm still looking something I'll really love! That's why I want to try som...
c++
[6]
6,009,105
6,009,106
jquery click image select next span without class or id
<p>I am trying to add a text line to an image without an id or a class I have a series of images such as</p> <pre><code> &lt;img src="../img/star.png" /&gt;&lt;span&gt;no text here until left img is clicked&lt;/span&gt; &lt;img src="../img/someotherpicture.png" /&gt;&lt;span&gt;no text here until left img is cli...
jquery
[5]
597,462
597,463
Forms with a variable number of fields
<p>I'm attempting to create a sort of marketplace. Each item on the market has a type (i.e. the item being sold), a value, a quantity, a seller name, and an id, and all of this information is stored in a MySQL database.</p> <p>When the user views the market, all entries in the market are returned. In addition, an inpu...
php
[2]
3,704,391
3,704,392
Passing Variables Error
<p>Im getting this annoying error and tried every i know but in this case it hasnt helped.</p> <p>I have in my delegate....</p> <pre><code>vid_name = [push objectForKey:@"vid"]; </code></pre> <p>(in the console .... vid = "video" )</p> <p>now in my normal page i have </p> <pre><code>NSString *videoName = [(Missile...
iphone
[8]
133,202
133,203
java: how to read a txt file to an Array of strings
<p>Hi i want to read a txt file with N lines and the result put it in an Array of strings.</p>
java
[1]
5,123,645
5,123,646
Returning after a period of inactivity in my Android Application causes destroy set Values
<p>I have a Problem with my Application that when it goes to the <strong>background</strong> and then return back after <strong>2-3 minutes of inactivity</strong>, then Application's <strong>on-Create method</strong> is called and values are set to the <strong>default values</strong>, kindly help me to diagnose this Pr...
android
[4]
3,715,553
3,715,554
Bold First Line of Output
<p>I need to add <code>&lt;b&gt;</code> tags around the first line of text, but not contained in a paragraph tag - rather just all the text before the first <code>&lt;br&gt;</code>. </p> <p>It's a PHP string being echoed, so it seems to me pretty simple but I'm not sure how I'd get just that section of text, bold it, ...
php
[2]
1,187,883
1,187,884
Implement new tab on web browser control for C#
<p>I want to build my own web browser, but I'm stuck on operation for adding new tab, does anyone have any idea to make it done?</p> <p>The final result will should like this.</p> <p><img src="http://i.stack.imgur.com/Em0Lx.png" alt="enter image description here"></p>
c#
[0]
3,045,128
3,045,129
Which is fastest in PHP?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/1813673/php-string-concatenation-a-b-vs-a-b-performance">PHP String concatenation - &ldquo;$a $b&rdquo; vs $a . &ldquo; &rdquo; . $b - performance</a> </p> </blockquote> <pre><code>&lt;?php $url = 'http://ww...
php
[2]
384,281
384,282
Passing type 'var' into a method in C#
<p>I have some sub queries which are of data type var. These are getting working on a data table. I would like to pass these into another method, how can i do that? Ex:</p> <pre><code> var subquery1= from results in table.AsEnumerable() where //some condition select new ...
c#
[0]
333,180
333,181
How to remove leading and trailing spaces from strings in a Python list
<p>i have a list:</p> <pre><code>row=['hi', 'there', 'how', ...........'some stuff is here are ','you'] </code></pre> <p>as you can see <code>row[8]='some stuff is here are '</code></p> <p>if the last character is a space i would like to get everything except for the last character like this:</p> <pre><code>if row[...
python
[7]
5,879,438
5,879,439
SQlite unable to open
<p><img src="http://i.stack.imgur.com/LAVzn.png" alt="enter image description here"> I create my database using sqliteadmin (version 0.8.3.2),I place this file into my asset directory and then copy this file into <code>data/data/mypackage/databases/mydb</code>,its ok.now when I am trying to open this file getting excep...
android
[4]
1,301,906
1,301,907
How to register event on elements that don't yet exist?
<p>I am trying to register a event on elements like this:</p> <pre><code>$(document).ready(function() { $('.classname').change(function(){ alert ('This line is never triggered'); }); }); </code></pre> <p>But the problem is that .classname elements are later loaded into the dom by ajax. So, how do I corre...
jquery
[5]
1,991,320
1,991,321
Variables in an array
<p>I'm trying to put a mysql query into a function, however when I do a mysql_fetch_array I need to specify the row's name. How can I put a variable in a function?</p> <pre><code>function config($setting_name,){ while($config_db = mysql_fetch_array(mysql_query("SELECT {$setting_name} FROM config WHERE id='1'") { ...
php
[2]
5,258,935
5,258,936
How can I pass array of objects as arguments to a RESTful service
<p>I've a types class, which contains key and value properties and I need to send array of types objects to restful service. I tried the below url, but its not working. Please correct it. Thanks in advance.</p> <p><a href="http://localhost:8080/CRService/services/CRService/newContentObjectRequest?User=abcd&amp;types="...
c#
[0]
2,455,530
2,455,531
exception reading http Stream
<p>The code pasted below gets an exception on tha line that says... InputStream in = new BufferedInputStream(urlConnection.getInputStream());<br> It's an IO exception that says: java.net.UnknownHostException: www.android.com</p> <p>I checked and that is a valid url. I got the original code from the android docs on Ht...
java
[1]
5,776,365
5,776,366
What data structure discards the oldest item when a new one is added?
<p>I've been trying to remember this and it's driving me crazy.</p> <p>Basically, it's like a small array, of let's say size five, and as you add items it starts to fill up. When it's full, and you add a new item, the oldest one (first added) is removed.</p> <p>You can access the values by something like variable[0],...
c++
[6]
428,232
428,233
How to do image rotation as well as image 3DTransform?
<p>How to do image rotation(CGAffineTransformRotate) as well as image 3DTransform(CATransform3DRotate)? My problem is when I change the rotation and then make 3D Transform, Image goes to the initial image. Similarly when I change the 3D Transform after change the rotation goes to the initial image. I am using below cod...
iphone
[8]
2,405,023
2,405,024
PHP white screen on error
<p>I'm getting a white screen every time a PHP application drops an error. I checked php.ini and error_reporting = E_ALL and display_errors = On Also I checked with the php_info() function and error_reporting is set to 6135 which is correct.</p> <p>I already tried adding: error_reporting(E_ALL); ini_set('display_err...
php
[2]
5,946,314
5,946,315
Android notification of
<p>Android, Notification, and download this information by clicking on the Notification inside information, this information is an apk file, how to get the click event?</p>
android
[4]
5,915,471
5,915,472
JQuery function is not working after URL Rewriting
<p>Refer to my this question: <a href="http://stackoverflow.com/questions/5403247/page-not-redirecting-properly-url-rewriting-asp-net">Page not redirecting properly, URL rewriting (Asp.NET)</a> </p> <p>Which is resolved except one thing.</p> <p>Though I have put the code to eliminate post back for .jpg and other file...
asp.net
[9]
3,154,061
3,154,062
how client browser data is saved in php array
<p>how client browser data is saved in php array if php processes on server side?</p>
php
[2]
2,119,424
2,119,425
Can I explicitly reference a JavaScript global variable that's been shadowed by a local with the same name?
<p>I've seen tons of posts about the difference between global and function scope in JavaScript, far too many to link here. I've also seen my exact question <a href="http://stackoverflow.com/questions/10235973/modifying-global-variable-with-same-name-as-local-variable">asked about Python</a>. So what I want to know i...
javascript
[3]
5,024,122
5,024,123
How to make a list item full selection when clicked on it?
<p>I have an app in which i should show the list item selection when clicked on it. But when i clicked on it it is showing the selection only on the text but not on the full row? How to do that? </p>
android
[4]
3,350,975
3,350,976
how to deal with multiple ids in query as i have problem in the following code
<pre><code>&lt;head&gt; &lt;script type="text/javascript" src="jquery.js"&gt;&lt;/script&gt; &lt;script type="text/javascript"&gt; $(document).ready(function(){ $("input").click( function(){ alert(this.id); $('#comments'+this.id).show(); } ); }); &lt;/script&gt; &lt;style type="te...
javascript
[3]
3,831,105
3,831,106
Dynamic ListView Columns At Runtime
<p>I want to give users the ability to customize the columns of an asp.net ListView. </p> <p>For example: there are 10 columns of data, a user should be able to select any number of columns to be displayed on their personalized view of a ListView.</p> <p>I have investigated how to accomplish this task and what I hav...
asp.net
[9]
2,392,057
2,392,058
PHP How to find if 2 dates are equal
<p>I have a date field that submits the chosen dates and I want to find out if the end date is today.</p> <p>So for example I want to compare 21-May-2012(today) to 21-May-2012(submitted) and see if they match or not.</p> <p>Can someone please help?</p> <p>Thanks in advance</p>
php
[2]