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,520,333 | 1,520,334 | client side authorization in asp.net web project | <p>i am developing a server-client program in which server will be showing datas sent by client across a network.
without Authentication it works fine but i need some authentication because server side its a website.once i give authentication i am not able to get datas from client.i know that client must be given auth... | asp.net | [9] |
3,204,486 | 3,204,487 | php glob doesn't read vertical images | <p>Would anybody know how to edit the following code to display the vertical images in the directory accurately? The default seems to be horizontal. Thanks very much.</p>
<pre><code><?php
$files = glob("images/*.*");
for ($i=0; $i<count($files); $i++)
{
$num = $files[$i];
echo '<img src="'.$num.'" alt="">'... | php | [2] |
1,889,161 | 1,889,162 | Php code giving no results in firefox? | <p>Just started learning Php on my own, and got stuck at the beginning. This is the code I was compiling: </p>
<pre><code><?php
echo "Hello world!";
echo 6+2;
?>
</code></pre>
<p>The problem is that the Php portion isn't displayed in Firefox. Why? Firefox ver. 7.0.1., I am using NetBeans 7, with cygwin.</p... | php | [2] |
912,850 | 912,851 | How To Get NMEA Sentence of GPRMC in my application? | <p>I am developing a GPS app in that, I used location manager and able get the longitude and Latitude ... But, I need the NMEA 0183 format sentence for sending to the server.. how can I get that sentence help me if any one knows that</p>
<p>Thanks for reading</p>
| android | [4] |
3,199,442 | 3,199,443 | Handlers and Threads in Android | <p>I am trying to understand how background threads work. i am calling a background thread from my activity and i implement my thread handler in this activity as well. Lets say the user goes to activity b while my background thread is running. what happens when my background thread finishes its operation will i have to... | android | [4] |
4,877,150 | 4,877,151 | Getting last of LinkedHashSet | <p>I'd like to store a list of numbers 1,2,3,4 - (lets start with <code>List<Integer></code>)</p>
<p>I'd like to make sure numbers are unique (ok, fine, <code>Set<Integer></code>)</p>
<p>I'd like to guarantee order (ok ... <code>LinkedHashSet<Integer></code>) </p>
<p>I'd like to get the last elem... | java | [1] |
5,690,712 | 5,690,713 | Game Programming Library C++ | <p>Which is the best available, free, easy-to-learn game programming library for C++?</p>
| c++ | [6] |
3,301,664 | 3,301,665 | pixel to percantage | <pre><code>drop: function( event, ui)
{
draggableDocumentOffset = ui.helper.offset(),
droppableDocumentOffset = $(this).offset(),
left = draggableDocumentOffset.left - droppableDocumentOffset.left,
top = draggableDocumentOffset.top - droppableDocumentOffset.top;... | jquery | [5] |
3,381,813 | 3,381,814 | How to make this text rotator to be read sequentially and repeat | <p>This is a script that functions randomize.</p>
<pre><code>function rotateEvery(sec) {
var Quotation=new Array()
Quotation[0] = 'Example 1..';
Quotation[1] = 'Example 2..';
Quotation[2] = 'Example 3..';
Quotation[3] = 'Example 4..';
Quotation[4] = 'Example 5..';
var which = Math.round(Math.random()*(Quotation.... | javascript | [3] |
806,899 | 806,900 | I have an array contains string values, in that same name i have image in drawable.so i want to add in integer array how to do that? | <p>I have an array contains string values, in that same name i have image in drawable.so i want to add in integer array how to do that? ex string newarray[]={"jj","kk","ll"};
i want to access R.drawable.jj ,R.drwable.kk,R.drawable.ll</p>
| android | [4] |
2,767,903 | 2,767,904 | Representing players with 1..N coords in Java | <p>my question is how would you do it to make a code as,</p>
<p>i need a list with players[unique] and for every player i got these coords [x, z]</p>
<p>but for every player there can be more than 1 coordinates[x,z]</p>
<p>i need to save it easly and i have to check the coords of the players every time they trigger ... | java | [1] |
4,628,302 | 4,628,303 | Simulate ASP.NET Page lifecycle | <p>I have an HttpHandler in which I want to render the HTML for some custom controls.</p>
<p>Currently my code looks like this:</p>
<pre><code>Page p = new Page();
var customControl = new CustomControl { Data = data, Blah = blah };
p.Controls.Add(customControl );
context.Response.Write(customControl.RenderToString())... | asp.net | [9] |
3,494,357 | 3,494,358 | A python module for global parameters - is this good practice? | <p>I'm a mechanical engineering student, and I'm building a physical simulation using PyODE.</p>
<p>instead of running everything from one file, I wanted to organize stuff in modules so I had:</p>
<ul>
<li>main.py</li>
<li>callback.py</li>
<li>helper.py</li>
</ul>
<p>I ran into problems when I realized that helper.p... | python | [7] |
597,568 | 597,569 | Most efficient way to check that string variable is a single alphanumeric character | <p>I could do it with regex (something like <code>myString.match(/^[A-Za-z0-9]$/)</code>) but it seems like an overkill. </p>
<p>What would be more effective performance-wise?</p>
<p>Thanks.</p>
| javascript | [3] |
1,533,568 | 1,533,569 | How to crop an image in android? | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/3725501/how-to-crop-the-parsed-image-in-android">How to crop the parsed image in android?</a> </p>
</blockquote>
<p>I am in a serious problem
I have an image in my res/drawable folder.
I want to crop the image w... | android | [4] |
1,944,944 | 1,944,945 | setTimeout in a for-loop and pass i as value | <p>I have this script:</p>
<pre><code>for(var i=1; i<=2; i++){
setTimeout(function() { alert(i) }, 100);
}
</code></pre>
<p>But the alert message is just <strong>two times '3'</strong> (i seems to be a reference). <strong>I want the alert to be 1 and 2...</strong></p>
<p>Is there a way to pass the i, without ... | javascript | [3] |
5,301,148 | 5,301,149 | why constructors aren't explicit by default? | <p>It's so easy to forget to mark a constructor "explicit": adding/removing args, making them optional etc. the single reliable way I know is to declare every constructor as explicit and then remove this keyword only if implicitness is required by design (thanks to the standard that allows this not only on single-argum... | c++ | [6] |
5,217,385 | 5,217,386 | How to Make Custom Software in Java | <p>Im no expert in Java and after learning from Oracle's book and twinkering around with Swing a little bit I wonder how are applications like Lotus Notes, Microsoft Office, Photoshop made?
Id like to create my own GUIs in Java for real-world applications and it seems that all that is available is the default AWT and S... | java | [1] |
1,244,413 | 1,244,414 | Debug with System.out.print in a loop (Eclipse) | <p>To my surprise in the following program the Eclipse console doesn't print while in the loop.
It prints only: "start: finish".
When I use println instead it does.
Of when I remove the comment it does too.
Surprise: when I copy the lines "start: finish" in the console, the clipboard does contain all printed numbers.
... | java | [1] |
3,435,182 | 3,435,183 | Java Number error | <p>i seen to be having a problem with the line:</p>
<pre><code>int xPos = ((x / maxX) * X_AXIS_LENGTH) + X_AXIS_OFFSET; =
</code></pre>
<p>for testing purposes i have assigned:</p>
<pre><code>int x = 10;
int maxX = 52;
</code></pre>
<p>but when used in this calculation <code>x / maxX</code> gives me <code>0</code> ... | java | [1] |
4,418,630 | 4,418,631 | PHP Count round thousand to a K style count like facebook Share . . . Twitter Button ect | <p>Ok so I am trying to turn my hit counter to round thousands to a single digit too display 3 thousand hits as 3K for example, like the Facebook Share and Twitter Tweet Buttons do. Here is my code. Any idea what I am doing wrong?</p>
<pre><code>$postresultscount = (($resultscount) ? $resultscount->sumCount : 1);
$... | php | [2] |
3,615,782 | 3,615,783 | Form is undefined when passing its ID into a jQuery dialog | <p>I am trying to submit a form which is displayed in a jQuery dialog box. However I am having trouble passing the ID of the form into the dialog window. Here is the output shown by Chrome:</p>
<p><a href="http://i.stack.imgur.com/1EIa1.png" rel="nofollow">http://i.stack.imgur.com/1EIa1.png</a></p>
<p>I know the answ... | jquery | [5] |
3,550,393 | 3,550,394 | Byte Array and Int conversion in Java | <p>I am having some difficulty with these two functions: byteArrayToInt and intToByteArray.</p>
<p>The problem is that if I use one to get to another and that result to get to the former, the results ares different, as you can see from my examples below.</p>
<p>I cannot find the bug in the code. Any ideas are very we... | java | [1] |
5,304,279 | 5,304,280 | how to dial special charaters in Uri method? | <p>Hi I'm making an application to automate/activate call forwarding via sms all are working except of parsing some characters for the call forwarding code..</p>
<p>this is my code to execute the call forwarding code which is documented here: <a href="http://en.wikipedia.org/wiki/Call_forwarding#Keypad_codes" rel="nof... | android | [4] |
3,110,593 | 3,110,594 | How to capitalize the first letter of word in a string using java? | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/1892765/capitalize-first-char-of-each-word-in-a-string-java">Capitalize First Char of Each Word in a String Java</a> </p>
</blockquote>
<p>Example strings</p>
<pre><code>one thousand only
two hundred
twenty
sev... | java | [1] |
2,313,975 | 2,313,976 | Literals and Objects - When to use what? | <p>I wonder when to use literals and when to use objects to create data type values.</p>
<p>Eg.</p>
<p>When do I use these:</p>
<pre><code>/regexp/
"string"
</code></pre>
<p>and when these:</p>
<pre><code>new RegExp("regexp")
new String("string")
</code></pre>
<p>Will these give me the same methods and properties... | javascript | [3] |
32,687 | 32,688 | Javascript to highlight current nav and sub directories | <p>I am using this script to highlight the current navigation link :</p>
<pre><code>function extractPageName(hrefString)
{
var arr = hrefString.split('/');
return (arr.length < 2) ? hrefString : arr[arr.length-2].toLowerCase() + arr[arr.length-1].toLowerCase();
}
function setActiveMenu(arr, crtPage)
{
... | javascript | [3] |
434,925 | 434,926 | How to direct access to the elements of stack in C++? | <p>For some reason, I have to use a stack to achieve some function, but I need to reverse the output stack's elements. So I want to use <code>stack<char,vector<char></code> to achieve direct access, but there may be some error in my suggestion. Can anyone tell me how to efficiently reverse the output stack's e... | c++ | [6] |
2,375,690 | 2,375,691 | Pointer arithmetic and dereferencing | <p>In the following code, can anyone please explain to my what the line in bold is doing.</p>
<pre>
struct southParkRec {
int stan[4];
int *kyle[4];
int **kenny;
string cartman;
};
int main()
{
southParkRec cartoon;
cartoon.stan[1] = 4;
cartoon.kyle[0] = cartoon.stan + 1;
cartoon.kenny... | c++ | [6] |
3,134,294 | 3,134,295 | Python: How to remove string from string | <p>I have this snippet of code that looks like this:</p>
<pre><code>server_directory = "/Users/storm/server"
def get_directory(self, username):
home = server_directory + "/" + username
typic = os.getcwd()
if typic == server_directory:
return "/"
elif typic == home:
return "~"
else:
... | python | [7] |
3,146,898 | 3,146,899 | how to delete all current and previoues messages from specific number | <p>This code only deletes the last message form specific number not all message from specific number what i do so its delete all messages? </p>
<p>If i send 3 messages before running the application then running the application when a new message is received will stop the application. I</p>
<p>f i delete all messages... | android | [4] |
745,446 | 745,447 | A puzzle while learning Templates in C++ | <pre><code>template <class A,class B>
class H {
public:
A a;
B b;
void fac();
};
template <class B,class A>
void H<B,A>::fac() {
}
</code></pre>
<p>What does which follows H exactly mean ?
Since I declared <code>template <class B,class A></code>, <code><B,A></code> seemed to be... | c++ | [6] |
3,965,741 | 3,965,742 | Android new SDK tools (r.14) does not generate AIDL files | <p>My project was running just fine and my AIDL files were generated in the GEN folder.
After i installed the new SDK tools (r.14) the AIDL are not generated anymore.</p>
<p>Any idea why?</p>
<p>P.S. the aidl.exe file exist in the platform-tools directory.</p>
| android | [4] |
3,351,099 | 3,351,100 | "initiating a variable" in Javascript: what does it mean? | <p>I am learning now JS but get so often this concept of "initiating a variable". Could anyone give me a good answer? Cheers</p>
| javascript | [3] |
290,370 | 290,371 | adding delete button to listview in android | <p>i have a list view and i want to mimic the functionality of
UITableViewEditingStyle in iphone .
I want the listview to have a delete button and when the user clicks the deleting button, that particular row should get deleted not only from the database but also from the listview.</p>
<p>I am using ListActivity.</p... | android | [4] |
4,892,568 | 4,892,569 | Is it a good practice to use input parameters inside a method | <p>I need to know if it is a good practice to use same input parameters inside a method without assigning them to the method local variable. Following code blocks may describe the query more clear way.</p>
<p>Option 1: Input parameters use inside the method</p>
<pre><code>public int SumValues(List<int> pLValues... | c# | [0] |
2,488,285 | 2,488,286 | Loading specific ViewControllers on tabBarController | <p>I am having problems loading specific ViewControllers on the tabBarController. This is what my project looks like:</p>
<pre><code>TabAppDelegate.m
--------------------
#import "TabAppDelegate.h"
#import "ViewControllerA.h"
#import "ViewControllerB.h"
//etc #import up to F
- (void)applicationDidFinishLaunching:(U... | iphone | [8] |
5,712,825 | 5,712,826 | Save uploaded image with unique name, create thumbnail and write db only if all goes well | <p>I'm coding a php script to get an uploaded picture, move it in a folder (let's say "/img") renaming it with a unique name, create a thumbnail with the same name in a subfolder ("/img/small"), and insert a record for the picture in my database where the picture's name is the primary key.</p>
<p>Basically I'm obtaini... | php | [2] |
5,626,607 | 5,626,608 | java : get computed values outside loop | <p>I do some calculation inside for loop and when I println values inside the loop, I got the expected values,
now, I need also that these values will be available outside loop and not only get the latest value.</p>
<p>example : </p>
<pre><code>String[][] matrix = { { "1", "2", "3" } };
String[] y= { "TEST" ,"B... | java | [1] |
2,785,698 | 2,785,699 | How to have a variable in a mail line | <p>okay, here is the code</p>
<pre><code>while (!feof($text)) {
$name = fgets($text);
$number = fgets($text);
$carrier = fgets($text);
$date = fgets($text);
$line = fgets($text);
$content = $_POST['message'];
$message .= $content;
$message .= "\n";
$number = $number;
mail... | php | [2] |
4,478,171 | 4,478,172 | Can JavaScript maintain any state after a reload? | <p>Is there a way to have JavaScript hold any variables through a reload?</p>
<p>If the user hits the reload button, is there any state that is kept by JavaScript, once a page is reloaded?</p>
| javascript | [3] |
5,173,115 | 5,173,116 | Problem in Process Run | <p>When I want to create a new process that target my files, It seem that I have problem with new threads ?</p>
<p>Where is my problem ? </p>
<p>When I started My Application with Proces.Run :</p>
<p>Error message is : Controls created on one thread cannot be parented to a control on a different thread .</p>
<p>but... | c# | [0] |
2,659,371 | 2,659,372 | How to get the size of the image selected from gallery in Android? | <p>I am doing a Android project in which, i have to take picture using camera or from gallery. </p>
<p>Normally when we do this, we get the URL of the image and i got it. But let me know is there any way to get the size of the image that we are selecting from that gallery programatically?</p>
<p>Can anyone suggest a ... | android | [4] |
3,128,794 | 3,128,795 | checking the availability of services (HTTP/MYSQL/etc.) | <p>I want to create a script, which will be checking status of HTTP/MySQL/SHH etc. services. Most likely i use fsockopen function, but maybe is different and better function or outside the class.</p>
| php | [2] |
5,089,538 | 5,089,539 | dispaly a listview over other activity | <blockquote>
<p><strong>Possible Duplicates:</strong><br>
<a href="http://stackoverflow.com/questions/4554770/custom-listview-over-an-exsisting-activity">custom listview over an exsisting activity</a><br>
<a href="http://stackoverflow.com/questions/4547511/how-can-i-display-a-listview-on-the-top-of-another-activi... | android | [4] |
4,468,023 | 4,468,024 | How do I profile memory usage in my project | <p>Are there any good, <strong>free</strong> tools to profile memory usage in C# ? </p>
<p>Details:<br>
I have a visualization project that uses quite large collections. I would like to check which parts of this project - on the data-processing side, or on the visualization side - use most of the memory, so I could op... | c# | [0] |
5,116,754 | 5,116,755 | Python: Scanning raw_input | <p>I would like to get multiple commands from raw_input(). I have been using this:</p>
<pre><code>reply = raw_input(">").split(' ')
command = reply[0]
file = reply[1]
</code></pre>
<p>but this seems very hacky to me is there a better way to do this in python?</p>
| python | [7] |
5,374,175 | 5,374,176 | When declaring a variable in javascript, is the default value null? | <p>If I have a declaration as follows:</p>
<pre><code>var j;
</code></pre>
<p>does <code>j==null</code> until I set it equal to something?</p>
| javascript | [3] |
833,534 | 833,535 | Getting a value in a textbox from a dropdown list | <p>I have a textbox named textbox1 and a dropdownlist. Dropdownlist contains the list of branches and i want that when i select a branch from dropdown i want to get the respective branch code to be generated in a textbox from the Database or from c# coding. How will it be possible ?</p>
| c# | [0] |
1,277,763 | 1,277,764 | c++ difference between std::string name and std::string &name | <p>I have a lib.h, lib.cpp and test.cpp. I would like to ask what is better?
lib.h</p>
<pre><code>class c
{
std::string name;
}*cc;
</code></pre>
<p>lib.cpp</p>
<pre><code>{
std::cout << "the name is:" << name << std:: endl;
}
</code></pre>
<p>test.cpp</p>
<pre><code>main()
{
c tst;
... | c++ | [6] |
4,135,975 | 4,135,976 | Adding more labels to a chart's axis | <p>I'm making an ASP.NET where I'm using some charts. Currently one chart shows savings on the Y axis.
The chart is only showing 4 labels on the Y axis, in this case 0, 200, 400 and 600. How do I make so the chart shows more labels on one axis, say I want 0, 100, 200, 300, 400, 500, 600?</p>
| asp.net | [9] |
1,337,240 | 1,337,241 | Create an array in javascript of custom objects | <p>Hi I need some help with javascript. </p>
<pre><code>function PricingData(id,method,freq,service,price) {
this.ID=id;
this.PaymentMethod_ID=method;
this.PaymentFrequency_ID=freq;
this.Service_ID=service;
this.Price=price;
}
</code></pre>
<p>I need... | javascript | [3] |
1,927,793 | 1,927,794 | Where is the hidden storage? | <p>I am little confused over the following situation</p>
<pre><code>const char c = 'C';
char * p = const_cast<char *>(&c);
*p = 'K';
cout << " c = " << c << endl;
cout << " *p = " << *p << endl;
printf("c's address : %u\n", &c);
printf("P is pointing to : %u\n",... | c++ | [6] |
1,970,761 | 1,970,762 | php class access variable | <p>I have the following PHP class:</p>
<pre><code>class connect {
public function __construct() {
$sql = new mysqli(...);
return $sql;
}
</code></pre>
<p>(Of course, this is not the whole code, just to give you the idea.</p>
<p>I then have:</p>
<pre><code>class two {
public function validateInput($input) {
$d... | php | [2] |
3,973,171 | 3,973,172 | How create BookMark Page | <p>Hi every one I have built a poem application for iphone.</p>
<p>Now I want to create a bookmark page for my poems. I import cells list with MyCell.Plist and my poems are HTML files. Now I want to create a bookmark page for favourite poems.<br>
How can I do that? </p>
| iphone | [8] |
3,154,403 | 3,154,404 | Use _tcstoul to detect invalid string during unsigned long conversion - unable to treat -ve string as invalid value | <p>I try to use _tcstoul for string to unsigned long conversion.</p>
<p>However, it doesn't treat -ve string input as invalid input. Is there any workaround for this? Or I had missed out something?</p>
<pre><code>#include <cstdio>
#include <tchar.h>
int main() {
{
unsigned long iResult(0);
... | c++ | [6] |
2,809,464 | 2,809,465 | need to get a GET variable then send it thru ajax jquery | <p>how can you get a GET variable with javascript?
i get it in php from the query string:
$idmessage = $_GET['id']; </p>
<p>then need to send it in $.ajax() jquery, how can i do this?
regards</p>
| jquery | [5] |
1,603,136 | 1,603,137 | why is this for loop taking so long? | <p>the for loop:</p>
<pre><code>//for testing, this is usually a value of about 27
int test = level.PathLookupVectors()[globalNodePositionIndex][globalNodeChoice].size();
for (int i = 0; i < level.PathLookupVectors()[globalNodePositionIndex][globalNodeChoice].size(); i++)
{
//adds the correct nodes to the sear... | c++ | [6] |
3,736,400 | 3,736,401 | Tools to search strings in C# | <p>I'm looking for the SQL equivalent of <code>LIKE '%text to search%'</code> in C#. Really just a small text searching engine I can use to check if a string is a match.</p>
| c# | [0] |
3,081,004 | 3,081,005 | Using createElement to create a new table | <p>Why doesn't the following works? Don't tell me is cos table can't contain in a div...</p>
<pre><code><html>
<head>
<script type="text/javascript">
function addTable() {
var table = document.createElement('table');
table.innerHTML = "<tr><td>123</td><td&... | javascript | [3] |
4,846,566 | 4,846,567 | iPhone UITableView trigger a parent method? | <p>Okay, so I'm working on an iPhone app with a preferences-esque section where there's a base TableView, which has one section, and several rows of customized cells to hold a name and a value label. Clicking on a row brings up another View, which allows the user to pick from a list (another TableView), and select an i... | iphone | [8] |
2,677,034 | 2,677,035 | Referencing a file static variable from an inline function | <p>Say you have a file example.h</p>
<pre><code>class example
{
public:
int doStuff();
};
</code></pre>
<p>and a file example.cpp</p>
<pre><code>#include "example.h"
static const int data[] = {1, 2};
inline int doStuffImpl()
{
return data[0] + data[1];
}
int example::doStuff()
{
return doStuffImpl();
}... | c++ | [6] |
3,486,994 | 3,486,995 | RSA- BIgInteger Issue | <p>I want to use <a href="http://introcs.cs.princeton.edu/java/78crypto/RSA.java.html" rel="nofollow">RSA algorithm</a>, for encrypt and decrypt messages. Now, as RSA can encrypt and decrypt Big-integer (or Integer) value, I need the message as Big-integer value. Now, message can contain strings like "ABC 123". What ca... | java | [1] |
3,819,635 | 3,819,636 | App icon and Default.png is not working properly in 2G iphone? | <p>My app icon of my application is not working in 2g version of the iphone (icon.png). only appear white icon with application name and also problem in default.png. can any one help me</p>
| iphone | [8] |
45,587 | 45,588 | Running Dtrce after i run my process shows it as an invalid Command | <p>I have written a small program and a dtrace script . I have compiled a program as <code>g++ CCtest</code> . The dtrace script name is <code>./CCstack.d</code> . After compilation , I am running the <code>./a.out</code> . and have induced sleep in main function before it starts executing things . Then
on a second c... | c++ | [6] |
2,126,233 | 2,126,234 | C++ reading list (books) to be good a C++ design and implementation | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/388242/the-definitive-c-book-guide-and-list">The Definitive C++ Book Guide and List</a> </p>
</blockquote>
<p>i did a reading list to be good a c++ programmer and designer, they are :</p>
<p>Exceptional C++ Her... | c++ | [6] |
1,701,772 | 1,701,773 | C++ multiple header files and only one main | <p>h files and a main file. How can I include all these files to use in the main file?. I included the first .h just fine and in the second I used static variables so that it could be included in the main but the third one I can't include. How can I include it? I'm using Dev C++.</p>
| c++ | [6] |
3,878,524 | 3,878,525 | Two buttons needed at navigationItem.rightBarButtonItem. Image not getting displayed | <p>I have to have two buttons on the right side of the navigation bar. So i created a tool bar and added two bar button items to its content view. Like below.</p>
<pre><code>UIBarButtonItem *shareButton = [[UIBarButtonItem alloc]
initWithImage:[UIImage imageNamed:@"share-icon-32x32.png"]
style:UIBarB... | iphone | [8] |
4,521,926 | 4,521,927 | jquery check html5 data value | <p>How would I check what value a data attribute has? e.g.</p>
<pre><code><form data-after="closemodal">
<form data-after="refreshmodal">
</code></pre>
<p>I've tried doing it with:</p>
<pre><code>if (form.data('after', 'closemodal'))
{
// close modal
}
else if (form.data('after', 'refreshmodal'))
{
// r... | jquery | [5] |
5,747,987 | 5,747,988 | How to implement ease BounceOut (Elastic) functionality in iPhone | <p>I want to implement a bounce out easing function in my application.</p>
<p>Something similar to elastic out.</p>
<p>Like as in the following link
<a href="http://www.powerping.be/js/jstween/moveSquare.html" rel="nofollow">http://www.powerping.be/js/jstween/moveSquare.html</a></p>
<p>I want to implement something ... | iphone | [8] |
5,214,457 | 5,214,458 | PHP operators for comparing table rows with letters inside? | <p>I have a simple CMS that I have set up.</p>
<p>In the database it has a row for short-story content and a row for full-story content on the same table.</p>
<p>I am trying to write an if else statement that basically shows the full story content if it has more characters or words inside.. or to show the short-story... | php | [2] |
4,409,046 | 4,409,047 | Java : How can I get only update text from text file when it's updated | <p>I have a text file (*.txt) . it's updated frequently. I need only update text from it when it's updated.</p>
| java | [1] |
4,616,784 | 4,616,785 | how many types of parsers are available for android | <p>I have used the SAX parser and the DOM parser. Are there any other parsers that can be used in Android?
PS. I know that these parsers are present in the JDK and have nothing to do with Android, but when I am asking for Android it is implied that I am asking for Java as well.</p>
<p>Thank you in advance.</p>
| android | [4] |
1,832,691 | 1,832,692 | PHP changing output from the database | <p>I'm creating an computer inventory website that is displayed in a table.
I'm trying to change the output display for example the following</p>
<pre><code>echo "<td>".$row['WindowsVersion']."</td>\n";
</code></pre>
<p>displays 5.0 or 5.1 or 5.2 or 6.0 or 6.1</p>
<p>but I want it to display</p>
<pre><c... | php | [2] |
1,431,443 | 1,431,444 | Maintain server after socket killing | <p>So I have this simple server. What I want to do is keep the server running and waiting for another client, when I kill the clients socket (telnet -> end process).</p>
<pre><code>private ServerSocket serv;
public Server() throws IOException {
try {
serv = new ServerSocket(port);
serv.setReuseAd... | java | [1] |
5,026,150 | 5,026,151 | Android exhibition mode --> Detect user inactivity | <p>I will first explain what I'm trying to accomplish. I wanna use some android devices (10-12) as exhibition devices. The will be always on power and my visitors can play with them. When a device is inactive for a while, I wanna pop up a full screen video playing. The video file must be updated once in a while. </p>
... | android | [4] |
4,885,324 | 4,885,325 | what is the difference between ACTION_SENDTO and ACTION_VIEW when sending sms? | <p>I have an application that sends messages to a specified contact. Right now I use</p>
<pre><code>Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("smsto:" + phoneNumber));
</code></pre>
<p>to send messages, and it works great on the emulator and on my N1. I got complaints from users with HTC incredible tha... | android | [4] |
2,148,775 | 2,148,776 | Accessing only part of a dictionary in a for using Python | <p>My example dictionary is this</p>
<pre><code>data_dictionary = {1:'blue',2:'green',3:'red',4:'orange',5:'purple',6:'mauve'}
</code></pre>
<p>The data_dictionary can have more elements depending on the incoming data . The first value is what we call a payload_index. I always get payload_index 1 to 4 .</p>
<p>I ne... | python | [7] |
5,241,681 | 5,241,682 | Disable the onItemclicklistner on OnItemLongClickListner | <p>I want to disable the onItemclicklistner when I Long click.The thing is I am playing the video on onItemclick of grid view.I want to do some other task on onItemLongclick.But when I long press it is playing the video and doing some other task..Here is my code..</p>
<pre><code>gv.setOnItemClickListener(new OnItemCli... | android | [4] |
992,385 | 992,386 | How to record audio/voice in background contineously in android? | <p>As I want to record audio in backgroung i use service..But I am not able to record the audio in service.</p>
<p>I tried same code in Activity it works for me. but how to do audio recording in background when voice /speech is input that means audio recording should start if there is voice input and that should be in... | android | [4] |
1,892,381 | 1,892,382 | Is the first operation supposed to be faster and if so then Why? | <p>Is the first opeartion faster than the second one ?</p>
<pre><code> u+= (u << 3) + (u << 1) //first operation
u+= u*10 //second operation
</code></pre>
<p>Basically both of them does the same thing that is <code>u= u+(10*u)</code>
But i came to knew that first operation is faster than second .
Doe... | c++ | [6] |
3,418,359 | 3,418,360 | How to set the value for an HTML element from external javascript | <p>I'm using an external javascript file (eg:<code>myjs.js</code>) with function <code>setval()</code> to set the <code>innerText</code> property of a HTML lable.</p>
<p>I have PHP page with <code><lable id="abc"></lable></code> and I have included <code>myjs.js</code> in <code><head></code> section.... | javascript | [3] |
5,151,836 | 5,151,837 | Aborting Execution, If Filename is changed | <p>This was A Question Asked by my teacher. "How Would You Stop Your Script From Executing, IF Filenamed is renamed by User."</p>
<p>I had sumthing this idea in my mind.</p>
<pre><code>#consider the name of the script to be myscript.py
import os
signal = 0
while 1:
if "myscript.py" not in os.listdir("."):
... | python | [7] |
5,752,352 | 5,752,353 | Intent and string array | <p>I need pass a string array from AlarmReceiver.class to Notify.class but the string is always "null". Now, is a problem about intent within AlarmReceiver?</p>
<pre><code>public class AlarmReceiver extends BroadcastReceiver {
public void onReceive(Context context, Intent intent) {
[...]
Intent notificationIntent = ne... | android | [4] |
1,214,489 | 1,214,490 | Javascript Namespace Help | <p>I have a pretty big Javascript script with loads of global variables & functions in it. Then a piece of code that calls one function from this js file: myfunc();</p>
<p>Ok, now I have cloned this script and modified some functionality, all function prototypes and variables are named the same in both scripts. So... | javascript | [3] |
4,692,039 | 4,692,040 | How do I exclude elements that have a "target" defined (for opening external links in new windows)? | <p>I'm not sure if this script is working properly. I do not want to overwrite existing targets. How can I adjust this to exclude links that already have a target defined?</p>
<pre><code>$("a[@href^='http://']").not("[@href*='" + window.location.host + "']").attr('target','_blank');
</code></pre>
| jquery | [5] |
2,929,897 | 2,929,898 | How to call overriden methods in all derived classes | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/5644338/how-to-force-child-same-virtual-function-call-its-parent-virtual-function-first">How to force child same virtual function call its parent virtual function first</a> </p>
</blockquote>
<p>I have a class h... | c++ | [6] |
3,548,594 | 3,548,595 | link detection? | <p>I asked a question yesterday about a problem that Im having with a program that Im trying to build <a href="http://stackoverflow.com/questions/6331409/having-problems-passing-array-values">having problems passing array values </a>. </p>
<p>the problem that I am having is that I have an array named $images() that fo... | php | [2] |
831,878 | 831,879 | How can I retrieve a file from my app folder in android? | <p>I want to send the database file of my app via email. This makes my it easier to help in a error case. For that I need to retrieve the installation folder of my app. How can I achieve this so that i can send my db which is place here APP-FOLDER\databases\mydb.db</p>
<p>Thanks</p>
| android | [4] |
5,587,324 | 5,587,325 | How can i take section as a button and clicking that button should display no of rows for that section? | <p>For Ex:I have 5 Section each section should be displayed as Button where it also have button title to display by pressing that button it should display no. of rows for ex: 5 rows. it is different for every section.each functionality should be done by TableView Only so how it's possible?Please guide me on solving thi... | iphone | [8] |
3,097,343 | 3,097,344 | linkShare integration in iPhone | <p>I want to integrate linkShare affiliated link into the my iPhone application. </p>
<p>I have already created the links for the applications which I want to sell from within my application using my linkShare account.</p>
<p>But the only problem is how would I get the logo, name and description of those applications... | iphone | [8] |
1,918,293 | 1,918,294 | How to access the ID of an HTML element | <p>How to get the value from "id" instead of from "value" and show it on the page? Now I have <code>Holzart:3</code>, I want to have <code>Holzart:Lärche</code>.</p>
<p>I have this function:</p>
<pre><code>$(document).ready(function() {
$("input[name='holzart']").click(function() {
PobierzWartosc2();
... | jquery | [5] |
1,662,263 | 1,662,264 | making transperent background | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/54926/make-a-jpanel-not-draw-its-background-transparent">Make a JPanel not draw its background (Transparent)</a> </p>
</blockquote>
<p>i want to make my application background as transperent.how to do this?</p>
| java | [1] |
5,913,278 | 5,913,279 | Jquery add percent sign to input box | <p>I'd like to have an input box that automatically adds a visible percent sign to the user when entering numbers (not just recognizes it as a percent when submitting). Thus, a user hits "2" and sees "2%"</p>
<p>I'm assuming one could use Jquery to do this fairly easily, but I have no idea how! Any ideas?</p>
<p>Than... | jquery | [5] |
3,144,753 | 3,144,754 | How to know which instruction taking the longest time to finish ? (to increase my program performance) | <p>I need to know how can I get every instruction's duration so I can maintain the code to increase the performance of my program .</p>
| c# | [0] |
2,785,180 | 2,785,181 | Is there any reason to put code in the code behind rather than in the aspx file? | <p>Any time I need to write code I almost always put it in the code behind file. For some reason this has always seemed like the "right" way to write code.</p>
<p>Based on most of the examples I see online, a lot of other people choose to write code this way too, but it seems like putting your code in the aspx file a... | asp.net | [9] |
3,058,561 | 3,058,562 | I just started learning the syntax of c++. What now? | <p>I more or less know the syntax of C++, but when I start to write a program, I have nothing to write, I am blank. The thing is I knew the syntax of C as well and I didn't know how to write programs in that either. Though I could understand the written answers of almost anything.</p>
<p>So, my question here is how do... | c++ | [6] |
5,543,308 | 5,543,309 | Fancybox gallery with image map | <p>I am trying to create a fancybox gallery using image maps. The html/iframes open but I can't get the gallery working.</p>
<p>I tried:</p>
<pre><code><area class="fancybox" data-fancybox-group="gallery"
</code></pre>
<p>and also tried:</p>
<pre><code><area class="fancybox" rel="gallery"
</code></pre>
<p>Ho... | jquery | [5] |
2,755,115 | 2,755,116 | How do you create a link from data retrieved from the database | <p>I have products stored in a database. These items have ID, NAME, QUANTITY, and STOCK_NUMBER fields. I want to make an <code>href</code> for all of the data in the database:</p>
<pre><code>$Result=mysql_query("SELECT * FROM Products");
while($row=mysql_fetch_array($Result)){
href .....
}
</code></pre>
<p>I wa... | php | [2] |
4,290,450 | 4,290,451 | Removing a string in javascript | <p>I have a URL say
<a href="http://www.google.com/?v=as12&&src=test&img=test" rel="nofollow">dummy URL</a></p>
<pre><code>http://www.google.com/?v=as12&&src=test&img=test
</code></pre>
<p>Now I want to remove the &src=test& part alone.I know we can use indexof but somehow I could not ... | javascript | [3] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.