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 |
|---|---|---|---|---|---|
1,565,453 | 1,565,454 | Java - Storing a "score" from play to play | <p>I wish to be able to keep a score that a player gets when playing my game from game to game and to when they close the game and re-open the scores are still saved. The only way I can think of is to do so using a text file, like I would of done in VB6. However, that then means that they can edit the text file? Or not... | java | [1] |
1,431,222 | 1,431,223 | do message queues provide transactional support? | <p>Say I load messages in a queue from multiple nodes.</p>
<p>Then, one or many nodes are pulling messages from the queue.</p>
<p>Is it possible (or is this normal usage?) that the queue guarantees to not hand out a message to more than one server/node?</p>
<p>And does that server/node have to tell the queue it has ... | java | [1] |
5,095,228 | 5,095,229 | To get the position number of selected text in the text view | <p>I am trying to highlight the selected text and find the position of selected text in the text view.</p>
<p>for example :</p>
<blockquote>
<p>It is stackOverFlow .Stackoverflow is very useful.</p>
</blockquote>
<p>Now when user Select <strong>stackoverflow</strong> then the back ground color should change and gi... | iphone | [8] |
3,923,071 | 3,923,072 | function not working properly in chrome | <p>Hi I have a function that's working correcty in Firefox, but failing in chrome. It's supposed to open a test window, and <strong>IF</strong> successful, close the test and redirect the parent. I'm still getting into java. I understand there are differences in how browsers interpret JS, just not sure why in this inst... | javascript | [3] |
694,471 | 694,472 | How to specify string padding with a variable in Python 2.5? | <p>For example:</p>
<pre><code>print('items %05d'%12)
</code></pre>
<p>would print 00012.</p>
<p>Can the amount of padding be specified by a variable instead of a literal? I believe python 2.6+ has the .format function but what are the options with python 2.5?</p>
| python | [7] |
4,169,298 | 4,169,299 | How can I tell if a listener is already running? | <p>I am adding a event listener to my Singleton class. I am adding the listener in a add method.</p>
<pre><code> public void add(TCComponentItemRevision tcRevision, TCComponentDataset selectedDataset) {
String revMasterForm;
tcRevision.getSession().addAIFComponentEventListener(this);
try {
revMasterForm ... | java | [1] |
3,848,786 | 3,848,787 | Are there any thread managers java | <p>I have been making a threadmanager class in java and wanted it so you could input a class and it would run the threadrun method in that class but when I write my code my ide says:cannot find symbol threadrun</p>
<p>Code:</p>
<pre><code>package thenetwork;
/**
*
* @author Jman
*/
public class Threadmanager impl... | java | [1] |
993,838 | 993,839 | calling function inside a another function | <pre><code>S.ui.createpulldown = function() {
function someName(){
}
someName() // gets called
}
someName() // does not get called, when outside because of scope issue.
</code></pre>
<p>I want to call this function outside the <code>s.ui.createpulldown</code> function. Is it possible, on what changes i h... | javascript | [3] |
1,169,576 | 1,169,577 | How do we call a super class method if we already have a super class of sub class? | <p>My Question is like that if there is a child class extend by father class and which is extended by Grandfather class then how can child class directly access the Grandfather's method.</p>
| java | [1] |
5,315,732 | 5,315,733 | Why would a language let programmer to handle divison by zero | <p>This happens in Javascript, for example, that division by zero is not handled by the language itself.
Is there's a valid reason for this?</p>
<p>I see this as a very basic exception that a language should be able to handle (they even handle 0/0 as NaN NaN).</p>
<blockquote>
<p>or take the square root of a negat... | javascript | [3] |
2,355,089 | 2,355,090 | Generate a radio button in JQUery | <pre><code> <li><a href="#" id="radio">Multiple Choices</a></li>
</code></pre>
<p>onclick of this radio i am trying to generate a radio button with two choices .. How to do so in JQUery??</p>
| jquery | [5] |
5,711,062 | 5,711,063 | Joining values in an arraylist | <p>Say I have an arraylist a with the values:</p>
<pre><code>a[0] = G
a[1] = B
a[2] = D
</code></pre>
<p>I was wondering, how can I create a new arraylist in java, that joins index values at random places and puts it into a new arraylist b
So like:</p>
<pre><code>b[0] = GB
b[1] = D
</code></pre>
<p>or</p>
<pre><c... | java | [1] |
1,784,345 | 1,784,346 | jc1: Cannot allocate 1342179073 bytes after allocating 185472 bytes | <p>I compiled Test.java use gcj:gcj -C Test.java</p>
<p>and it return the error: jc1: Cannot allocate 1342179073 bytes after allocating 185472 bytes</p>
<p>this is the source Test.java:</p>
<pre><code>public class Test {
}
</code></pre>
<p>my gcj version: gcj --version</p>
<p>gcj (GCC) 3.2.2 20030222 (Red Hat Linu... | java | [1] |
5,178,422 | 5,178,423 | asp.net response.redirect avoid validation | <p>I have an ASP.NET form which has many requiredfield validators. Now under some consditions , I have to choose response.redirect to go to another form (this happens when a menu item is chosen under some complex conditions). In this case the navigation fails because of Requiredfield validators on the current form.</p>... | asp.net | [9] |
76,955 | 76,956 | Navigation Bar, Relative Links | <p>i'm building a php cms style app for tracking of members characters, the projects coming along nicely, but I am wondering if there is a more efficient way of coding my navigation bar.</p>
<p>the bar is included in many different pages so relative links as standard will not work for obvious reasons, the way I have b... | php | [2] |
5,494,993 | 5,494,994 | Need Help in Changing Screen Orientation in Android | <p>I want to change the screen orientation from portrait to landscape and vice versa when the user rotates his Android mobile phone clockwise/anticlockwise. Can anyone help me how to achieve this? I do not know what event is fired when the user rotates his Android mobile phone.</p>
<p>For instance, when the user touch... | android | [4] |
667,564 | 667,565 | datagrid speed issue | <p>i m binding gridview in asp.net application...
i m about to bind some thousand records in datagrid...
on RowDataBound event of the grid i need to check if the log in user is authorised to view the perticuler record...so i need to send database request...like wise such other two to three operation requires to send re... | asp.net | [9] |
4,689,152 | 4,689,153 | How to get data out of a deferred callback; | <p>How do I get the returned data to work outside the deferred callback below?</p>
<pre><code> results.done(function(data)
{
alert(data); // works
});
alert(data); // does not work but need it to work...
</code></pre>
| jquery | [5] |
2,900,170 | 2,900,171 | fire an event after document is rendered | <p>How to fire an event or call a method after the document body is fully rendered in jQuery</p>
| jquery | [5] |
774,717 | 774,718 | Send Key Strokes to Games | <p>I can send any windows application key strokes with PostMessage() api.But i cant send key strokes to Game window by using PostMessage.</p>
<p>Anyone know anything about using Direct Input functions for sending keys to games from C#.</p>
| c# | [0] |
4,354,218 | 4,354,219 | Check existance of a file to unlock app | <p>I wish to create a file on my device somewhere (I don't mind where or what the file contains, my only concern is the name of the file), then have my app look for the existence of that file. The idea is to have a mechanism to secretly unlock some features of my app to anyone I tell about the file.</p>
<p>My only pro... | android | [4] |
3,937,646 | 3,937,647 | Changing Background Image with set Interval | <p>I've got the following function which changes that background image of 4 classes so one background goes green and then another making a loading bar:</p>
<pre><code>clearInterval(start);
var i = 0;
function boxes() {
in_loading = ".in_loading:eq(" + i + ")";
$(".in_loading").css("background", "url(images/... | jquery | [5] |
976,293 | 976,294 | android mirroring (wireless display mirroring) | <p>I want to display my content on the both devices (ex mobile , others) through wireless display mirroring (mircast). My Question is here how can be implement this concept using miracast . which has been launched by google in android jelly beans 4.2 . Please give me any idea or suggestion.</p>
<p>Thanks in advance <... | android | [4] |
2,334,926 | 2,334,927 | $.fn or Function.prototype | <p>I'm trying to get this to work. </p>
<pre><code>$.fn.createDelegate = function(scope){
var fn = this;
return function() {
return fn.apply(scope, arguments);
}
}
</code></pre>
<p>The below version works but I thought they were both the same. The first being a shorthand way of writing the second.
Or ma... | jquery | [5] |
1,077,156 | 1,077,157 | NoClassDefFoundError trying to use OpenCyc, what could be wrong? | <p>I want to create cycAccess object to connect to the openCyc knowledge base, but I could not create this object. I got NoClassDefFoundError from this code... Plz anybody can help me ? Following is my code....</p>
<pre><code>public static void exampleConnectingToCyc() {
System.out.println("Starting Cyc connection ... | java | [1] |
2,742,898 | 2,742,899 | camera in android | <p>how can i simulate camera of an android device?And what is the format of image obtained?
thanks in advance..</p>
| android | [4] |
2,169,628 | 2,169,629 | Suspend layout during DOM interaction | <p>In Javascript I'm clearing out the contents of a DIV and then re-populating it, is there any way to suspend layout of these elements or lock the UI until I've finished slashing away at the HTML? I don't want any messages popping up, I just don't want to see the flicker as the items are removed/added.</p>
<p>Thanks
... | javascript | [3] |
2,789,270 | 2,789,271 | Android App- Using a loop for setText procedure to populate EditText | <p>Trying to use a loop to set the text of 12 checkboxes from a db query. Would like to substitute "add1" with an array value and loop through all 12 instead of spelling out each one. Any ideas of how to do this?</p>
<p>Here is the code I am trying to modify:</p>
<pre><code>add1Text= (CheckBox) findViewById(R.id.a... | android | [4] |
4,920,123 | 4,920,124 | Difference in results returned between .has() and :has() | <p>I have a gnarly navigation structure that can be generalized as:</p>
<pre><code><ul id="navigation">
<li>
A
<ul>
<li>
B
<ul>
<li>C</li>
</ul>
</li>
... | jquery | [5] |
2,449,492 | 2,449,493 | iPhone SDK - How to play a video with transparency? | <p>I recorded a video with a bluescreen. We have the software to convert that video to a transparent background. What's the best way to play this video overlaid on a custom UIView? Anytime I've seen videos on the iPhone it always launches that player interface. Any way to avoid this?</p>
<p>Thanks!</p>
| iphone | [8] |
2,330,256 | 2,330,257 | how to play only one sound at a time with AVAudioplayer | <p>i am playing sound when user tap on the respected button.</p>
<p>i have 10 buttons with 10 audio files.</p>
<p>i am playing the selected sound by using the AVAudioPlayer</p>
<pre><code>AVAudioPlayer *myaudio=[[AVAudioPlayer alloc]initWithContentsOfURL:[NSURL fileURLWithPath:[[NSBundle mainBundle]pathForResource:[... | iphone | [8] |
4,506,749 | 4,506,750 | Anyone can let me know the following syntax in C++? | <p>Why we can access <code>value_type</code> by <code>myType::value_type</code>, any c++ reference talk about it?</p>
<pre><code>class myType{
public:
typedef double value_type; // the type for elements in the array
private:
};
</code></pre>
| c++ | [6] |
791,182 | 791,183 | Predict C++ program running time | <p>How to predict C++ program running time, if program executes different functions (working with database, reading files, parsing xml and others)? How installers do it?</p>
| c++ | [6] |
3,897,293 | 3,897,294 | conversion operator and operator>> | <p>I have a program following:</p>
<pre><code>class INT {
public:
INT(int ii = 0) : i(ii) {}
operator int() { return i; }
private:
int i;
};
int main()
{
INT i;
cin >> i;
}
</code></pre>
<p>the statement <code>cin >> i</code> is compiled error, but I don't know the reason?</p>
<p>In my option,... | c++ | [6] |
5,195,700 | 5,195,701 | Is the method WifiManager.setWifiEnabled synchronous? | <p>I had to do something. Just when Wi-Fi was enabled, so I called method <code>WifiManager.setWifiEnabled()</code>, when the method returns, does Wi-Fi state change at the same time?
If not, how can I trace the change of Wi-Fi state? </p>
| android | [4] |
5,675,636 | 5,675,637 | How to use single quote inside an echo which is using single quote | <p>First of all, i have gone through the related questions.. haven't found any answer..
I m using this code to display a message</p>
<p><code>echo 'Here goes your message with an apostrophe S like thi's ';</code></p>
<p>How can i make this work, as any quote inside this echo will break the statement...</p>
| php | [2] |
2,903,291 | 2,903,292 | PHP StdErr after Exec() | <p>In PHP i am executing a command with exec(), and it returns if successful an URL;</p>
<p>$url = exec('report');</p>
<p>However, I want to check STD_ERR, if something went wrong. How would I read the stream?
I want to use php://stderr, but not sure how to use it.</p>
<p>Thanks,
Martin</p>
| php | [2] |
3,812,369 | 3,812,370 | ASP .NET expressions (inline tag) with String.Format | <p>I was juste wondering if it was possible to use <code>String.Format</code> with the following inline tag :</p>
<pre><code><asp:RequiredFieldValidator ControlToValidate="tbTest" Text="<%$ Resources:ErrorMsg, E3032 %>" runat="server" />
</code></pre>
<p>like this so</p>
<pre><code><asp:RequiredField... | asp.net | [9] |
4,656,685 | 4,656,686 | jQuery: Can we use it to serialize a form that returns JSON? | <p>Can I easily use jQuery or a plugin of jQuery that serializes the data in a form as a JSON instead of a <em>"text string in standard URL-encoded notation"</em></p>
<p>ref: <a href="http://api.jquery.com/serialize/" rel="nofollow">http://api.jquery.com/serialize/</a></p>
| jquery | [5] |
2,024,610 | 2,024,611 | change labels orientation,programmatically | <p>can we change the orientation of label,programmatically.</p>
<p>i created few labels on landscape mode, but my application works on portrait,
so wen i start my app, the labels still comes according to landscape mode only,</p>
<p>i cant change the orientation of labels through,IB,i hv some restrictions.</p>
<p>so,... | iphone | [8] |
46,178 | 46,179 | Array elements vs properties? | <p>So to follow up a previous question;</p>
<p>Due to the dynamic functionality of using properties and iterating with </p>
<pre><code>for(var key in array)
</code></pre>
<p>I've used this quite a lot in favor of trying to enumerate an array and iterating by numbers.</p>
<p>What are the pro's and cons of just .push... | javascript | [3] |
1,203,834 | 1,203,835 | The computer hangs when debugging an ASP.NET webform | <p>I start learning ASP.NET few days. I don't know why my computer hangs when I debug my very simple application? My computer hangs, not only IDE hangs? Please help me!</p>
| asp.net | [9] |
760,914 | 760,915 | php 5.2.17 source code repository | <p>The php developers do not support anymore php 5.2.17. However, normal apps are using this php instead of the new one, 5.3 branch (Whose idea was drop security support for 5.2.17? ). Normally we compile php from source code. However the official source code is outdated. Is there any public repository out there with b... | php | [2] |
5,295,395 | 5,295,396 | How to get process ID in iPhone or iPad? | <p>i need to to end a process in my iPhone for security issues so i need it's id
How to get process ID in iPhone or iPad ?? in order to end it in Background process</p>
| iphone | [8] |
5,426,905 | 5,426,906 | How to attach a file and send it through any email application like gmail,yahoo,hotmail etc | <p>This is my code..</p>
<pre><code>import java.io.File;
import android.app.Activity;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
public class EMailAc... | android | [4] |
1,915,773 | 1,915,774 | Write a python script that goes through the links on a page recursively | <p>I'm doing a project for my school in which I would like to compare scam mails. I found this website: <a href="http://www.419scam.org/emails/" rel="nofollow">http://www.419scam.org/emails/</a>
Now what I would like to do is to save every scam in apart documents then later on I can analyse them.
Here is my code so far... | python | [7] |
3,221,554 | 3,221,555 | save and load from sdcard shows empty file | <p>I have a layout where I have an Edit Text field where I enter my data.
I have 2 buttons.Save and Plot.</p>
<p>When I press save I want to save the data (in xls format) from edittext field and the current date in sd card.</p>
<p>When I press the plot ,I want to plot them.</p>
<p>To save data:</p>
<pre><code>case ... | android | [4] |
3,562,972 | 3,562,973 | Too many decimals after addition | <p>I would like to add 0.01 to 36.01 and get 36.02 as the result
But below code returns 36.019999999999994.</p>
<pre><code>Double d = 36.01;
d = d + 0.01;
</code></pre>
<p>Could anyone tell me how to get 36.02 as the result ?
Thanks in advance</p>
| c# | [0] |
1,885,114 | 1,885,115 | What is real purpose of isolated storages in .Net? | <p>I have heard of the term isolated storage in .Net. What is it really and how far is that used? Does that storage not visible to user and can be consumed or written to by Assemblies (specific assembly or AppDomain which created it) only?</p>
| c# | [0] |
2,012,932 | 2,012,933 | writing arraylist of objects in file | <p>I want to write arraylist of objects in a file. But only one object in going in file.Atfirst I am fetching all the stored objects and then appending new object after that I write whole arrayList to the file.</p>
<p>Here is my code....</p>
<pre><code>public void write(UserDetail u1) throws FileNotFoundException {
... | java | [1] |
1,537,436 | 1,537,437 | How to remove all the punctuation except whitespaces or numbers in java | <p>How to remove all the punctuation <em>except</em> whitespaces or numbers in Java.</p>
<pre><code>"\\p{Punct}|\\d", "" //THIS WORKS BUT IT REMOVES THE NUMBERS AND I DONT WANT IT TO REMOVE THE NUMBERS...
</code></pre>
<p>I am reading text and I need to remove punctuation.</p>
<pre><code>String[] internal;
char ch =... | java | [1] |
4,005,990 | 4,005,991 | How do I parse out the substrings in python? | <p>I need to parse out the following:</p>
<pre><code>2012
01
02
16
50
00
</code></pre>
<p>out of the string (in this format):</p>
<pre><code>2012-01-02 16:50:00 ABCABCABCABCABCABCABC
</code></pre>
<p>What's a simple command that would accomplish this?</p>
| python | [7] |
2,029,970 | 2,029,971 | Manipulating the "data" from $.ajax success: function(data) { | <p>i have this and a simple question to it.</p>
<pre><code>$.ajax({
type: "POST",
url: "/",
data: $(".form").serialize(),
dataType: "html",
success: function(data) {
$("#id").html(data);
}
});
</code></pre>
<p>Inside "data" is some html I am inserting into the DOM. Thats no problem. But I want t... | jquery | [5] |
4,749,564 | 4,749,565 | Laying out controls on ASP Web Form using markup | <p>![enter image description here][1]I am new to ASP.NET and I am trying to recreate an existing Winform calculator application in ASP.NET. It is basically a bunch of text boxes on two different tab pages. I am having trouble laying out the text box controls on a web page. I have the Telerik UI Controls Library avai... | asp.net | [9] |
497,077 | 497,078 | how to make rest call with key and secret using md5 in android? | <p>I am trying to implement rest call with key and secret using md5. I tried a way but its giving me an error, </p>
<p>{"status":"error","message":"Signature mismatch"}. </p>
<p>Please help me, its very urjent!!</p>
<h1>this is my md5 method,</h1>
<pre><code>private static final String md5(final String parem) {
... | android | [4] |
4,516,050 | 4,516,051 | Back button issues after forwarding intents via share menu | <p>I am working on a login screen for my application. If I open the application, by either running from eclipse or by selecting the application icon installed on the emulator, it will run an AuthUser.class which checks for a valid token on a remote server. If the user is not logged in then the AuthUser.class forwards t... | android | [4] |
4,076,900 | 4,076,901 | Disable globbing in PHP exec() | <p>I have a PHP script which calls another script in order to add IP addresses to a whitelist. I sometimes want to whitelist all addresses, in which case I have it call</p>
<pre><code>exec("otherscript *.*.*.*", output, retval);
</code></pre>
<p>This worked fine, adding the string "*.*.*.*" to the whitelist until I h... | php | [2] |
3,321,140 | 3,321,141 | How can I load new content without reloading the page based on hashtags fragments? | <p>Imagine I'm on:</p>
<p><a href="http://example.com/" rel="nofollow">http://example.com/</a></p>
<p>I click in a link containing a hashbang <a href="http://en.wikipedia.org/wiki/Fragment_identifier" rel="nofollow">fragment identifier</a>, let's say:</p>
<p><a href="http://example.com/#!/login" rel="nofollow">http:... | javascript | [3] |
2,359,678 | 2,359,679 | how to close all the opened windows(except the parent)onclick from a parent window in javascript? | <p>I have a parent window which calls for a function that opens 2 new windows in javascript.
When I click a close button, I want to close both the child windows.
I tried window.close(windowname); windowName.close(). Both didn't work.</p>
<p>Please help..</p>
| javascript | [3] |
4,455,927 | 4,455,928 | Action bar on pre-honey comb devices by using Android support-v4 library | <p>I want to design Action bar UI on pre-honeycomb devices. After my Google i got ActionBarSherlock library. Can i design without using this ActionbarSherlock library. is it possible to design Action bar on pre-honey comb devices by using Android support-v4 library itself?</p>
<p>Basically i trying to design without u... | android | [4] |
902,755 | 902,756 | check box not working | <p>I need your assistance in my following scenario.</p>
<p>I have three checkboxes A, B and C and variables a. If I click on Checkbox B, the value of a should be kept 2 and if I check A then this should be changed to 3 and if I deselect it should go back to 2.</p>
<p>How to obtain this dynamically?</p>
<p>I am using... | android | [4] |
2,633,159 | 2,633,160 | javascript server issue | <p>Onchage of selection i am calling a javascript to make a server call using struts1.2 but its not making a call.Please let me know where i am going wrong,below is the code</p>
<pre><code><html:form action="/populate">
<html:select property="tName" onchange="test()">">
<html:option v... | javascript | [3] |
3,757,026 | 3,757,027 | which is the best datepicker for birth date? | <p>Which is the easiest to use/select date of birth?</p>
| javascript | [3] |
1,038,579 | 1,038,580 | g++ cannot find header file | <p>I am migrating from Java to C++. It seems that C++ makes classes declaration in separate files, difficult. So I need your help,</p>
<p>in my main.cpp:</p>
<pre><code>#include "Sphere.h"
using namespace std;
.....
...
..
int main( void ) {
Sphere *earth = new Sphere(sphere_start ,sphere_end);
...
..
.
</code><... | c++ | [6] |
5,840,715 | 5,840,716 | Check boolean from another php script | <p>I want to check if a boolean is true or false from antoher phpscript.
Like if I have a boolean like this in one php script:</p>
<pre><code>$signedin = false;
</code></pre>
<p>then I want to check if it is false or true by another php script in another file.
I hope someone can help me! :)</p>
<p>Thanks!</p>
| php | [2] |
4,575,322 | 4,575,323 | android how to moving many image on my destination point | <p>how to implement my idea with android source code</p>
<p>i have many image, i want to move image one by one, if image move on destination point, then other image moving on behind image previous.</p>
<p>ilustration</p>
<pre><code>"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
image1,im... | android | [4] |
6,029,969 | 6,029,970 | Starting an ACTION_VIEW activity to open the browser, how do I return to my app? | <p>In my app i need to open the bank's page, to make the user able to pay.
Reading the Android documentation I see that I should use an <code>ACTION_VIEW</code> (and not a WebView) to accomplish this.</p>
<pre><code> Uri uri = Uri.parse("http://www.example.com");
Intent intent = new Intent(Intent.ACTION_VIEW, uri);
... | android | [4] |
3,604,636 | 3,604,637 | Call to new HttpRequest fails | <p>I am trying to get a php script working. The purpose of the script is to call out to a web service. I've reduced the script down to it's simpliest components and it is still failing. Here it is:</p>
<pre><code><?php
print "Hello";
$request = new HttpRequest('http://www.pivotaltracker.com/services/v3/source_commi... | php | [2] |
472,375 | 472,376 | jQuery Novice: how to remove certain child elements | <p>I need to remove the 2nd and 3rd <code><br></code> elements in the parent <code><address></code> element such that the <code>City</code> and <code>StateCode</code> are on the same line. Here is the exact code:</p>
<pre><code><address>
<label>3651 Stardust Drive</label>
<br&g... | jquery | [5] |
2,731,829 | 2,731,830 | android gallery layout | <p>What type of layout i should use?</p>
<p>What layout elements I need?</p>
<pre><code>__________________________________________________
|list_item | |
|list_item | |
|list_item | |
|list_item ... | android | [4] |
2,354,844 | 2,354,845 | how to use javascript change the form action | <pre><code><div class="fr_search"
<form action="/" accept-charset="UTF-8" method="post" id="search-theme-form">
.......
</form>
</div>
</code></pre>
<p>now i want to write a function to change the form action and method, when it equal a condition. how to write the code. thank you. eg: <... | javascript | [3] |
5,559,371 | 5,559,372 | String comparison; finding 'like' characters | <p>I am doing a quick duplicate check on a form. When comparing two strings, I was trying something like this:</p>
<pre><code>if (stripos($_SESSION['website'], $f['website']))
</code></pre>
<p>I am getting this error:</p>
<pre><code>Fatal error: Call to undefined function: stripos() in...
</code></pre>
<p>I do not ... | php | [2] |
1,204,006 | 1,204,007 | How to create Cash Register Effect using Pure Javascript? | <p>I wanted to create a Cash Register Effect using Pure Javascript(With out using any libraries),</p>
<p>Here is the link for Cash register Effect which is implemented Using Mootools,</p>
<p><a href="http://jsbin.com/ehuzes/edit#preview" rel="nofollow">http://jsbin.com/ehuzes/edit#preview</a></p>
<p>I want to get th... | javascript | [3] |
440,551 | 440,552 | Is it possible for a service to simulate power button? | <p>I'm writing a service on android and I need to turn off the screen after a certain time, I tried using all solutions on this thread <a href="http://stackoverflow.com/questions/6756768/turn-off-screen-on-android">enter link description here</a></p>
<p>but none of them worked, thus is there any way i can simulate the... | android | [4] |
2,954,671 | 2,954,672 | how to print this result using PHP | <p>How to print this result using this code i didn't recognize myself what am i doing wrong can you please help me out </p>
<pre><code><?php
$brush_price = 5;
echo "<table border=\"1\" align=\"center\">";
echo "<tr><th>Quantity</th>";
echo "<th>Price</th></tr>";
for ( $cou... | php | [2] |
5,204,358 | 5,204,359 | PHP how to maintain/update querystring across all links in page | <p>I have a custom e-shop script written in PHP/MySQL.
On the product pages there is a form using GET with a series of form elements (drop downs, check boxes, sliders etc) who's values are used to construct the final MySQL query for pulling the right products based on the users selections. To construct my query, I go ... | php | [2] |
2,920,511 | 2,920,512 | Project has no default.properties file! | <p>I downloaded a sample project from a website. when i import this project to eclipse work space. Im getting this error</p>
<p><strong>Project has no default.properties file! Edit the project properties to set one.</strong></p>
<p>How i can get rid of this problem. Please let me know</p>
<p>Thanks</p>
| android | [4] |
5,238,911 | 5,238,912 | jQuery - Access form items through function | <p>I found on some examples on the web that people were passing the form to a function and then they were only using the id of the item to access it like in :</p>
<pre><code><form id="frm">
<input type="text" id="textbox" name="textbox" value="some value" />
</form>
<script>
console.log(getele... | jquery | [5] |
4,625,157 | 4,625,158 | Is there a way to download the android 2.3.3_r1 platform source code without repo/git | <p>I'm trying to build the source and flash a phone.
The instructions given in source.android are specific to repo/git and it gives me a error saying Connection refused</p>
| android | [4] |
4,297,824 | 4,297,825 | How to launch MpMediaPlayer through HTML5 | <p>Please guide me how to launch MPMediaPlayer through HTML5. I am new to IOS and html.</p>
| iphone | [8] |
1,642,957 | 1,642,958 | how to display toast when email or mms is received to the other person | <p>I am sending emails and mms in my project. I want to show a tost when email or mms is received to the recipient. I am using built-in email and messaging application. I don't know how to implement this please help.</p>
<p>thanx</p>
| android | [4] |
2,456,329 | 2,456,330 | java-Passing argument into main method | <p>i can't pass the name of files as argument to the main method. here is my code...</p>
<pre><code>import java.io.*;
class four {
public static void main(String args[])throws IOException{
int i;
FileInputStream fin = null;
try{
fin = new FileInputStream(args[0]);
}catch(FileNotFoundExceptio... | java | [1] |
2,278,641 | 2,278,642 | How do I get a user control to be closed when I close a specific form? | <p>When I open from the main screen of the application a child form I also display a user control that should be displayed until the child form is closed or the user closes it. If I set the child form to be usercontrol's parent, the user control is not displayed (so the parent of the user control is the desktop). I use... | c# | [0] |
3,202,851 | 3,202,852 | Creating paragraphs in UITextview | <p>Is it possible to split the text into paragraph in a UITextView?</p>
| iphone | [8] |
4,816,368 | 4,816,369 | WorkflowApplication generate unhandle exception in ASP.NET | <p>am using simple persistence workflow application in ASP.NET when i try start workflow using
WorkflowApplication invoker the .NET framework generate unhandled exception.</p>
<p>the exception is:</p>
<pre><code>Type 'VacationRequestWorkflow.VacationRequestModel' in Assembly 'VacationRequestWorkflow, Version=1.0.0.0... | asp.net | [9] |
1,068,434 | 1,068,435 | how to get the height and width of the browser viewport without scrollbars using jquery? | <p>how to get the height and width of the browser viewport without scrollbars using jquery?</p>
<p>Here what I tried so far:</p>
<pre><code> var viewportWidth = $("body").innerWidth();
var viewportHeight = $("body").innerHeight();
</code></pre>
<p>THis solution does not take account for the browser scro... | jquery | [5] |
398,490 | 398,491 | FormView + FileUpload - can I change a bound field based on the fileupload? | <p>I have a FormView control in an ASP.NET 2.0 app. I've got the database storing a filename (a person's picture) in a column. I can't bind the value of the column to a fileupload control - so I'm trying to use a hidden form field. Here's what I have:</p>
<pre><code><asp:HiddenField ID="pictureLink" runat="serve... | asp.net | [9] |
172,438 | 172,439 | app for android! | <p>i am final year student of a university, want to make some application on android, basically i am not sure which application should i go for, since its going to be a FINAL YEAR PROJECT!!,
... app should be good, and long lasting, and have some beneficial for humans. plz reply. </p>
| android | [4] |
4,334,803 | 4,334,804 | Error C2146: syntax error : missing ';' before identifier | <p>The line in question is:</p>
<blockquote>
<p>extern BOOL logged_in;</p>
</blockquote>
<p>Here are my includes:</p>
<pre><code>#define _WIN32_WINNT 0x0403 // Very important for critical sections.
#define WIN32_LEAN_AND_MEAN // Good to use.
#pragma optimize("gsy", on) ... | c++ | [6] |
2,565,263 | 2,565,264 | Is it possible to specify that jquery only searches within a particular div on the page? | <p><strong>In the selector syntax of jqeury $('.string') is it possible to specify that the search is performed only within a particular div or element on the page?</strong> I ask because I am using a web application framework which has a bug, namley producing container elements with the same id so when i search by id ... | jquery | [5] |
1,888,522 | 1,888,523 | What kind of grammar it is in Android? | <pre><code>Dialog dialog = new AlertDialog.Builder(Activity01.this)
.setTitle("Login hint")
.setMessage("Here needs your login!")
.setPositiveButton(...)
.setNeutralButton(...
).create();
</code></pre>
<p>What kind of grammar it is? I cann... | android | [4] |
2,291,909 | 2,291,910 | Read until condition is met and read next line storing it as an array | <p>I currently have a conf file which exists out of the following format:</p>
<pre><code>[client]
person1,person2,person3,person4
[employee]
emp1,emp2,emp3,mp4
</code></pre>
<p>And so on. Now I need to read the file to store the data that comes after the line [employee] into and array.</p>
| c# | [0] |
3,977,824 | 3,977,825 | int.Parse, Input string was not in a correct format | <p>How would I parse an empty string? <code>int.Parse(Textbox1.text)</code> gives me an error: </p>
<blockquote>
<p>Input string was not in a correct format.<br>
System.FormatException: Input string was not in a correct format.</p>
</blockquote>
<p>If the text is empty (<code>Textbox1.text = ''</code>), it throws... | c# | [0] |
1,058,628 | 1,058,629 | Easy jQuery Question - Selecing a div with the same class as the a | <p>I want to do this, but haven't figured it quite out yet...</p>
<pre><code> $(document).ready(function() {
$("a.whateverclass").click(function() {
$("div.whateverclass").show();
return false;
});
</code></pre>
<p>Basically when a link with a certain class is clicked all di... | jquery | [5] |
1,778,680 | 1,778,681 | Java: What is "for (;;)" | <p>Would any one please explain this instruction for me:
for (;;)</p>
<p>I have encountered several kinds of these mark (like in ajax code of facebook and in concurrent stuff of Java).</p>
| java | [1] |
4,029,212 | 4,029,213 | Globals and singletons in Python | <p>I have some few classes which are widespread in my Python application and which should have only one global instance (eg Logger, DbConnection). Python does not support static variables/methods in a class, so the usual Java/C++ way to create a singleton here does not work. I have looked for alternatives to implement ... | python | [7] |
3,912,735 | 3,912,736 | How do I display a decimal to a max of two zeroes after the point | <p>for example.</p>
<p>If I have the decimal</p>
<blockquote>
<p>123.4567</p>
</blockquote>
<p>I want the string</p>
<blockquote>
<p>123.4567</p>
</blockquote>
<p>but if I have the decimal</p>
<blockquote>
<p>123.4000000</p>
</blockquote>
<p>I want the string</p>
<blockquote>
<p>123.40</p>
</blockquote>... | c# | [0] |
2,404,895 | 2,404,896 | Java: Solving sample question for exam | <p>I'm studying for a Java exam and I can't seem to solve this sample question correctly. </p>
<p>Suppose the method int sign(int x) returns 1 if x is positive, -1 if x is negative and 0 if x is 0. Given:</p>
<pre><code>int[] nums = {-2, -1, 0, 1, 2};
</code></pre>
<p>what are the values of the elements of nums afte... | java | [1] |
4,656,628 | 4,656,629 | Why do print_r and var_dump execute before echo | <p>I'm calling either <code>var_dump()</code> or <code>print_r()</code> on an array that has one value in an <code>echo</code> statement:</p>
<pre><code>echo "<br><br>testArray is ==> " . var_dump($testArray) . " <===<br><br>";
</code></pre>
<p>Here is the actual output in the browser:</... | php | [2] |
2,840,989 | 2,840,990 | What is the size of a boolean variable in java? | <p>Can any one tell the bit size of boolean in java?</p>
| java | [1] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.