Unnamed: 0 int64 302 6.03M | Id int64 303 6.03M | Title stringlengths 12 149 | input stringlengths 25 3.08k | output stringclasses 181
values | Tag_Number stringclasses 181
values |
|---|---|---|---|---|---|
5,105,953 | 5,105,954 | Delete a line in file (Android/java) | <p>In my app (Android) I create a file. To this file I add a line by line after some situation. Then I send a data to the server line by line. When all transmission is OK I erase the file, like this:</p>
<pre><code>fos_kasowanie_pliku = openFileOutput(FILENAME, Context.MODE_PRIVATE);
fos_kasowanie_pliku.write("".getBy... | java android | [1, 4] |
701,884 | 701,885 | Prompt box with 2 text fields | <p>I am trying to make a social website.I need to create a <code>pop up window</code>(may be prompt box in javascript) when the user clicks on <code>create message</code> button.The pop up window should contain 2 text fields just like facebook message pop up window.First one for the name of the recipient and the second... | php javascript | [2, 3] |
1,889,311 | 1,889,312 | jQuery event listening | <p>Basically I want to be able to call jQuery from FireBug, place code that listens to all event fires on the page, then displays info about the event fire without knowing anything about the page structure or the types of event it has.</p>
<pre><code>var s = document.createElement('script');
s.setAttribute('src', 'htt... | javascript jquery | [3, 5] |
3,354,009 | 3,354,010 | How to use internal layouts in Android? | <p>I have been developing application which uses ListView. A ListView has items which contains 2 text fields and 1 picture. I have developed application with internal layouts for ListView items (android.R.layout. ...), but I don't know anything about layouts with image fields. Is there anything similar my task? Or shou... | java android | [1, 4] |
4,229,026 | 4,229,027 | Javascript uppercase not working | <p>I am trying to change text input value after user fill it, to uppercase string: </p>
<pre><code>$('#University').blur(function(){
if ( $(this).attr("value") != '') {
var uni = $(this).val();
uni.toUpperCase();
alert(uni);
$(this).attr("value", uni);
};
});
<input type... | javascript jquery | [3, 5] |
4,550,818 | 4,550,819 | how to publish web application in ASP.NET C#? | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/5190217/how-to-run-asp-net-c-web-application-locally">How to run ASP.NET C# web application locally???</a> </p>
</blockquote>
<p>Hi everyone , How to publish web application done on Visual Studio 2010, OS window... | c# asp.net | [0, 9] |
5,068,148 | 5,068,149 | Jquery constraint proportions with width and height input fields | <p>I have a form with width and height input fields.
I want to listen to changes made in any one of the fields by the user
and change the value in the other field wile constraint proportions using Jquery.
the user can see the changes as he typs. </p>
<pre><code><form>
<p>
<label>Width</label... | javascript jquery | [3, 5] |
1,867,913 | 1,867,914 | Setting default date format for datepicker? | <p>I have a page where I keep track of various dates. So I end up using datepicker through jquery anywhere from 10-200 times. I want to set the default for all cases of datepicker to the 'yy-mm-dd' - but I can't seem to figure out how to set that?</p>
| javascript jquery | [3, 5] |
2,485,094 | 2,485,095 | Omitting special characters from the string using Jquery | <p>I have to implement some type of pixel for analytic and it requires passing a session Id in the url string. My sessionID contains special characters. It looks something like this <strong>BFhGlzT6FBkDr2Zndp0!-1309</strong>
I need to remove the (-!) characters from this string, how do I achieve this using jquery? I ne... | javascript jquery | [3, 5] |
1,390,712 | 1,390,713 | Using jquery validate() while at the same time having a submit handler | <p>I make an ajax call and return some JSON when my user submits a form which is part of my .submit() handler.</p>
<p>I am also trying to attach some validation to this form now.</p>
<p>The result I am getting with the below code is that I do receive the "Field is required" error message, but the form is being submit... | javascript jquery | [3, 5] |
2,488,551 | 2,488,552 | How to find the nearest common ancestors of two or more nodes? | <p>Users selects two or more elements in a HTML page. What i want to accomplish is to find those elements' common ancestors (so body node would be the common ancestor if none found before) ?</p>
<p>P.S: It can be achieved with XPath but it is not a preferable option for me. Also it may be found with css selector parsi... | javascript jquery | [3, 5] |
5,646,610 | 5,646,611 | Jquery dont allow button to be pressed | <p>If i have a button pressed method like this:</p>
<pre><code>$('#next').click(function () {
});
</code></pre>
<p>How can i stop this method being initiated whilst its running. Say the method takes 5 seconds to run and someone clicks it 3 seconds in it breaks so i want to make the div thats being clicked unclickable... | javascript jquery | [3, 5] |
3,392,073 | 3,392,074 | Get all inputs from a submitted form | <p>I have a form that has no id, no class whatsoever. I need to get all the inputs that are inside it, I have a script but it will get all inputs no matter if they are inside my form or not.</p>
<p>Of course I could add classes, id's to my forms but is there any way of doing what I want without adding identifiers to m... | javascript jquery | [3, 5] |
2,181,106 | 2,181,107 | Php calling javascript on load | <p>Guys i have little problem with PHP to call Javascript function on load ...
Idea is when page load i do little calculation with PHP stuff , so when i finish that all i
want is to write that down in same DOM element using javascript.
I will not show you PHP code for calculation as i am 100% sure it is alright.
This ... | php javascript | [2, 3] |
4,655,737 | 4,655,738 | jquery toggle function open/close | <p>Trying to do a function that does "A" when toggle open and "B" when toggle close.</p>
<p>Code:</p>
<pre><code>function awesome_toggle()
{
$(".button").click(function()
{
$("content").toggle(
function()
{
/* Do "A" */
},
function()
... | javascript jquery | [3, 5] |
954,500 | 954,501 | Member method consting in Java? | <p>In C++, a member method can be const if it does not modify the class. For example:</p>
<pre><code>class Foo {
public:
float getValue() const;
};
</code></pre>
<p>Is there something similar I must do in Java classes? How exactly does consting work in Java? (Aside from adding the final keyword before a member vari... | java c++ | [1, 6] |
3,810,914 | 3,810,915 | Refresh page after update looping.. div better? | <p>I have a page where i'm using edit-in-place... now, after the update it's showing slashes even though I am using stripslashes() - prob because ajax call just updating the div therefore bypassing the stripslashes function</p>
<p>Anyway, if i refresh the page manually they go away, which is what I need... so, i figur... | php javascript jquery | [2, 3, 5] |
162,110 | 162,111 | FormsView data bind goes wrong | <p>I got a fromview defined as following:</p>
<pre><code> <asp:TableCell>
<asp:UpdatePanel runat="server" id="UpdatePanel2" updatemode="Conditional">
<ContentTemplate>
<asp:FormView ID="LavenderRegion" AutoGenerateColumns="true" AutoGenerateEditButton="true" AutoGenerateSel... | c# asp.net | [0, 9] |
4,561,250 | 4,561,251 | Read data from .xls and .ods files | <p>Is there a way to read data from excel and open office spreadsheets and save them to a temporary store, like a DataSet or array? I came across ExcelDataReader (http://exceldatareader.codeplex.com/), but it only works if the user has Excel installed on their computer. Some of our users only have Open Office (and othe... | c# asp.net | [0, 9] |
5,808,574 | 5,808,575 | Why is Javascript called Javascript, if it has nothing to do with Java? | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/2018731/why-is-javascript-called-javascript-if-it-has-nothing-to-do-with-java">Why is JavaScript called JavaScript, if it has nothing to do with Java?</a> </p>
</blockquote>
<p>Why Javascript is called Javascrip... | java javascript | [1, 3] |
3,438,111 | 3,438,112 | How to write functions in jQuery? | <p>I'm going to be writing a callable function which will make use of jQuery. But I can't find any reference to ordinary function declaration with jQuery; it's all about element manipulation functions. Can I essentially just declare an ordinary javascript function and then use jQuery in it, or do I need to be doing som... | javascript jquery | [3, 5] |
2,840,378 | 2,840,379 | Sending email to a user | <p>I am using this code to send email</p>
<pre><code>var message = new MailMessage("abc@somedomain.com", "administrator@anotherdomain.com");
message.Subject = "Testing";
message.IsBodyHtml = true;
message.Body = "<html><body>IMAGINE A LOT OF HTML CODING HERE</body></html>";
</code></pre>
<p>Th... | c# asp.net | [0, 9] |
5,606,399 | 5,606,400 | Calling JavaScript function from code beind (c#) catch block | <p>I am trying to call a JavaScript function from my ascx control code behind in the catch block.
I have tried the below two ways but they don't seem to work.</p>
<ol>
<li><p><code>Page.ClientScript.RegisterClientScriptBlock(typeof(string), "script", "test();", true);</code></p></li>
<li><p><code>ScriptManager.Registe... | c# javascript asp.net | [0, 3, 9] |
4,998,181 | 4,998,182 | Replacing part of a text using jQuery's .replaceWith function | <p>I am working on a new masterpage withing sharepoint 2010. One of the placeholders produces the sitename - the page name in a string. When the page is ready the sources shows this for exampe. </p>
<pre><code><h1 class="ribbonmc">
Devness Squared - Mark Jensen
</h1>
</code></pre>
<p>Devenss Squared i... | javascript jquery | [3, 5] |
4,822,495 | 4,822,496 | Enable button after writing file to response | <p>There is many similar questions but there is still no clear answer that is solving the problem taking some action after writing some stream to response.</p>
<p>I have a following situation:</p>
<p>On button click I am generating some excel file that I am going to write to response allowing user to download generat... | c# asp.net | [0, 9] |
1,804,951 | 1,804,952 | how to compare two base64 string? | <p>I have a base64 string(source string) which was converted from an image, I need a code to compare that string with another base64 string on web service and check which string have the most similarities to the source string,the language I use is C#, can anyone help me ???</p>
| c# asp.net | [0, 9] |
407,235 | 407,236 | Programming language for simple dynamic web site development? | <p>I only know the basics of HTML/CSS. The only experience with web development I have is whatever I learned in Web Development 101 at my university, aka "OMG - CSS u guise, 101". </p>
<p>I'm mainly interested in building simple dynamic sites. That's the whole reason I got into this in the first place. I'm at the poin... | php python | [2, 7] |
1,688,422 | 1,688,423 | java.lang.NoClassDefFoundError: android.media.ThumbnailUtils | <p>i try to use the <a href="http://developer.android.com/reference/android/media/ThumbnailUtils.html" rel="nofollow"><code>android.media.ThumbnailUtils</code></a> class to fetch the video thumbnails from the video which is locate under specified path, for that i use the following code,</p>
<pre><code>Bitmap thumb = ... | java android | [1, 4] |
4,227,979 | 4,227,980 | Alternative to if..else statment | <p>I have a table in a database that contains a bunch of different controls. In my Page_Init method, I need to load the appropriate control based on a Session variable that is being passed in. Is there any better way to do this then using a whole bunch of if..else statements? I have about 15 to 20 different scenarios... | c# asp.net | [0, 9] |
61,663 | 61,664 | Add data to textbox | <p>I would like your help in order to solve the following issue. I want to show the value of several fields in different TextBox. </p>
<p>I have a GridView with a hyperlink Field on Name. When I click on the Name I want, I go directly to the Profile Page of that Name. And there is where the problem resides. I want to ... | c# asp.net | [0, 9] |
4,892,484 | 4,892,485 | show/hide html content in javascript | <p>I have response which is coming from backend . Now i want to create some links, if i click those links it should display html content below that link and if i click that link again those html content should go. I know jquery hide() and show() . But here i am using for loop and i am not able to find DOM element ,
as ... | javascript jquery | [3, 5] |
4,041,279 | 4,041,280 | How do I pass a javascript function I've already defined into a jquery call? | <p>For example, if I have:</p>
<pre><code>function example() {
alert("example");
}
</code></pre>
<p>Then why doesn't this work?</p>
<pre><code>$("h2").click( example() );
</code></pre>
<p>Does it have to be defined inline?</p>
| javascript jquery | [3, 5] |
5,052,479 | 5,052,480 | How to check value of INPUT element on change? | <p>I have an INPUT element of the TEXT type and I want to perform an action whenever the INPUT's value does not equal a default value. How do I do this? I've looking into jQuery's "change" event handler, but it only works for SELECT elements. Anyhow, here is what I want to do..</p>
<p>Example:</p>
<pre><code><inpu... | javascript jquery | [3, 5] |
3,949,692 | 3,949,693 | Pass a javascript variable to a php function | <p>I would pass a variable javascript to a php function but it doesn't work.</p>
<p>I call my javascript function in <code><a href='javascript:showDetail(5);'>detail</a></code></p>
<p>and this is the javascript function where call my <code>showInfo</code> php function</p>
<pre><code>function showDetail... | php javascript | [2, 3] |
5,954,078 | 5,954,079 | Writing better selector in jQuery | <p>What would be the best way to write the following selector?</p>
<pre><code>id = "#id",
$id = $("#id");
//works but seems wrong
$($id, 'a').click(function(){
//do stuff..
});
//this was not working for me.
$id.find('a').click(function(){
// do stuff...
});
</code></pre>
| javascript jquery | [3, 5] |
4,855,592 | 4,855,593 | How to disable/enable button when the edit text is empty/nonempty | <p>I have 2 edit text and 1 button. How can I make this button to be disabled until the user fill all the edit text? I used this code but when I run this code it always disable the button even when I fill the 2 Edit text, also I do not know what the onTextChanged and beforeTextChanged doing!!</p>
<p>Please help me, I ... | java android | [1, 4] |
952,954 | 952,955 | Get the current browser window center | <p>How do I get the browser window height so I can find the center position?</p>
<p>I only need the window height, not the web page height.</p>
<p>I tried <code>$(window).height() / 2</code> but it only works if the browser has focus from the top of the page. If I scroll down I get the wrong center.</p>
| javascript jquery | [3, 5] |
5,097,481 | 5,097,482 | How to kill Android process if user opens youtube | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/6531627/how-to-restrict-android-device-to-not-open-some-specific-site-e-g-youtube-facebo">How to restrict Android device to not open some specific site e.g.youtube, facebook</a> </p>
</blockquote>
<p>I am writin... | java android | [1, 4] |
1,034,266 | 1,034,267 | How to trigger PHP/jquery when a button is clicked | <p>PHP noob here...so please excuse me if you find this to be a lame question.</p>
<p>I have the following form:</p>
<p>HTML </p>
<pre><code><form id="myForm" action="" method="post">
<div id="edit-box">
<INPUT type="submit" name="save-text" id="save-text" value="Save">
<textarea id="editor" nam... | php jquery | [2, 5] |
1,998,327 | 1,998,328 | PHP server for Android turn based multiplayer game? | <p>I developed a turn based game for Android, and now I want to add multiplayer gaming. I don't want to use providers like "skiller", I would like to develop my own server. </p>
<p>I don't have a dedicated server, but I have a php hosting with "1 and 1". Would be a good idea to use this hosting like a game server? My ... | php android | [2, 4] |
2,566,792 | 2,566,793 | Object Parameter/Function and/or Ternary Operator Confusion | <p>Sorry for the ambiguous "Title" but I'm struggling to come up with one that captures my question pithily. </p>
<p>I'm working through R Murphy's <a href="http://jqfundamentals.com/book/index.html" rel="nofollow">JQuery Fundamentals</a> and am stuck on a snippet of code in her solution: <a href="https://github.com/r... | javascript jquery | [3, 5] |
4,003,124 | 4,003,125 | BitmapFactory throws NullPointerException (sometimes) | <p>I'm beginning to learn programming on android, but I have come across a problem with Bitmap factory. Here is the code:</p>
<pre><code>public class MainGamePanel extends SurfaceView implements SurfaceHolder.Callback {
private MainThread gameThread;
public ResourceManager resourceManager;
public MainGame... | java android | [1, 4] |
5,413,926 | 5,413,927 | jQuery Dropdown Check List: jQuery click() anomaly | <p>I have a page with several dropdownchecklists, all with checkboxes (multiple selects possible). Inside document ready, I have this simple code:</p>
<pre><code>$(":checkbox").click(alert('TEST'));
</code></pre>
<p>The problem is that when the page first loads, the alert fires. What I want to do is only fire the al... | javascript jquery | [3, 5] |
653,899 | 653,900 | Placing a counter incrementing and decrementing when items are added and removed using jquery | <p>Please find the code below</p>
<pre><code><script type="text/javascript">
$(function(){
var c=1;
$("#i1").toggle(function(){
$("#e1").appendTo("#i2");
$('#counter').attr('value',c);
},
function(){
$("#e1").appendTo($(this));
$('#c... | php jquery | [2, 5] |
3,615,107 | 3,615,108 | page 140 quiz questions | <p>I'm working right now at present to make a quiz page to my friends about firefighter training. and I'm thinking about whether I can do it with javascript or should I do it with php?. where there are about 140 questions but I will start to build so there are only 10 questions to start with :)</p>
<p>I never try to d... | php javascript jquery | [2, 3, 5] |
3,468,239 | 3,468,240 | setting asp image src property from javascript | <p>I am trying to set asp image element src property from javascript but the url property is not being set.</p>
<pre><code>function slideshow() {
$.ajax({
type: "POST",
contentType: "application/json; charset=utf-8",
url: "/RollingScreen.aspx/GetNextImage",
dataType: "json",
data: "{}",
succe... | jquery asp.net | [5, 9] |
421,504 | 421,505 | jquery show() not working | <p>im making a todo list app in php and im using unordered lists to print them out.What I want is to display the titles of todo lists to be displayed first and their contents hidden initially but displayed later via the click event in jQuery.This is what i have tried so far...</p>
<pre><code><?php
include_once "co... | php jquery | [2, 5] |
4,193,192 | 4,193,193 | How to Remove Previous li of particular class? | <p>I tried this to remove the adjacent <code>li</code>, but it doesn't work:</p>
<pre><code> $(this).prev(".Removable").remove();
</code></pre>
<p>Edit: I only want to remove the immediate adjacent <code>li</code> if it has that class.</p>
<pre><code> WHEN SELECTABLE IS CLICKED I WANT THE PREVIOUS REMOVABLE TO VAN... | javascript jquery | [3, 5] |
1,390,618 | 1,390,619 | Error using Android textviews in Java | <p>I'm pretty sure there's something wrong with this part of a switch statement, but I'm stumped, and I just need someone to have a look over it.</p>
<pre><code>switch(buttonId)
{
/* LOTS OF CASES HERE */
default:
case R.id.goButton:
TextView rootNum = (TextView)findViewById(R.id.otherView);
... | java android | [1, 4] |
722,531 | 722,532 | Select class jquery | <p>I have a class called formStyle which occurs several times in my webpage. Is it possible to select let's say first and third (with jquery) if they are five </p>
| javascript jquery | [3, 5] |
903,121 | 903,122 | Javascript async loop inside another async loop | <p>I have some code in jQuery that iterate through children in div using each().
Every text inside is splitted into words. Each word is processed with 'for' loop.
This function can take a long time and can freeze the browser so...</p>
<p>Is there a way to create asynchronous loop inside another asynchronous loop but o... | javascript jquery | [3, 5] |
3,395,703 | 3,395,704 | How to set default value for Auto-Implemented Properties in ASP.NET | <p>I came to know that C# 3.0 comes with a new feature of Auto-Implemented Properties,I liked it as we don't have to declare extra private varible in this (compare to earlier property), earlier I was using a Property i.e. </p>
<pre><code>private bool isPopup = true;
public bool IsPopup
{
get
{
return is... | c# asp.net | [0, 9] |
5,341,330 | 5,341,331 | How we can attach the unobtrusive validation with the id of the field? | <p>I am using <code>unobtrusive validation</code> in jquery. My problem is that the validation is attach with the <code>name</code> of the element, is there any way to attach it with <code>id</code> of the element? </p>
| javascript jquery | [3, 5] |
5,255,944 | 5,255,945 | Replace Javascript click event with timed event? | <p>I've found some javascript code that layers photos on top of each other when you click on them.</p>
<p>Rather than having to click I'd like the function to automatically run every 5 seconds. How can I change this event to a timed one:</p>
<pre><code>$('a#nextImage, #image img').click(function(event){
</code></pr... | javascript jquery | [3, 5] |
1,182,736 | 1,182,737 | How to catch textchange event in textbox on mobile | <p>Now I'm developing a auto completor on mobile website. I want to catch textchange event of textbox on mobile. But I dont know how? Now I'm using focus, blur and setInterval to catch the change of textbox, but I think it's a bad idea for mobile website. Plz help me.</p>
<p>Cheers,
Bob khin</p>
| javascript jquery | [3, 5] |
863,474 | 863,475 | Jquery not working in IE 9 | <p>I am trying to create a toggle panel to show and hide the additional div.Please find my code snippet of the function below. It is working fine in Chrome,Safari&Firefox . It is not working on IE 9 alone. Please help. </p>
<pre><code> handleExpandClick : function(e){
e.preventDefault();
e.stopPr... | javascript jquery | [3, 5] |
5,919,057 | 5,919,058 | Initialize an array whose indexes are scattered over integer range | <p>How to initialize a string array (size<100 items) in javascript whose indexes are scattered over entire integer range, with data items.</p>
<p>If I do like this: </p>
<pre><code>array1 = ["string1","string2","string3","string4"];
</code></pre>
<p>then I get array of length 4 with indices ranging 0 to 3 </p>
<... | javascript jquery | [3, 5] |
3,520,581 | 3,520,582 | Jquery UI Not Loading | <p>I'm trying to use jquery draggable ui , but it seems like the ui is not well imported</p>
<p>I'd run this test :</p>
<pre><code>if(jQuery.ui){
alert("loaded");
}
else
{
alert("not loaded");
}
</code></pre>
<p>And got an "not loaded" alert....</p>
<p>Here are the first code lines o... | javascript jquery | [3, 5] |
112,927 | 112,928 | How and where do i use the i++ operator in C#? | <p>I was wondering if anyone could tell me about the <code>i++</code> operator in C#.</p>
<p>I know it adds one to the int value, but I wouldn't have a clue where to use it, and if its only for loop statements, or can be used in general projects.</p>
<p>If I could get some practical examples of where you might use th... | c# asp.net | [0, 9] |
1,739,875 | 1,739,876 | Array selector function by property value | <p>I have: </p>
<pre><code>var array = [ { key: '1' }, { key: '2' }, { key: '3' } ]
</code></pre>
<p>I want:</p>
<pre><code>var obj = getFirstItem(array, 'key', '2');
</code></pre>
<p>And as a result:</p>
<pre><code>obj = { key: '2' }
</code></pre>
<p>Is there such function in JavsScript or jQuery?</p>
| javascript jquery | [3, 5] |
5,458,290 | 5,458,291 | Uncaught TypeError: Object #<Event> has no method 'split' | <p>I'm writing a Javascript function to preload pictures on a website.</p>
<pre><code>function preload(images) {
if (document.images) {
var i = 0;
var imageArray = new Array();
imageArray = images.split(';');
var imageObj = new Image();
for(i=0; i<=imageArray.length-1; i++) {... | javascript jquery | [3, 5] |
1,213,206 | 1,213,207 | ASP..NET Hod to hide a Div before Page is loaded? | <p>I have a div on my page - I'd like when that page is being loaded tthat Div is being hidden by jQuery's .hide method. Now I have that when a page is ready then that div is hiding - but that hiding is visible. I don't want that</p>
<p>Now I have that code:</p>
<pre><code>$(document).ready(function(event)
{ ... | asp.net jquery | [9, 5] |
2,015,119 | 2,015,120 | Performance Tips try/catch blocks | <p>In ASP.NET I would like your opinion regarding what is the best way for Handling Exceptions.</p>
<ul>
<li>Would you suggest to use try/catch blocks?</li>
<li>Better to use try/catch blocks on every single piece of code/component? Or in wich situations?</li>
</ul>
<p>I really appreciate your help thanks!</p>
| c# asp.net | [0, 9] |
1,325,591 | 1,325,592 | Webworks code not working on android device | <p>I have Blackberry Webworks code(Javascript). I have already put that code in assets folder and call .html file from my native code creating webview in android. it Works fine on emulator but not working on Actual Device.
(I have already remove Blackberry Api calls from blackberry webworks code) any Suggestion??</p>
| javascript android | [3, 4] |
3,977,289 | 3,977,290 | system.web.mail vs system.net.mail | <p>Any body pls share the difference between <code>system.web.mail</code> and <code>system.net.mail</code></p>
| c# asp.net | [0, 9] |
622,523 | 622,524 | Why doesn't this code work? (2) | <p>This code works as expected:</p>
<pre><code>$(
function() {
$("tr:odd").css("background-color","#dddddd");
}
)
</code></pre>
<p>And this doesn't:</p>
<pre><code>function temp() {
$("tr:odd").css("background-color","#dddddd");
}
$(temp());
</code></pre>
<p>Why?</p>
| javascript jquery | [3, 5] |
3,700,258 | 3,700,259 | Javascript Type Error, is not a function | <p>I've got abit of a strange problem, that I just can't seem to solve! It's part of a big framework I'm writing, but I've wrote some test code which has the same problem. See the following:</p>
<pre><code>!function ($, window, undefined) {
// BASE FUNCTION
var test = function (selector, context) {
re... | javascript jquery | [3, 5] |
5,480,907 | 5,480,908 | Comma separated values in block | <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="http://stackoverflow.com/questions/519107/jquery-autocomplete-tagging-plug-in-like-stackoverflows-input-tags">jQuery autocomplete tagging plug-in like StackOverflow’s input tags?</a> </p>
</blockquote>
<p>I am working on a recruitment portal wher... | php jquery | [2, 5] |
2,233,658 | 2,233,659 | jQuery equivellent for dynamically create id | <p>I am looking for jQuery equivellent for the following. Please help. </p>
<pre><code>var request = document.getElementById('request_' + id1)
var response = document.getElementById('response_' + id1);
modifyText(request.firstChild.nodeValue,response.firstChild.nodeValue);
</code></pre>
| javascript jquery | [3, 5] |
5,162,394 | 5,162,395 | Append stylesheet link for printing triggered on jQuery click() event | <p>I have one css link on the head section that has <code>media='screen'</code> attribute, then I want to link the other css file that has <code>media='print'</code> attribute dynamically.</p>
<p>and I do this for the solution.</p>
<pre><code>$("div#alert").click(function(){
$('head')
.append("<link rel='s... | javascript jquery | [3, 5] |
3,378,377 | 3,378,378 | Android: Disallow user to select cursor position in EditText? | <p>Right now I use onFocusListener to automatically move the cursor to the end of the EditText string. This works fine when the box is being Focused, however, once focused if the user taps a position in the string, the cursor moves there. I've tried implementing other methods in addition to the Focus (Touch, Click) whe... | java android | [1, 4] |
2,322,358 | 2,322,359 | Limiting input to a set of characters while also displaying those characters | <p>I have seen in a few "username" fields where you type in a username, and below it, in something like a span, it will append it to a url. A lot like what is happening as I type this in StackOverflow at the bottom.</p>
<p>I would like to show only allowed characters from a list, ignore any input of characters not in... | javascript jquery | [3, 5] |
872,910 | 872,911 | How to encapsulate definitions into a class? (Use const and then scope it) | <p>All my PHP files conform to class.className.php as a naming conventoin. So I put all my definitions in a class called class.Configure.php like below. Is there a best practice way to put this in an acutal class. Consistency makes it easier for me to manage my code. </p>
<p>This is the only "loose" code I have in ... | php c++ | [2, 6] |
4,395,198 | 4,395,199 | read html file from asp.net | <p>I want to read <code>html</code> file and load control in <code>ascx</code> file in asp.net.I search in net but unable to find any resource.Please suggest links or any solution.Thanks.</p>
| c# asp.net | [0, 9] |
5,652,482 | 5,652,483 | Forms in ModalPopupExtender in ASP.net c# | <p>I am currently working on an ASP.net c# project. I have an aspx page where I have a form taking user input and a datagrid. When the user clicks on a link inside the datagrid it displays a modal popup extender with dynamic data. This is working fine. </p>
<p>What I want to be able to do is when the modal popup exten... | c# asp.net | [0, 9] |
4,851,081 | 4,851,082 | Remove word from substring | <p>I've got a list of links that looks like this</p>
<ul>
<li>Item 1 </li>
<li>Item 2 (foo) </li>
<li>Item 3</li>
</ul>
<p>How do I get jQuery to remove the string " (foo)" from the link text?</p>
| javascript jquery | [3, 5] |
58,795 | 58,796 | JQuery hover problem | <p>Im using jquery hover method to call a function as follows</p>
<pre><code>$(<some_element>).hover(function(){animate("next",true);},function(){});
</code></pre>
<p>But,the animate function is called only when the mouse enters the element. I want it to keep getting called as long as the mouse is over the elem... | javascript jquery | [3, 5] |
4,342,746 | 4,342,747 | PHP And JavaScript onClick? | <p>I have the following:</p>
<p><code>onClick='<?php $message = $_row['message']; $poster = $_row['poster'];?> deletePost();'"</code></p>
<p>I have a <code>while()</code> statement before the <code>onClick</code> (applied to a delete button) but need to set the values of the <code>$poster</code> and <code>$mess... | php javascript | [2, 3] |
3,491,329 | 3,491,330 | The type or namespace name GridViewHelper could not be found | <p>Fist off, I'm very new to ASP.NET and Visual Web Developer Express.</p>
<p>I have a datagrid that I want to display subtotals in and have grouping.</p>
<p>I found this <a href="http://www.agrinei.com/gridviewhelper/gridviewhelper_en.htm" rel="nofollow">http://www.agrinei.com/gridviewhelper/gridviewhelper_en.htm</a... | c# asp.net | [0, 9] |
3,984,677 | 3,984,678 | Help thinking "Pythony" | <p>I'm brand new to Python and trying to learn it by replicating the following C++ function into python</p>
<pre><code>// determines which words in a vector consist of the same letters
// outputs the words with the same letters on the same line
void equivalentWords(vector <string> words, ofstream & outFile) ... | c++ python | [6, 7] |
1,669,476 | 1,669,477 | jquery div hidden and show, how to control show div's position? | <p>I make a easy div hover show and hidden <code>introduce words</code> with jquery. But in the defult code. all the introduce words position is relative. the <code>introduce words</code> div's of <code>box4</code> and <code>box8</code> will out of the <code>div#main</code>.</p>
<p>and how to do? so that the introduce... | javascript jquery | [3, 5] |
5,357,040 | 5,357,041 | Gridview always return a single row | <p>I am using the below code to display some records in gridview with specific filter. If the parent less than 2 means records display in a grid. But it always return a single row but my last datatable dt having more than five rows.How can i solve this error</p>
<pre><code>try
{
DataView dv = new DataView();
d... | c# asp.net | [0, 9] |
3,160,975 | 3,160,976 | jQuery caller ID works in queer way | <p>Hi mega masters of JS and jQuery! I'm somewhat confused by the trick of the "click" function and think that the explanation of the problem is lying in the intricacies of jQuery and JS.</p>
<p>I have a standard binding to a click event</p>
<pre><code>$('.add-button').click( function(event) {
$.ajax({
url: 'su... | javascript jquery | [3, 5] |
263,313 | 263,314 | PHP __call equivalent for java | <p>Is there a Java equivalent for the <a href="http://www.php.net/__call#language.oop5.overloading.methods">__call of PHP</a>?</p>
<p>It would make sense to me if that's not the case, because it would probably result in compiler errors.</p>
<p>From the <a href="http://de3.php.net/manual/en/language.oop5.overloading.p... | java php | [1, 2] |
3,579,666 | 3,579,667 | difference between namespace in C# and package in Java | <p>I'm a Java programmer and I would understand which is the difference in terms of use between the concept of namespace in c# and package in Java. Someone could explain me in a deeper way?</p>
| c# java | [0, 1] |
57,791 | 57,792 | Problem in variable declaration | <p>On page load i am setting the value of String variable <code>DB</code> as follows:</p>
<pre><code>protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
String DB = "";
DB = Session["db"].ToString();
}
}
</code></pre>
<p>I want to use the variable <code>DB</code> (i want to... | c# asp.net | [0, 9] |
6,001,149 | 6,001,150 | jQuery .html() does not select some emails? | <p>Hi I am starting to use jQuery and when I try to select the content inside a div, some emails don't get selected? I'm using Safari's console to execute the jQuery code. I get the desired result with <code>.text()</code> but why doesn't <code>.html()</code> work?</p>
<p><strong>jQuery</strong></p>
<pre><code>$("inp... | javascript jquery | [3, 5] |
1,757,282 | 1,757,283 | Jquery .Change and .load together | <p>I'm hoping to update one text box when another changes using jquery. Here's what I have:</p>
<pre><code>$('#inputs').change(function() {
var first_name=$(".first_name").val();
var last_name=$(".last_name").val();
var username=$(".username").val();
var category=$(".category").val();
if ((!empty(f... | javascript jquery | [3, 5] |
5,587,687 | 5,587,688 | jQuery: Showing a hidden div on page scroll | <p>jQuery</p>
<pre><code>function showDiv() {
if ($(window).scrollTop() > 100) {
$('.lock').fadeIn('slow');
} else {
$('.lock').fadeOut('slow');
});
}
$(window).scroll(showDiv);
showDiv();
</code></pre>
<p>HTML (.lock { display: none; position: fixed; })</p>
<pre><code><div class="l... | javascript jquery | [3, 5] |
1,192,436 | 1,192,437 | How to resize text in a textbox if it is too large till a certain size | <p><a href="https://auth.me.com/authenticate" rel="nofollow"><code>https://auth.me.com/authenticate</code></a></p>
<p>On this website when you type in your email address , the font-size will automatically be reduced if the email address fills the box size. </p>
<p><img src="http://i.stack.imgur.com/5Mjik.png" alt="en... | javascript jquery | [3, 5] |
1,714,008 | 1,714,009 | Why @Override needed in java or android? | <p>In java or Android there are @Override annotations. What does it mean? I found that it is used when method is from subclass or inherited interface's method, I want to know further and other is @SuppressWarnings its also Anonation, if yes how many annonation used by java and for which purpose.</p>
| java android | [1, 4] |
4,620,926 | 4,620,927 | Insert values generated by PHP in a Javascript array | <p>I'm trying to make a list where the user can select 5 items. Those items are generated through PHP. When the user clicks on 1 item that item needs to be saved in an Javascript array. Once the user selected 5 items, those needs to be saved into an mysql database.</p>
<p>Atm I can select items, but the array remains ... | php javascript | [2, 3] |
3,772,208 | 3,772,209 | C# event using jQuery | <p>I need ASP.NET C# button click event to be done by the jQuery. The following sample code taken from my project in which instead of <code>document.write('Passed')</code> I need C# button click even to be done. How it can be done?</p>
<p>Sample code in which button click <code>Button1_Click</code> to be replaced inst... | c# jquery asp.net | [0, 5, 9] |
4,308,693 | 4,308,694 | Can you recommend me an Android Book for a Java developer? | <p>Can anyone of you recommend a good Android book for developer with java background. I have looked at this book i.e. </p>
<p>1-Programming Android by Zigurd Mednieks, Laird Dornin, G. Blake Meike and Masumi Nakamura </p>
| java android | [1, 4] |
1,510,777 | 1,510,778 | How to communicate between C++ and JAVA via Memory-Mapped file without NMI? | <p>I have a C++ COMPILED code which takes two arguments: input file & output file. It's also not possible to pipe input and output. I want to call this program from a Java application.
The only performance-improvement option which comes to mind, is to use memory-mapped files. The task is simple: </p>
<ol>
<li>cre... | java c++ | [1, 6] |
464,632 | 464,633 | How to get mousedown offset relative to an img target element? | <p>I have a <code>mousedown</code> event handler on an <code>img</code> element:</p>
<pre><code>$('#some_image').bind({
mousedown: function(e) {
var img = e.target;
var relpos = ???;
}
})
</code></pre>
<p>How can I get the location of the <code>mousedown</code> <em>relative to</em> <code>img... | javascript jquery | [3, 5] |
5,814,491 | 5,814,492 | Process.Start("url") is not working in proxy environment | <p>How i can pass WebProxy credentials like userid, password, IP,Port and domain. During proxy environment the url does not open.</p>
| c# asp.net | [0, 9] |
2,476,242 | 2,476,243 | How do I use "this" as a part of a selector? | <p>I tried to do it this:</p>
<pre><code>$(this + ' li:not(:nth-last-child(2)):not(:last-child)').hide()
</code></pre>
<p>Full code sample:</p>
<pre><code>$('.comments').each(function(){
$(this + ' li:not(:nth-last-child(2)):not(:last-child)').hide()
var template = $('#expand').html();
$(this).prepend(te... | javascript jquery | [3, 5] |
4,896,880 | 4,896,881 | jquery and/or javascript simplest issue (but can't figure it out) | <p>The following line works i.e. radioClicks function gets called.</p>
<pre><code>$("input:[name='"+54464+"']").bind( "click", radioClicks );
</code></pre>
<p>but this one doesn't:</p>
<pre><code>$("input:[name='"+options.rowId+"']").bind( "click", radioClicks );
</code></pre>
<p>and yes, you have guessed it, opti... | javascript jquery | [3, 5] |
5,982,184 | 5,982,185 | Custom Tab Disappears on Click? | <p>In my Android application I have three tabs in <code>TabHost</code>.</p>
<p>Tab number 2 and 3 loads some data that will take around 4-5 seconds to load. When I click on any of these tabs, the tab disappeared until the data got loaded. Is there any reason for that? How can I handle this disappearing tab ?</p>
<p>O... | java android | [1, 4] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.