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
5,810,586
5,810,587
How to trim document.getElementbyId value in JavaScript?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/196925/what-is-the-best-way-to-trim-in-javascript">What is the best way to trim() in javascript</a> </p> </blockquote> <p>How to trim document.getElementbyId value in JavaScript?</p>
javascript
[3]
2,541,883
2,541,884
Multiple apk based on density
<p>I want to upload 3 apk on android market based on density that is ldpi,mdpi and hdpi.</p> <p>I referred this links <a href="http://developer.android.com/guide/appendix/market-filters.html#MultiApks" rel="nofollow">http://developer.android.com/guide/appendix/market-filters.html#MultiApks</a> <a href="http://develop...
android
[4]
5,499,327
5,499,328
Automatically install/uninstall an application from within another application
<p>I am developing an Android device management service. </p> <p>One of the functions for this is specifying what apps should be installed on registered devices of the service.</p> <p>The scenario is that a manager will upload an enterprise app to the service for use on his employees' Android devices.</p> <p>He then...
android
[4]
2,862,628
2,862,629
Can AtomicInteger replace synchronized?
<p>The javadoc for the java.util.concurrent.atomic package says the following:</p> <blockquote> <p>A small toolkit of classes that support lock-free thread-safe programming on single variables.</p> </blockquote> <p>But I don't see any thread-safe (synchronized or Lock) code inside any of the AtomicInteger or At...
java
[1]
5,078,284
5,078,285
On Tablets, is internal storage the only option to store images?
<p>On Tablets, is internal storage the only option to store images?</p> <p>I'm writing an app that gets data from a web service, the data is Base64 encoded image. I have to save this image on phones &amp; tablets. On a phone I have the option of storing the image on external storage but if the device is a tablet is ...
android
[4]
4,191,698
4,191,699
Balanced Payment integration for iOS
<p>I am trying to do the payment using <a href="https://www.balancedpayments.com/" rel="nofollow">https://www.balancedpayments.com/</a> . They have their iPhone library for this <a href="https://github.com/balanced/balanced-ios" rel="nofollow">https://github.com/balanced/balanced-ios</a> . The problem is that there is ...
iphone
[8]
1,680,669
1,680,670
Declaring variables inside a $.each loop in jQuery
<p>I have a simple jQuery each loop and I wonder if it's possible to declare some variables using it. Something like this:</p> <pre><code>jQuery.each(["var_name1", "var_name2", "var_name3"], function(){ $[this] = this; }); </code></pre> <p>Something like a variable varbiale in php.</p> <p>I know I could store ever...
jquery
[5]
3,131,637
3,131,638
I want to perform in place modification to a std::map while iterating over it
<p>I need to know the best way to do the in place modification to the map without taking a local copy of the values modified and then pushing it again into the original map.</p> <p>I have detailed the snippet below that explains the problem: </p> <pre><code>#include &lt;string&gt; #include &lt;map&gt; struct E...
c++
[6]
4,740,239
4,740,240
class derived from list
<p>I have a C# class derived from a generic list</p> <pre><code>public class CostCodes : List&lt;CostCode&gt; { public CostCodes() : base() { Add(new CostCode { Description = "DOM0010 Fall Arr", ID = 1599 }); Add(new CostCode { Description = "DOM0020 Acoustics", ID = 1600 }); } </code></pr...
c#
[0]
594,159
594,160
Sending emails digitally signed with S/MIME encryption using phpmailer
<p>I need to know that how can I send an email digitally signed with S/MIME encryption using the phpmailer API. I'm able to send normal email. Please provide me with links or examples of how to do it.</p>
php
[2]
4,757,756
4,757,757
C# Process + Backgroundworker & timer error
<p>I have some code that spawns a process, the file being executed is a Java application and my intent is to read the output from it.</p> <p>The problem is that when I call <code>Start</code>, I am unable to read the output stream after that point. If I test and call <code>Console.Beep</code> after calling <code>Start...
c#
[0]
3,980,036
3,980,037
best way to do this string conversion in Python
<p>I need to convert a string to another which has removed anything before the second word</p> <p>Example from this,</p> <pre><code>string = "xyz anything else" string2 = "xyz anything else" string3 = "xyz anything else" </code></pre> <p>to this,</p> <pre><code>string = "anything else" string2 = "anything else"...
python
[7]
2,069,259
2,069,260
How can i control my Google TV emulator with an another emulator devices
<p>I work in ubuntu 12.0.4 LTS, I want to control my Google TV emulator (provided by android sdk 3.1) with another emulator as a remote.</p> <p>I have already tried to import android library into eclipse and androidLibrary.jar within my apps but it didn't work.</p> <p>hopefully that you can help me . </p>
android
[4]
3,728,952
3,728,953
sdk manager update
<p>I have installed eclipse indiego , added ADT plugins from google repository after that I closed the eclipse and restart again. then no wizard appear to ask for installing a sdk , so I manually install the latest from google developer and give the path in windows-->preference ->android</p> <p>I saw there was no plat...
android
[4]
5,185,171
5,185,172
How do I set a dictionary size for Activator.CreateInstance?
<p>I want to set the initial size of a dictionary using Activator.CreateInstance, what is the syntax please?</p> <pre><code>var collection = Activator.CreateInstance(someDictionaryType) as IDictionary; </code></pre>
c#
[0]
3,925,021
3,925,022
WindowManager.LayoutParams.TYPE_SYSTEM_ALERT no longer disables home key on Android 4.1
<p>On android Jelly Bean setting the alert dialog window type to WindowManager.LayoutParams.TYPE_SYSTEM_ALERT no longer disables home key. On ICS settings window type to WindowManager.LayoutParams.TYPE_SYSTEM_ALERT would block all key press. Is there any other way to avoid home key and recent app key from dismissing al...
android
[4]
4,337,862
4,337,863
dynamic button event problem
<p>i have some problem.. i have created a dynamic button in a table view. I want to know the method of opening a new view controller when i click the dynamic button in the table view. </p>
iphone
[8]
967,683
967,684
How to convert a const char * to std::string
<p>What is the correct/best/simplest way to convert a c-style string to a std::string.</p> <p>The conversion should accept a max_length, and terminate the string at the first \0 char, if this occur before max_length charter.</p>
c++
[6]
1,262,027
1,262,028
Why isn't this jQuery script working?
<pre><code>&lt;script type="text/javascript"&gt; $(document).ready(function(){ $("tr.reqDet").hide(); $("[title='requestType']").change(function(){ if ($("[title='requestType']").val()!=""){ $("#reqDet").hide(); } else { $("#reqDet").show(); } }); &lt;/script&gt; </code></pre> ...
jquery
[5]
2,768,046
2,768,047
& symbol not accepting in jquery ajax
<p>Why &amp; symbol not accepting in jquery ajax?</p>
asp.net
[9]
1,190,021
1,190,022
changing visibility of text android
<p>Hi i have two textViews that i initially set its visibility to gone then animate in and become visible. now i want to make the invisible again but for some reason they're still showing on screen does anyone no why?</p> <p>in my onCreate() i make the view gone</p> <pre><code>register = (TextView)findViewById(R.id.r...
android
[4]
5,253,810
5,253,811
How to serialize ArrayList
<p>How can I serialize an ArrayList and Save it in a file?</p>
android
[4]
1,503,500
1,503,501
What does static and IOException mean?
<p>I just had a test on java and we had to give the definition of<br> 1) Static:<br> 2) IOExcepion: </p> <p>What I said for static was...a static method is used to define a method as a class method. And I got it wrong so I asked my teacher and he said he wants the actually definition of static not a static method, cl...
java
[1]
3,372,412
3,372,413
Jquery Image Gallery Next Button
<p>Can't seem to get this jquery gallery working. I've been able to get the .galleryImgs click function working, but cant seem to get the #gallery-next click function to work. It's supposed to get the data-src attribute from the next .galleryImgs div and set it in the .galleryImg src. I've tried using addClass and remo...
jquery
[5]
3,531,749
3,531,750
Timing in javascript vs real time
<p>I have a question: When I do a countdown in JavaScript, and I have a function of the form:</p> <pre><code> &lt;script&gt; var interval; var minutes = 1; var seconds = 5; window.onload = function() { countdown('countdown'); } function countdown(element) { interval = setInterval(function() { v...
javascript
[3]
2,587,801
2,587,802
Detecting when reception returns Android
<p>How do I detect when the reception returns to the phone? is there an intent I can register to get a message when it does? Thanks</p>
android
[4]
4,353,709
4,353,710
Jquery Scrollorama issue
<p>here's my code:</p> <pre><code>&lt;script src="javascripts/jquery.js"&gt;&lt;/script&gt; &lt;script src="javascripts/scrollorama.js"&gt;&lt;/script&gt; &lt;script&gt; $(document).ready(function() { // initialize the plugin, pass in the class selector for the sections of content (blocks) var scrollorama =...
jquery
[5]
1,016,087
1,016,088
how to read blob from sql server using c#?
<p>I have a console application using C# where I want to read the blob stored in SQL Server and write it to windows file system at a specified path.</p> <p>How do I convert a blob to a image of pdf using C# and write it to a file system?</p>
c#
[0]
4,495,326
4,495,327
C# Downcasting Lists to IList "special tactics"
<p>So I'm working at a company and I'm relatively new here but I've come across something very strange in some production code which I'm told are written by someone much more knowledgable in C# than myself who "does things a special way". So I'm trying to think of reasons to do what I'm about to explain, giving the be...
c#
[0]
4,158,283
4,158,284
Why span dissapears on mouseenter?
<pre><code>&lt;DIV id=gallery2&gt; &lt;DIV class=center_content&gt; &lt;A id=example2 class=photo-link title=567 href="http://www.hdwallpapersarena.com/wp-content/uploads/2012/06/Desktop-wallpaper-Free-honey-bee1.jpg" rel=group1 smoothbox?&gt; &lt;IMG id=mygal class=mygalclass src="http://www.hdwallpapersar...
jquery
[5]
189,310
189,311
Can I add folders to Drawables and cycle files in them?
<p>Wanted to ask how I can add my own folders with drawables to resources? And how could I later cycle through all files in a specific folder?</p> <p>Thanks!</p>
android
[4]
254,952
254,953
jQuery check childNode class
<p>I'm trying to figure out how to check the class of a childNode. I currently have a list like this:</p> <pre><code>&lt;li&gt; &lt;a href="#"&gt;Link&lt;/a&gt; &lt;ul class="children"&gt; &lt;li class="current"&gt;&lt;/li&gt; &lt;li&gt;&lt;/li&gt; &lt;li&gt;&lt;/li&gt; &lt;/ul&gt; ...
jquery
[5]
5,350,483
5,350,484
how i can resolve this open cv sample native camera?
<p>I got this error when I run <code>open cv sdk 2.4.2</code> on my devices:</p> <pre><code> 09-19 04:41:27.880: E/dalvikvm(1188): Could not find class 'org.opencv.samples.tutorial2.Sample2NativeCamera$1', referenced from method org.opencv.samples.tutorial2.Sample2NativeCamera.&lt;init&gt; </code></pre> <p>The pr...
android
[4]
4,455,994
4,455,995
Vibrate in dynamic pattern
<p>I'm coming from Actionscript 3 and new to Java. I'm trying to make a vibrate pattern half of which is fixed and half of which is dynamic. For eg:</p> <pre><code>long[] vibratePattern = {100,100,100,100} //fixed pattern if(some_condition) vibratePattern.append(400); if(some_condition) vibratePattern.append(200); if(...
android
[4]
3,772,541
3,772,542
How to get title attribute for each a href and put as span?
<p>Hi I am trying to get the title attribute of each a href in jQuery and put it as a span and have done something like this:</p> <pre><code>$('.menu li').each(function(){ var title = $('.menu li a').attr("title"); $(".menu li a span").text(title); }); </code></pre> <p>Each link has a different title attribut...
jquery
[5]
5,552,445
5,552,446
Python list lookup with partial match
<p>For the following list:</p> <pre><code>test_list = ['one', 'two','threefour'] </code></pre> <p>How would I find out if an item starts with 'three' or ends with 'four' ?</p> <p>For example, instead of testing membership like this:</p> <p><code>two in test_list</code></p> <p>I want to test it like this:</p> <p><...
python
[7]
1,013,847
1,013,848
unclosed string literal error at compile time because it contains double quotes and pre tags of HTML
<p>In my program, there is a string that contains double quotes and less than and greater than symbols. Here is a sample String:</p> <pre><code>String s2="div class=\"codeblock\"&gt;&lt;pre name=\"code\" class=\"java\" "; </code></pre> <p>Can anyone help me?</p>
java
[1]
4,367,147
4,367,148
Add class to an element
<p>I try to write these code to make grid view through CSS:( jsbin )</p> <pre><code> var tables = document.getElementsByClassName('tableData'); var rows = tables[0].getElementsByTagName('tr'); for(var i=1; i&lt;rows.length; i +=2) { alert(rows[i]); rows[i].className = "alt"; } </code></pre> <p>This only wor...
javascript
[3]
3,513,641
3,513,642
Changing directory using php passthru()
<p>I want to change the working directory using passthru() method and commandline ..</p> <p>This is the php script</p> <pre><code>&lt;?php passthru("chdir C:/Documents and Settings/svn"); print passthru("dir"); ?&gt; </code></pre> <p>However, it is not changing the working directory to C:/Documents and Settings/sv...
php
[2]
3,824,199
3,824,200
<asp:File upload control is not visible what ever I do
<p>Some thing weird is happening. I created a simple form and Added an <code>&lt;asp:file upload&gt;</code> control to the page. When I run it, I am not able to see the control at all.</p> <p>When I click on the place where I added it is letting me upload a file. I even added visible="true" still not able to see the ...
asp.net
[9]
5,046,031
5,046,032
Loading random form into jQuery Tools overlay
<p>I asked how to load a random form in another thread and got great answers. Here is what I got and verified to work</p> <pre><code>$(function() { $("a.random")click.(function){ $(".test_form").hide(); var formNumber = Math.floor(Math.random() * 4);//will equal a number between 0 and 3 $("#form" + formNu...
jquery
[5]
3,929,639
3,929,640
Would like to concantenate list of fields one of which is a URL link
<pre><code>$list[] = '&lt;li&gt;&lt;a href="' . $row-&gt;tr_survey_link . '"&gt; ' . $row-&gt;Survey_Subject . '&lt;/a&gt;&lt;/li&gt;'; </code></pre> <p>How would I add a field after the Href each time I try I get nothing showing in list... </p> <p>want to add $row->Evaluator_Type before or after link.... but it just...
php
[2]
5,510,290
5,510,291
String or binary data would be truncated. The statement has been terminated
<p>In my web application,i am storing password in the database using encryption. the password field's datatype is nvarchar(max). Even i enter the 10 character password e.g. '8427484274' then also i am getting the error. I came to know by searching this is the error we get when we try to store the data more then the dat...
asp.net
[9]
1,806,929
1,806,930
in python , how to make two lists contianing the same elements not equal with each other?
<p>say we got two lists: </p> <pre><code>a = [1, 2, 3] b = [1, 2, 3] </code></pre> <p>then all the following expressions will return True:</p> <pre><code>a == b # True a == list(b) # True a == list(tuple(b)) # True a == copy.deepcopy(b) # still True </code></pre> <p>But i do want a "False" returned, because when a...
python
[7]
5,265,134
5,265,135
I have a requirement that is converting a string (2011/05/02 02:55:20 PM) to date
<p>I have a requirement that is converting a string (2011/05/02 02:55:20 PM) to date</p>
java
[1]
1,137,040
1,137,041
Using JavaScript to launch window behind browser for users agreeing to survey
<p>I am asking a small percentage of users on a site if they would take a short survey. If they click 'yes' I would like to close the little pop-up window i have open that is asking them, and launch a new window in the background that comes to the forefront once they leave my domain - or close their browser.</p> <p>R...
javascript
[3]
3,462,601
3,462,602
Programmatically change the width of the Button in android
<p>How to change the Width of a button programmatically. I am able to change the height but the width does not change. Following is my code snippet</p> <pre><code>private void createButton(final String label) { Button button = new Button(this); button.setText(label); button.setWidth(10); button.setH...
android
[4]
3,709,266
3,709,267
Iphone Movement in particular direction with particular speed
<p>How can i find when iphone moving particular direction (i.e X axis) with particular speed using its UIAcceleration values?</p> <p>Can anyone help me ?</p> <p>Thanks in advance.........</p>
iphone
[8]
1,926,090
1,926,091
Why are the MDC prototype functions written this way?
<p>In MDC there are plenty of code snippets that meant to implement support for new ECMAScript standards in browsers that don't support them, such as the <code>Array.prototype.map</code> function:</p> <pre><code>if (!Array.prototype.map) { Array.prototype.map = function(fun /*, thisp */) { "use strict"; i...
javascript
[3]
2,639,968
2,639,969
CSV file to flat array with materialized path
<p>I have CSV file which contains a list of files and directories:</p> <pre><code>Depth;Directory; 0;bin 1;basename 1;bash 1;cat 1;cgclassify 1;cgcreate 0;etc 1;aliases 1;audit 2;auditd.conf 2;audit.rules 0;home .... </code></pre> <p>Each line depends on the above one (for the depth param)</p> <p>I would like to cre...
php
[2]
3,161,638
3,161,639
Can I have a form on index.php and process it with index.php
<p>Is this possible? I have looked online and cannot seem to find an answer.</p>
php
[2]
57,213
57,214
Create bitmap to compare two images by pixel
<p>I am trying to compare two images by pixel. I have searched on Google about bitmap but I did not clear with it.</p> <p>My code is showing error <code>Parameter is not valid</code>.</p> <p>I have try this;</p> <p>var a = new Bitmap(imageurl);</p> <p>but it does not work.</p> <p>I am also refer this site for imag...
c#
[0]
217,390
217,391
Using a for loop to count size or List<string>?
<p>I have a for loop in which i test for the size of a list.</p> <pre><code>for(int i = 0; i&lt; thumbLinks.size(); i++) { Log.e("URL" + i, thumbLinks.get(i)); url0 = thumbLinks.get(i); url1 = thumbLinks.get(i); //Fix index out of bounds ...
java
[1]
3,764,145
3,764,146
How to get mp3 file duration Http streamed over Android MediaPlayer
<p>I am making a media player application in which i have a Mp3 file URL that i need to http stream down over Android MediaPlayer.</p> <p>Now My Streaming is working very fine . Song is getting downloaded and Played Successfully. But i need to show the Downloading and Song Progress over a ProgressBar/SeekBar. As soon ...
android
[4]
5,127,580
5,127,581
How to prevent multiple object instantiations of a certain class
<pre><code>MyInterface intf = (MyInterface) Class.forName(className).newInstance(); </code></pre> <p>I have a certain piece of code which will create new interfaces on demand using the above call and invoke a certain method. All of the implementation classes usually contain lots of <code>final static</code> variables ...
java
[1]
5,344,797
5,344,798
Deleted nib still displayed when controller is pushed
<p>I have an application with a UINavcontroller under a tab bar controller. To create the navigation model I want, I push a container UIView object onto the stack to manage additional views(Thanks Frank). When I created the container class, an associated nib file was created along with it. I at first used that nib f...
iphone
[8]
1,762,874
1,762,875
input file cannot be found
<p>I am just messing around with reading input files with java until I got stumped at the most basic of steps... finding the input file!</p> <p>The input.txt file is in the same directory as my class file that is calling it yet eclipse still gives me an error that it cant be found:</p> <p>"Exception in thread "main" ...
java
[1]
3,359,913
3,359,914
Improving performance of ifstream in c++
<p>I apologize if this question is a bit vague or just plain stupid, I am still very much a novice.</p> <p>I need to extract information from a web log file in c++. The string manipulations are relatively, accessing the data in a timely fashion isn't. What I am doing currently</p> <p><code>string str;</code></p> <p...
c++
[6]
979,629
979,630
Time Calculation
<p>I am on a time calculation to calculate a delay time for a train Schedule time : t1 Arrival time : t2</p> <pre><code>function tomdiff(t1,t2) { var t1 = hour2mins(t1); var t2=hour2mins(t2); var ret = mins2hour(parseInt(t2-t1)); if(t2&lt;t1) {ret=mins2hour(parseInt(parseInt(t2+1440)-t1));} return ret...
jquery
[5]
5,503,156
5,503,157
Python command line SETUP for ABSOLUTE BEGINNER with Python
<p>I'm "new school" meaning that i've never really used the command prompt(they didn't teach us anything but IDE's in school). I would like to setup Python using Notepad++ for the editor, and winpdb as my debugger.</p> <p>I want stuff to work really easy from the cmd prompt but it is not.</p> <p>This is what I put in...
python
[7]
2,597,947
2,597,948
Scale textsizes for different screen sizes
<p>I have some layouts and I want to adjust my textsize to the screen size. I used sp for all my sizes, but when I switch to my tablet my text still looks to small. </p> <p>Is there a common scale formula or something to simply do this ?</p>
android
[4]
115,955
115,956
Get the number of unread mails on an Android Device
<p>Is there a way to ask the mail programms on an Android Device how many unread mails they have?</p>
android
[4]
2,447,977
2,447,978
Understand Reference and Dereferencing Operators?
<p>Can someone please help me understand Reference and Dereference Operators?</p> <p>Here is what I read/understand so far:</p> <pre><code> int myNum = 30; int a = &amp;myNum; // a equals the address where myNum is storing 30, int *a = &amp;myNum; // *a equals the value of myNum. </code></pre> <p>When ...
c++
[6]
2,052,061
2,052,062
Java, opinion on using Object class?
<p>I'm wondering what the general opinion is on using Java's Object class for something like this:</p> <pre><code>private Car myCar; private String myCarBrand; public void set(String variableToSet, Object valueToSet){ if(myCarBrand.equals("AUDI")){ if(varibleToSet.equals("COLOR")) (Audi myCar)....
java
[1]
332,194
332,195
Callback routine in Android
<p>I ran into a piece of Android code. I don't quite understand the purpose of the callback because it's empty. </p> <p>In Animation.java</p> <pre><code>private AnimationCallback callback = null; public Animation(final AnimationCallback animationCallBack) { this(); callback = animationCallBack; } public voi...
android
[4]
1,329,730
1,329,731
How to share a variable across classes in Java, I tried static didn't work
<p>class Testclass1 has a variable, there is some execution which will change value of variable. Now in same package there is class Testclass2 . How will I access updated value(updated by Testclass1) of variable in Testclass2. tried this didn't work </p> <p>Note: Testclass1 and Testclass2 are two separate files in s...
java
[1]
1,645,746
1,645,747
Array in gridview
<p>I have a string array data[].I need to bind this string array as datasource in gridview. I have values in data array. I write the code gridview_forecast.DataSource = data; gridview_forecast.DataBind(); I got an <strong>error</strong> as "A data item was not found in the container. The container must either...
asp.net
[9]
3,612,365
3,612,366
onchange event and auto grow textbox
<p>i have made auto grow textarea.it's working fine but when copying and pasting using right click it's not working properly.if i use onchange event in this situation it won't work either because to fire this event we need press enter or tab. please help me to solve this problem</p>
javascript
[3]
4,025,209
4,025,210
How to add tabhost control on each page of our android application?
<p>I want to display and handle events of tabhost control on each page of android application without creating it again and again, as in asp.net we have masterpage concept on which we can place our common controls, is there anything in android, so that i can place tabcontrol there.</p>
android
[4]
3,309,966
3,309,967
fputcsv and checkboxes
<p>I trying simplify my form submit by using <code>fputcsv</code>. my question is how do I process checkboxes? also since i'll be appending do I need to change the <code>"w"</code> to <code>"a"</code>?</p> <pre><code>if(isset($_POST['submit'])) { $data = implode(',', $_POST); if( $fp = fopen('form_data.csv', ...
php
[2]
4,604,341
4,604,342
Creating IPA file for iPad testing
<p>I need to give an IPA file for testing in my clients i Pad. I have given him 3 IPA files so far and all of them crashed when installing. The client says when clicking on the app icon a black screen appears and closes immediately taking him back to the home screen. How do i create an IPA file. I need clear steps fro...
iphone
[8]
1,827,666
1,827,667
How to append before last li in dropdown list
<p>I am using the following form builder (<a href="http://dontlink.me/formbuilder/" rel="nofollow">http://dontlink.me/formbuilder/</a>) and making lots of changes to it to work the way I want.</p> <p>One of the things I want it to do is when you add a new form field, I want that form field to be placed at the bottom o...
jquery
[5]
4,741,864
4,741,865
jQuery Cookie path/subdirectory issue
<p>I hope someone might be able to help me out. I have an jQuery animated quicklaunch in which I "remember" the open/closed states through use of jQuery cookies. This works well, with the exception of certain instances.</p> <p>Basically works as planned on every /path1/SitePages/ wiki page as necessary, however</p> <...
jquery
[5]
17,564
17,565
Get Current Time of CalendarEntry of Google Calendar API
<p>I was wondering, is there anyway to get the current time of a CalendarEntry, of Google Calendar API.</p> <p>I try to use the following hack :</p> <pre><code> try { if (calendarEntry.getSummary().getPlainText().equalsIgnoreCase("XXX")) { calendarEntry.setSummary(new Pla...
java
[1]
3,481,490
3,481,491
jquery code to change number to other with fading like digg
<p>i have this :</p> <pre><code>&lt;script&gt;var newnumber="680";&lt;/script&gt; &lt;div id="number-area"&gt;458&lt;div&gt; &lt;button onclick="changeit()"&gt; </code></pre> <p>i want a jquery code to change the content of the div "number-area" to the variable "newnumber".</p> <p>and that's with a fad in &amp; fad ...
jquery
[5]
1,557,402
1,557,403
Search for elements that matches a pattern in PHP
<p>I have a string like <code>sub_category-21,cross_category-23,sub_category-33,sub_category-93,cross_category-69</code>.</p> <p>I want to obtain the numbers for sub_category and the ones for cross category.</p> <p>What I've done since now is seperate it in an array:</p> <pre><code>$categories = explode(",", $_POST[...
php
[2]
5,947,290
5,947,291
Android: What is a difference between 'orientation' and 'screenLayout'?
<p>There are 2 different constants that have same description (<a href="http://developer.android.com/intl/de/reference/android/R.attr.html#configChanges" rel="nofollow">http://developer.android.com/intl/de/reference/android/R.attr.html#configChanges</a>)</p> <pre><code>orientation 0x0080 The screen orientation has c...
android
[4]
630,911
630,912
Patterns / Design
<p>I do C# programming as a hobby mostly. This means I write certain amounts of code but lack the insight of other programmers, senior or not to provide insight into alternative, more useful or cleaner code patterns or habits. Even design of a library itself.</p> <p>How do others deal with this situation to get decent...
c#
[0]
1,247,484
1,247,485
Android - keytool XML signing/verification
<p>Is it necessary to create both (private and public keys) via keytool utility? Is the private key created by "-protected" added when exporting keystore by keytool? If I have now private and public keys, how to make initial signing process and verification of some, e.g. external XML document?</p> <p>Thanks</p>
android
[4]
2,703,013
2,703,014
Android: Animated gif
<p>I've got an animated gif which is a loading bar. The image displays but there is no animation, how would I get it to animate?</p>
android
[4]
4,621,953
4,621,954
Is there a way to use out parameter as an optional parameter in C#?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/4293627/optional-output-parameters">Optional Output Parameters</a> </p> </blockquote> <p>I am currently working in a module wherein I need to add a new out parameter to a function which has been used in so many ...
c#
[0]
5,868,024
5,868,025
Avoid OutOfMemoryError in android
<p>Loading images onto ImageView in xml takes more memory?</p> <p>I Have an Activity with around 7 imageviews(just like the app tray in any android phone.)</p> <p>I am loading the images for each of the imageviews in the xml. Does this cause OutOfMemoryError? </p> <p>Is there a way to recycle these?</p>
android
[4]
783,673
783,674
PHP pagination loses variable on other pages- whats the solution?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/11638999/php-pagination-loses-variable-on-other-pages">PHP pagination loses variable on other pages</a> </p> </blockquote> <p>I am having the exact same issue that another member had. This issue was brought up b...
php
[2]
2,469,422
2,469,423
Getting "multiple types in one declaration" error in C++
<p>Can anyone tell me why i get a "Block.h:20: error: multiple types in one declaration" error message when compiling this file. Nothing seems to be solving this problem and I'm getting pretty frustrated.</p> <p><strong>Displayable.h</strong></p> <pre><code>#include &lt;X11/Xlib.h&gt; #include &lt;X11/Xutil.h&gt; //...
c++
[6]
1,968,253
1,968,254
Command prompt within another widget
<p>I have a GUI with label and entry widgets on a frame widget. I want to add a command prompt.to the frame through which the user can submit commands. I know about using the cmd module to create a prompt in the python shell, but I want the prompt to be part of my GUI window. Is there a way to 'embed' a command prompt ...
python
[7]
5,217,296
5,217,297
Adapter for list view
<p>please guide me with this program. Why do we need to use an array adapter to show the list? What is this "adapter", and can we display things directly in the ListView, without an adapter? Like, can we set setListAdapter(names) instead of setListAdapter(adapter);? Thanks.<br> Here is the code:</p> <pre><code>import ...
android
[4]
4,881,990
4,881,991
iphone - handle web page with in the application
<p>i'm currently working on iphone app which has a web view. i'm pulling a web page from internet and updating the web view. the web page has 3 text inputs: username, mail id and response code. it also has a button "play now". on click of play now, the data is posted to server and some processing is done there...... no...
iphone
[8]
4,282,009
4,282,010
Override asp.net form tag
<p>I have master page that contains the following asp.net form tag</p> <pre><code>&lt;form id="CommerceMasterForm" runat="server"&gt; </code></pre> <p>on one page of my website i need to create normal html form from a user control</p> <pre><code>&lt;FORM action="http://externaldomain.com" method="post"&gt; </code></...
asp.net
[9]
1,708,648
1,708,649
Android-Expandable List view
<p>How to move the group item to left when you deleted the default group indicator by using setGroupIndicator() method. </p>
android
[4]
3,486,292
3,486,293
Why does this floating-point calculation give different results on different machines?
<p>I have a simple routine which calculates the aspect ratio from a floating point value. So for the value 1.77777779, the routine returns the string "16:9". I have tested this on my machine and it works fine.</p> <p>The routine is given as :</p> <pre><code> public string AspectRatioAsString(float f) { ...
c#
[0]
2,205,498
2,205,499
redirecting the output of shell script executing through python
<p>Hi I am trying to execute shell script from python using following command.</p> <pre><code>os.system("sh myscript.sh") </code></pre> <p>in my shell script I have written some SOP's, now how do I get the SOP's in my Python so that I can log them into some file?</p> <p>I know using <code>subprocess.Popen</code> I c...
python
[7]
4,035,456
4,035,457
Php SimplePie library not working properly
<blockquote> <p>Deprecated: Assigning the return value of new by reference is deprecated in C:\Workspace\htdocs\feedBlurb\processing\simplepie.inc on line 738</p> </blockquote> <p>this is the error I get when I run the following SimplePie code on my server:</p> <pre><code>&lt;?php require_once("processing/simpl...
php
[2]
3,276,980
3,276,981
how to connect android and mysql server?
<p>I want to get the details from online mysql databse in android. I have wrote a php script to get the details form mysql database and convert the result as json string and extract the details in android using some sort of methods. I am new to android development I think there should be some simple way to do this. if ...
android
[4]
3,794,327
3,794,328
Need help understanding this block of code (java)
<pre><code>public class Bicycle { private int cadence; private int gear; private int speed; public Bicycle(int startCadence, int startSpeed, int startGear) { gear = startGear; cadence = startCadence; speed = startSpeed; } </code></pre> <p>when you write gear = startGear; what does this actually do? does ...
java
[1]
4,576,289
4,576,290
How to read output of hexdump of a file?
<p>I wrote a program in C++ that compresses a file.</p> <p>Now I want to see the contents of the compressed file.</p> <p>I used hexdump but I dont know what the hex numbers mean.</p> <p>For example I have:</p> <p><code>0000000 00f8</code><br> <code>0000001</code></p> <p>How can I convert that back to something tha...
c++
[6]
4,085,327
4,085,328
permutation of integer arrays
<p>I want a Java code for permutation of <code>int</code> arrays.</p> <p>Suppose an input of <code>1 2 3</code> and the program would return all the possible combinations of these elements.</p> <p>I have written a Java code which takes <code>String</code> array as an input and returns <code>int</code> array. But when...
java
[1]
5,179,660
5,179,661
Can the android API be used to intercept and read operator messages (USSD messages)?
<p>Through the android API is it possible for an android application to read the message sent by the mobile network operator as and when the user receives it as shown in the message below. If so how?:</p> <p><img src="http://i.stack.imgur.com/cC5cC.png" alt="Operator message regarding data usage in Android"></p>
android
[4]
982,704
982,705
How to get a file name based on last modified in php?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/5448374/get-last-modified-file-in-a-dir">get last modified file in a dir?</a> </p> </blockquote> <p>I have lot of file inside a folder. How can I get the last modified file name using php?<br> Is it possible? ki...
php
[2]
1,341,727
1,341,728
Integer storage - Hexadecimal/Octal
<p>I understand that integers are stored in binary notation, but I was wondering how this affects the reading of them - for example:</p> <p>Assuming </p> <pre><code>cin.unsetf(ios::dec); cin.unsetf(ios::hex); and cin.unsetf(ios::oct); </code></pre> <p>the user inputs</p> <pre><code>0x43 0123 65 </code></pre> <p>wh...
c++
[6]
3,803,728
3,803,729
how do i check hosts in php?
<p>I want to match by hostname and I can't figure out how, </p> <p>example: i want to force all links to be from <code>oi*.tinypic.com</code> or <code>i*.tinypic.com</code>. However people bypass my current validation by using then adding hash at the back of the URL like <code>.jpg#tinypic</code>, if i use <code>strip...
php
[2]