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
3,459,782
3,459,783
add class to regex jquery
<p>I have this</p> <pre><code>if( window.location.href == "http://localhost:3000/categories") { $("#container ul #all_categories a.categories-menu").css("font-weight","bold"); } }); </code></pre> <p>but I have a url with:</p> <pre><code>http://localhost:3000/username/boards </code></pre> <p><strong>user...
javascript jquery
[3, 5]
2,850,378
2,850,379
Returning to previous page
<p>If a user is making an edit and clicks cancel, how can i return them to the page before the edit was made? Not jus refering them back to the previous page, but referring them back to how it was before they decided to edit.</p> <p>If i need to me more thorough please ask.</p> <p>I used this code but it just refers ...
c# asp.net
[0, 9]
376,274
376,275
How to get the date time of client PC in asp.net C#?
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/274826/how-to-get-client-date-and-time-in-asp-net">How to get client date and time in ASP.NET?</a> </p> </blockquote> <p>I have a ASP.NET web application. My hosting server is in USA. Database is present there. ...
c# asp.net
[0, 9]
3,034,650
3,034,651
email data from a form to an email address
<p>I have a very simple form. All i want to do is email the data to an email address. Is there a way I could do that just using JQuery or javascript? Can I do this without php or any other server side language? Is it doable or I am just thinking out loud</p>
javascript jquery
[3, 5]
337,635
337,636
Override Asp.Net Button mutators
<p>I need to trigger an event when Asp.Net button <code>visible</code> property is changed. For this purpose I am using <code>INotifyPropertyChanged</code>. The task remaining is to override getters and setters of button.</p> <p>How do I achieve this?</p>
c# asp.net
[0, 9]
417,274
417,275
Create jQuery Animation Plugin and use Deferred Object
<p>I've created a plugin for jquery. Now i want to implement jquery deferred object to use when, then with my plugin functions. I like to return the query chain with the deferred functionality... It have to work like $.fadeIn() etc.</p> <p>My plugin functions look like these:</p> <pre><code>(function( $ ){ $.fn.img...
javascript jquery
[3, 5]
2,916,821
2,916,822
Element objects vs HTML string
<p>My question is pretty simple, and it may be subjective. For the most part when I am manipulating the DOM, I create HTML text and append it to an element. Sometimes, if the data is small enough, I will create elements and append those to the parent element.</p> <pre><code>$("#p").html("&lt;p&gt;My Paragraph&lt;/p&...
javascript jquery
[3, 5]
1,177,161
1,177,162
Does the surfaceview in android scale to whatever size it needs to be?
<p>If I have a surface view and in that surface view I place a 50x50 image at the coordinates of 0 and 0 and then put that surface view inside of a relative layout and place it at the top left hand corner what will happen? </p> <p>What will happen if I place that surface view at another position?<br> Also, since I am ...
java android
[1, 4]
2,583,512
2,583,513
jQuery listview plugin
<p>Is there any ListView widget plugin for jQuery? With resizable columns, sorting helpers, odd-even rows styles etc. Something like ListView class from Ext library but for jQuery (NOT table/grid).</p> <p><strong>UPDATED</strong> Have switched to ExtJS so question is not topical anymore.</p>
javascript jquery
[3, 5]
3,494,074
3,494,075
Moving an object towards a point android
<p>I have this in the initialization of a bullet object:</p> <pre><code> x = startX; y = startY; double distance = Math.sqrt(((endX - x) ^ 2) + ((endY - y) ^ 2)); speedX = (6 * (endX - x)) / distance; speedY = (6 * (endY - y)) / distance; </code></pre> <p>It goes to where I touch on the screen, but...
java android
[1, 4]
1,727,926
1,727,927
Can i Create the Paging user control for gridview?
<p>Hi please give me idea or reference to create Paging User control.</p> <p>Thank You very much in advance.</p>
c# asp.net
[0, 9]
30,433
30,434
How do you configure SWFUpload to work with an ASP.NET C# WebService?
<p>I'm trying to use SWFUpload with an ASP.NET Web Forms project. I need to get at Request.Files[0] But I can't do that in my WebService! </p> <p>Anyone know a way around this?</p> <p>Thanks in advance.</p>
c# asp.net
[0, 9]
2,820,478
2,820,479
Falling through a switch case?
<p>I was in the process of writing a switch case when I read on the PHP site: </p> <p><code>Thus, it is important not to forget break statements (even though you may want to avoid supplying them on purpose under certain circumstances).</code></p> <p>A switch case without break statements was perfect for what I wanted...
php javascript
[2, 3]
4,435,414
4,435,415
How can I include a javascript file using php echo?
<p>How can I include a javascript file using php echo ?</p> <p>I am creating a html page using php ---</p> <pre><code>echo "&lt;html&gt;&lt;head&gt;&lt;link rel='stylesheet' type='text/css' &lt;script src="Calculation.js"&gt; &lt;/script&gt; href='style.css' &lt;/head&gt;&lt;body&gt;"; </code></pre> <p>I have inclu...
php javascript
[2, 3]
4,249,626
4,249,627
C# DateTimeKind.Local in JavaScript
<p>I just want to know that what is equivalent of C# DateTimeKind.Local in JavaScript and how can I set it in JavaScript</p>
c# javascript
[0, 3]
3,496,480
3,496,481
Python-spidermonkey: How to get a line num. of error
<p>How to retrieve the line number in which a error occured?</p> <p>In the next script the line outputs (as the result of the last <strong>raise</strong>) but there is no line num. in JSError object.</p> <pre><code>from spidermonkey import Runtime, JSError runtime = Runtime() context = runtime.new_context() try: ...
javascript python
[3, 7]
5,099,296
5,099,297
Different Chart Axis Values
<p>I am creating a StepLine chart in ASP.NET and C#. Chart works great and shows what I want, but I want to be able to show X Axis Values at the top as well as the bottom. Now the issue is that I want it to show values for one of my data points at the top and different values for a second data point down the bottom. ...
c# asp.net
[0, 9]
4,189,566
4,189,567
remove/restore elements, maintaining their events and element's children
<p>I came to a situation where I need to edit the following in a way that, on some event (lets assume the 'click' event in this case) I need to remove (or unwrap?) the <code>.container</code> and the <code>.header</code> and have the <code>.itemlist</code> still visible/available on the page. And then, I need to restor...
javascript jquery
[3, 5]
2,722,736
2,722,737
ToolTip on button click
<p>I need to show a tooltip onClick (Instead of hover) and it should fade out after 200ms </p> <p>Any help ? </p>
javascript jquery
[3, 5]
5,450,833
5,450,834
FancyUpload timeout issue?
<p>I am using FancyUpload with asp.net page.</p> <p>It is working fine but when I try to upload a little heavy file say 5 MB it shows timeout error. Can u please guide where time limit can be increased or what else I should do to fix this issue ?</p>
javascript jquery asp.net
[3, 5, 9]
3,982,100
3,982,101
Finding the td associated to its table onclick event
<p>I have a table like below</p> <pre><code>&lt;table onclick="dosomething()"&gt; &lt;tr&gt;&lt;td&gt;11&lt;/td&gt;&lt;td&gt;12&lt;/td&gt;&lt;td&gt;13&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt;&lt;td&gt;11&lt;/td&gt;&lt;td&gt;12&lt;/td&gt;&lt;td&gt;13&lt;/td&gt;&lt;/tr&gt; &lt;tr&gt;&lt;td&gt;11&lt;/td&gt;&lt;td&gt;12&lt;/td&gt...
javascript jquery
[3, 5]
85,028
85,029
jquery.countdown.js giving really off results.
<p>I am really pressed for time so I am going to ask on here. The time of writing this is 2012-10-06. I am trying use a a jquery plugin called /jquery.countdown.js". It seems pretty straight forward. Can Anyone see what I am doing wrong? I am just trying test a countdown till tomorrow.</p> <pre><code> &lt;scr...
javascript jquery
[3, 5]
2,677,511
2,677,512
Jquery: slideToggle() multiple divs independently using one function
<p>Markup:</p> <pre><code>&lt;div&gt; &lt;h3 class = "trigger"&gt;Heading 1&lt;/h3&gt; &lt;ul class = "toggle"&gt; &lt;li&gt;Line One&lt;/li&gt; &lt;li&gt;Line Two&lt;/li&gt; &lt;li&gt;Line Three&lt;/li&gt; &lt;/ul&gt; &lt;/div&gt; &lt;div&gt; &lt;h3 class = "trigger"&gt;Heading...
javascript jquery
[3, 5]
375,074
375,075
@Override in Android
<p>I am new to Java and Android programing. The issue that I am having is that after surfing several books, forum and websites, I do not have clear understanding of what the @overide annotation does. I understand it signifies when a meathod is being over ridden. but why is it needed in android. I see it rarely in sourc...
java android
[1, 4]
2,271,990
2,271,991
Using list of serialized objects
<p>I'm learning Android/Java programming, but I'm confused about persistant data. After a lot of research it seems that the best way to store objects is to serialize them in a file, but I couldn't find a simple way to retrieve these objects.</p> <p>If I create two objects and save their serialized versions, how can I ...
java android
[1, 4]
5,695,197
5,695,198
jscript/jquery: fade in divs 1 by 1, with pause inbetween
<p>I am totally stumped here.</p> <p>I have a bunch of messages, each within a div "msg_feed_frame_$i" which increases, so message 1 is in div "msg_feed_frame_1", msg 2 is in "msg_feed_frame_2", etc etc. I want to fade these messages in one by one using jquery, but for some reason no matter what I do with settimeout a...
javascript jquery
[3, 5]
3,911,532
3,911,533
Retrieving scalar data using .xsd dataset object?
<p>Can someone suggest the best way to retrieve a scalar value when the site uses .xsd files for the data sets? I have such site where before I commit to a insert task I need to verify duplicates. </p> <p>Back in the day one would just instantiate a new connection and command object and run the query through BLL/DAL -...
c# asp.net
[0, 9]
514,712
514,713
noob question about function ()
<p>I am not sure about this code. This structure is correct?</p> <pre><code> success: function(data, data1, data3, .... ) { switch (data.livre) { case 'x': break; } switch (data1.livre1) { case...
javascript jquery
[3, 5]
620,058
620,059
How do I combine the best of two Apps into one?
<p>I have two similar iPhone and Android Apps (2 each) in the near future we will be combining/merging the best of these two Apps into one App. The App does have a user login that would need to be combined, but a common data file, so authentication should not be an issue. How do I deploy the combined App via the App St...
iphone android
[8, 4]
5,692,154
5,692,155
Render C# class as javascript
<p>I'm looking for a way to render a C# class object to javascript. For instance this class definition:</p> <pre><code>public class Foo { public string Bar1 { get; set; } public string Bar2 { get; set; } } </code></pre> <p>should render (an object of class Foo with values filled) as:</p> <pre><code>foo: { ...
c# javascript
[0, 3]
3,284,426
3,284,427
.show() not showing HTML element
<p>Here the problem: the layer gets sucessfully hidden, but when I click the button again, it won't re-appear. Any ideas?</p> <pre><code>&lt;head&gt; ... &lt;script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"&gt; &lt;/script&gt; &lt;script type...
javascript jquery
[3, 5]
1,257,911
1,257,912
on doing bulk process in window service got stucked up by throwing this memory exception error
<p>my window service will generate some text files and it will be placed in some mentioned folder on during process suddenly service gets stop and thrown this error</p> <p><strong>Error Text :Exception of type 'System.OutOfMemoryException' was thrown.</strong></p> <p>how to come out off this issue ...</p> <p>NOTE...
c# asp.net
[0, 9]
2,733,309
2,733,310
Color Dodge Blend Bitmap
<p>I have two bitmaps topBitmap and bottomBitmap and I need to blend the two bitmaps using color dodge in android. I could not find color dodge in PorterDuffXfermode. Is there any way to do it with ot without the use of a Canvas? </p> <p>Kindly let me know how to blend two bitmaps using color dodge mode in android.Tha...
java android
[1, 4]
1,133,421
1,133,422
Ajax request cross domain json data and display?
<p>I have a function to get JSON data from another domain, but I don't know what is wrong with it. It never fires the success function and and no errors are returned.</p> <pre><code>$.ajax({ url: "http://other-domain.com/sample/Json.aspx", dataType: "jsonp", type: 'get', crossDomain: true, jsonp: '...
javascript jquery
[3, 5]
4,840,963
4,840,964
Search function to add & remove options from select dropdown
<p>Here is my crazy code:</p> <pre><code>t.config.searchSpanInput.keyup(function () { var searchCriteria = t.config.searchSpanInput.val(); $.each (t.config.promoInput, function (i, v) { $.each ($(v + " option"), function (j, v) { if (optObj[i][j].text().toLowerCase().indexOf(searchCriteria...
javascript jquery
[3, 5]
3,686,834
3,686,835
JQuery frontend with Java and C# backends: design choices
<p>I have to build a multibrowser web app which should be able to be installed in both Windows and Linux servers.</p> <p>I've thought of using a single client-side frontend built with JQuery, and two different backends, built with java and c# respectively. The client then would use ajax calls with json to communicate ...
c# java jquery
[0, 1, 5]
1,228,229
1,228,230
sending parameters from ASP.NET to javascript
<p>I want to call a javascript function from my ASP.NET (C#) code, I want to pass a variable (string) with another string like below:</p> <pre><code>tag_label.Attributes.Add("onmouseover", "tooltip.show('my text'+'"+myString+"'&lt;br/&gt;'another text);"); </code></pre> <p>how should I pass these values? also I want ...
javascript asp.net
[3, 9]
3,810,279
3,810,280
jQuery Plugin: Limiting script tag references to other libraries
<p>I am about to create a jQuery plugin but I was thinking of using a few other libraries. Now for it to be easy to use I was wondering if there are ways to limited the amount of script tag references I have to add. </p> <p>Few options I was considering:</p> <p>1: Include the library code into the plugin code. Not su...
javascript jquery
[3, 5]
1,396,190
1,396,191
How to fix this jQuery Scope mistake?
<p>Something I'm not able to figure out in this code, I think it's a scoping issue.</p> <p>I have the following javascript snippet</p> <pre><code>&lt;javascript language="javascript&gt; $(function() { $("#dialog").dialog({ autoOpen: false }); function getMessage(direction, msg...
javascript jquery
[3, 5]
5,023,612
5,023,613
Count elements that the id begins with a certain string
<blockquote> <p><strong>Possible Duplicate:</strong><br> <a href="http://stackoverflow.com/questions/897025/jquery-return-elements-where-id-begins-with-a-certain-string">jQuery Return elements where ID begins with a certain string</a> </p> </blockquote> <p>Ok, let's say I have the following elements:</p> <pre>...
javascript jquery
[3, 5]
4,031,362
4,031,363
calll click event of a button of aspx page from usercontrol
<p>i have a button in an usercontrol.</p> <pre><code> &lt;asp:Button ID="btnCompare" CssClass="new_btn" runat="server" Text="Compare" /&gt; </code></pre> <p>i need to call a click event of a button which is in another aspx page on "btnCompare" button click.</p> <p>is it possible ?</p>
javascript asp.net
[3, 9]
477,980
477,981
How to raise the button command event from JavaScript ?
<p>How can we fire the button command event from the JavaScript.</p> <p>Not the BUTTON onclick event.</p>
c# javascript jquery asp.net
[0, 3, 5, 9]
3,135,318
3,135,319
System.Web.HttpException: This is an invalid script resource request
<p>I get this error when pushing our website to our clients production server however the page works absolutely fine on their dev / test servers. What causes this error (considering I am not using any web resources myself, though I am using the asp.net ajax toolkit).</p>
c# asp.net
[0, 9]
4,724,366
4,724,367
remove php tags from a string with python
<p>I want to remove php tags from a string </p> <pre><code>content = re.sub('&lt;\?php(.*)\?&gt;', '', content) </code></pre> <p>seems to work OK on single line php tags but when a php tag closes some lines after , it cannot catch it. can anybody help?</p>
php python
[2, 7]
4,988,095
4,988,096
set intervals between per click
<p>I have a working adding/removing numbers that I just created for showing the number of current page attached to the content slider which is not a feature of the slider ( please take a look <a href="http://sneakyrascal.com/coupon2" rel="nofollow">http://sneakyrascal.com/coupon2</a> )</p> <p>slider changes each conte...
javascript jquery
[3, 5]
4,673,726
4,673,727
Javascript Equating Varaible .value
<p>This is the code im working from: <a href="http://jsfiddle.net/9B84H/26/" rel="nofollow">http://jsfiddle.net/9B84H/26/</a></p> <pre><code>function autosuggest() { var input = document.getElementById('location'); var options = {types: [],}; var autocomplete = new google.maps.places.Autocomplete(input, option...
javascript jquery
[3, 5]
3,813,927
3,813,928
ASP.NET Custom authentication handler
<p>We have a web app written by a third party in ASP.NET, we don't have access to the source code but do have access to the server it runs on. We now have had a new public website developed for us in PHP and need to add a login to the homepage that will allow users to access out ASP>NET app. Any ideas on the best way t...
php asp.net
[2, 9]
1,145,386
1,145,387
passing array via query string
<p>I am passing a javascript array via <code>Request.QueryString["cityID"].ToString()</code>, but it shows me an error of "invalid arguments":</p> <pre><code>blObj.addOfficeOnlyDiffrent(Request.QueryString["cityID"].ToString(), Request.QueryString["selectTxtOfficeAr"].ToString()); </code><...
c# asp.net
[0, 9]
2,298,482
2,298,483
Is there any api which give suggestion words?
<p>I want to ask is there any api which return list of suggestions of words on giving input in any text control in any platform.</p> <p>For example when we type in EditText in android through soft keyboard , keyboard returns some suggestions so my question is that is there any api which gives the suggestions of corr...
iphone android
[8, 4]
5,962,183
5,962,184
Dip to pixel conversion results in the exact same value
<p>I am trying to convert dips to pixels using the following function. I’ve tried low, medium, and high density emulators and regardless of the emulator I use, the pixel value remains the same value as the dip value I pass into the function.</p> <pre><code>private int ConvertDips(float dips) { int pixels = (int) Typ...
java android
[1, 4]
3,377,578
3,377,579
Create my own "URL Manager"
<p>I'm writing a http API, and I need a bit more flexibility than I'm used to in asp.net. It's pretty simple problem I have, and just need some help getting on the right track.</p> <p>My problem is, that I want to create a response object based on the request. F.x a user can get a xml document when requesting: "myapi/...
c# asp.net
[0, 9]
3,625,436
3,625,437
asp.net auto generated textboxes ID on webform
<p>I am using <strong>C#</strong> on <strong>Visual Studio</strong>. I want to generate a <strong>webform</strong> with auto numbered <code>Textboxes</code> depending on the input from the previous page. What is the best way to do this loop?</p> <p>For example:</p> <p>Input is 4</p> <p>The next page should generate ...
c# asp.net
[0, 9]
620,022
620,023
Jquery-Image-Gallery-issue
<p>I am trying to create a jquery image gallery but I am facing a problem in next and prev and I should follow the structure which i am using in fiddle demo. Initially I need to show two images on click of next the other images/video should visible</p> <p>Here it is what I have tried.</p> <p>I should not use any plug...
javascript jquery
[3, 5]
2,350,451
2,350,452
Android Toast.makeText() not showing up
<p>When the user presses a button, I'd like a small <code>Toast.makeText()</code> message show up saying something like <code>Contacting server...</code> while the app gets some information from my web server.</p> <p>The problem is that Java's HttpClient.Execute() method is synchronous, so it blocks the Toast from sho...
java android
[1, 4]
3,308,632
3,308,633
Login is not working
<p>I have written the code below for a login page, but doesn't seem to work.<br> The variable <code>temp</code> takes a value of <code>0</code>.</p> <pre><code>protected void ButtonSbmt_Click(object sender, EventArgs e) { //if (IsPostBack) { SqlConnection conn = new SqlConnection(ConfigurationManager.Connectio...
c# asp.net
[0, 9]
1,142,830
1,142,831
fileupload path is missing
<p>I am using a file upload control to upload the files if the user browse and upload the file. after uploading the path gets disappears. i should be maintain there itself. how?</p>
c# asp.net
[0, 9]
3,142,486
3,142,487
Selecting an element by a class using javascript or jQuery
<p>I have the following html snippit;</p> <pre><code>&lt;input name='first' class="foo" /&gt; &lt;input name='second' class="foo bar" /&gt; &lt;input name='third' class="foo" /&gt; </code></pre> <p>I want to set the value of a specific element, but i'm unable to select the right one. This is whar i've tried:</p> <pr...
javascript jquery
[3, 5]
5,853,794
5,853,795
document.selection.createRange() not working in chrome and safari
<p>I am using a textbox with textmode as multiline option its working fine in IE,Mozilla problem occurs in Chrome and safari. Sample code folows</p> <pre><code>&lt;asp:TextBox ID="txtRootDescription" onpaste="DoPaste(this);" Width="600px" Rows="10" Columns="72" MaxLength="500" TextMode="MultiLine" runat="server"&gt;&l...
c# javascript asp.net
[0, 3, 9]
3,607,666
3,607,667
how to remove first two segments of a url string in java?
<p>if I have a url string like "http://www.google.com" how can I convert that to just "google.com" in java? Im assuming there is a way to parse this using a function in java, any help will go a long way thanks!</p>
java android
[1, 4]
5,296,390
5,296,391
how to get the asp.net drop down list items in javascript
<p>I have one dropdownlist in my c# code behind page like `DropDownList dl = new DropDownList(); dl.Items.Add("Item 2");</p> <pre><code> dl.Items.FindByText("Item 2").Value="2"; dl.Items.Add("Item 3"); dl.Items.FindByText("Item 3").Value="3";` </code></pre> <p>I like to get that...
c# asp.net
[0, 9]
5,837,811
5,837,812
Change the background of all the activities in the app
<p>I'm trying to define a background as default for all the activities in the app. So I have used:</p> <pre><code>&lt;style name="testStyle" parent="@android:style/Theme.NoTitleBar"&gt; &lt;item name="android:background"&gt;@color/app_background_color&lt;/item&gt; &lt;/style&gt; </code></pre> <p>and then in the m...
java android
[1, 4]
423,123
423,124
How do I remove a clickable link from asp:Gridview column?
<p>I want to remove a clickable link from asp:Gridview column when some condition is true.</p> <p>I tried this:</p> <pre><code>Gridview.attributes["disabled"] = "disabled"; </code></pre> <p>But the hyperlink is still clickable. I don't want clickable hyperlinks when the grid is disabled. How can I do it in C#.net?</...
c# asp.net
[0, 9]
3,663,941
3,663,942
How to read a text file from the last line to the first
<p>I need this to run in reverse so that the lines appear in the reverse order of this. Is there a quick way to flip a TextView or something like that? Thanks for any help.</p> <pre><code>try { // Create a URL for the desired page URL url = new URL("text.txt"); // Read all the text returned by the server BufferedRe...
java android
[1, 4]
5,173,831
5,173,832
Java Android No more background processes
<p>I want to understand some things that take place in JAVA application while application is loading. First of all then I launch my application it start to load more then 180MB of libraries to the RAM of the phone and I can see </p> <blockquote> <p>12-12 19:05:05.478: DEBUG/dalvikvm(12579): GC_EXPLICIT freed 53K, 48...
java android
[1, 4]
3,026,109
3,026,110
How to give user defined validation in asp.net?
<p>I have a grid to which there are edit/delete/insert buttons, there is a column in the grid say SR_NO ,the user can simply add a number in this field and append/edit to the grid.</p> <p>but the thing is I want to validate this field such that there is no other entry in the entire SR_NO column having same SR_NO,how ...
c# asp.net
[0, 9]
3,857,057
3,857,058
JavaScript 'beforeunload' event not working in ie
<p>I need to open a pop-out window, then after close pop-out window (refresh a parent page)</p> <p>jquery 'beforeunload' event not working in internet explorer 8,9.</p> <p>my code is:</p> <pre><code> /* * events * add tallyman */ $("div.main form div.tallymanlist").click(function() { if(gencargo.show_con...
javascript jquery
[3, 5]
909,271
909,272
Calculating degrees for bouncing ball
<p>I'm doing a simple breakout game and I have some problem how to calculate the angle when the ball hit the top border. When the ball moves upwards in an angle of 180 degrees, then it bouncing back downwards in an angle of 0 degrees. But when the ball is moving upwards in an angle of 170 degrees, then it should be bou...
java android
[1, 4]
1,638,999
1,639,000
make jquery use min-height not just height
<p>The code:</p> <pre><code>function setEqualHeight(columns) { var tallestcolumn = 0; columns.each( function() { currentHeight = $(this).height(); if(currentHeight &gt; tallestcolumn) { tallestcolumn = currentHeight; } } ); if (tallestcolumn &lt;= 1000) { columns.height(tallestcolumn + 4); } } $(docum...
javascript jquery
[3, 5]
5,934,004
5,934,005
how to save a file at the server in asp.net?
<p>i have a log file which needs to be written to the server . If i had the code in a code behind file for a web form i would have done this </p> <pre><code>File.WriteAllText(Server.MapPath("/ErrorLogFile/ErrorLogFile.log"),json); </code></pre> <p>Now, since my code sits inside the App_Code folder i have no access to...
c# asp.net
[0, 9]
4,112,314
4,112,315
How to write a file in Android to the raw folder?
<p>I think this is a pretty basic question. </p> <p>I am currently writing a file like this:</p> <pre><code>File output = new File("exampleout.mid"); </code></pre> <p>Now, I want to write the file to ../myproject/res/raw</p> <p>I read I could do it by putting the complete url in the "". BUT. Since this is an Androi...
java android
[1, 4]
3,960,562
3,960,563
How to unload C++ DLL in C#
<p>I load a C++ DLL using DLLImport in my C# ASP.Net web application. The DLL basically reads some CSV files, and manipulates them and creates new files.</p> <p>After I ran the method successfully, and run it again then I get C++ exception back. </p> <p>I want to unload the C++ DLL from the website so a user can re-...
c# asp.net c++
[0, 9, 6]
1,711,934
1,711,935
Why invalidate must be called by UI thread
<p>Anyone know why <a href="http://developer.android.com/reference/android/view/View.html#invalidate%28%29" rel="nofollow">invalidate</a> must be called by UI thread? </p> <p>As in Java Swing, the <code>repaint</code> function can be called by both non-UI thread and UI thread. <code>repaint</code> is performing a very...
java android
[1, 4]
1,010,033
1,010,034
Cannot crop Bitmap
<p>I'm trying to crop and scale given bitmap,But only scaling works.<br> What am I doing wrong?</p> <pre><code>private Bitmap CropAndShrinkBitmap(Bitmap io_BitmapFromFile, int i_NewWidth, int i_NewHeight) { int cuttingOffset = 0; int currentWidth = i_BitmapFromFile.getWidth(); int currentHeight = i_Bitmap...
java android
[1, 4]
559,277
559,278
Passing Eval from ASPX to Javascript function as Parameter
<pre><code>&lt;a id="lblShowTimings" runat="server" title='&lt;%# Eval("SHOW_Name") %&gt;' onclick='PopulateTicketDiv(&lt;%#Eval("SHOW_ID") %&gt;)'&gt; &lt;-- this is the problem %#Eval("SHOW_Time") %&gt; &lt;/a&gt; </code></pre> <p>Can Eval be passed as an argument to a javascript function? If so wh...
c# asp.net javascript
[0, 9, 3]
1,070,592
1,070,593
Java math conversion
<p>I have this code in C++</p> <pre><code>float result = -log(result)/0.5231-1.0; </code></pre> <p>And I converted that into Java code like this</p> <pre><code>float result = (float) (-Math.log(result)/0.5231-1.0); </code></pre> <p>Is this correct way to convert the c++ code?</p>
java c++
[1, 6]
757,982
757,983
Handler to grab variable values from another function
<p>This is what I have so far </p> <pre><code>//file uploader /////////////////////////// function uploader(){ var file = $(this).val() var error = $(this).next('.req-error') var fileLimit = $(this).attr('maxlength')-1 var uploadedFiles = $(this).siblings('.uploaded-file').length //make uploaded...
javascript jquery
[3, 5]
1,102,531
1,102,532
Binding javascript to new rows
<p>I have a simple table which has a some information displayed. To view the details of that row i have a javascript function:</p> <pre><code>$('#production tr').bind("click", function(){ reviewProductionOrder(this); }); </code></pre> <p>This lets me select the row and display information appropriately. However i...
javascript jquery
[3, 5]
1,060,874
1,060,875
How to add opacity to a div?
<p>I am trying to add opacity to a div.</p> <p>Here is my Jquery:</p> <pre><code>$('.redDiv').fadeIn(0, 0.5); </code></pre> <p>My HTML:</p> <pre><code>&lt;div class="redDiv" style="background:red;width:20px;height:20px;"&gt; &lt;/div&gt; &lt;div class="divBlue;" style="background:blue;width:20px;height:20px;"&gt; &...
javascript jquery
[3, 5]
4,637,467
4,637,468
jquery search each table row for a particular td
<p>Consider there's a table with rows to which a <code>td</code> with class <code>x</code> is added by jqeury on the fly (during DOM manipulation). Later when the user sumbit's this table (table being part of a form), i want to search all the rows for existence of this particular <code>td</code>. If this <code>td</code...
javascript jquery
[3, 5]
4,900,791
4,900,792
DetailsView when DECODE data
<p>Hi I have a DetailsView control that should display data from a DataBase. This data it is Encoded.</p> <p>Which is the best way to DECODE this data before visualize the result in the DetailsView.</p> <p>DataBound event handler? DataBinging Event Handler?</p> <p>Could you give me an example of code. </p> <p>Thank...
c# asp.net
[0, 9]
4,649,446
4,649,447
jquery attribute selector problem: Dynamic attribute selector
<p>My code is here</p> <pre><code>$("a[href=$.jqURL.url()]").hide(); </code></pre> <p><code>$.jqURL.url()</code> return current page url. </p> <p>But this code don't work</p> <p>Is it possible to select dynamically?</p>
javascript jquery
[3, 5]
2,996,562
2,996,563
php javascript form validation for upload file <input>
<p>want to get a validation script to validate the file upload box onsubmit.</p> <p>check the extension of the file and validate accordingly to the extension of file loaded</p>
php javascript
[2, 3]
3,710,067
3,710,068
How to Move up and down in ASP.NET Gridview Using Arrow Keys
<p>I Have A Grid view control in that grid view controls ItemTemplate i have taken textboxes now i want to do is that on pressing down arrow key the cursor which is in first textbox of first row will go to the first textbox of second row</p> <p>This is the Grid view which i want to do the up down </p>
javascript asp.net
[3, 9]
5,792,541
5,792,542
Is there a way to randomly apply css properties from a list to a bunch of elements?
<p>More exactly could i apply to my 20 divs, 10 background-images that i have, so there are two elements with same background?<br> I want to reproduce a game and i didn't start beacause i don't know if it's possible. I have 20 cards faced upside down. When i click one they flip and show their image. But they are in pai...
javascript jquery
[3, 5]
3,753,533
3,753,534
how to read twice a file using fileupload
<p>I am trying to read the same file twice.</p> <p>I have been using a <code>FileUpload</code> to look up the file. I was successful in the first read where I find out how many lines the file have, using the next code in C# ans asp.net:</p> <pre><code>Stream data_file; data_file=FileUpload1.PostedFile.InputStream; st...
c# asp.net
[0, 9]
522,027
522,028
Java -> Python?
<p>Besides the dynamic nature of Python (and the syntax), what are some of the major features of the Python language that Java doesn't have, and vice versa?</p>
java python
[1, 7]
1,037,304
1,037,305
Need to loop through two loops and use delayed iterations in the inner loop
<p>What I'm trying to do is build a way to loop through two <code>for</code> loops, but the inner loop needs to have a delay on each iteration, but it can't be a queued animation. </p> <p>The way I'd like for this to work is, on start it would trigger each of the elements at an interval but not wait for their animatio...
javascript jquery
[3, 5]
5,669,656
5,669,657
JQuery Detecting Hover on Flash Object
<p>I am having problem with the following JQuery code:</p> <pre><code>$("object").hover(function(e){ alert('Flash Here'); }); </code></pre> <p>I just want jquery to detect if I hover on top of the flash object.</p> <p>Here is the flash embed code:</p> <pre><code>&lt;object classid="clsid:D27CDB6E-AE6D-11CF-96B8-...
javascript jquery
[3, 5]
1,751,523
1,751,524
Why is my PHP variable not changing when my Javascript code runs?
<p>I have a counter timer and I tried to block a simple bypass to download without waiting.</p> <p>so in main class I declared the boolean</p> <pre><code>$allow_download = false; </code></pre> <p>and in <strong>Javascript</strong> when the time is elapsed </p> <pre><code>else { textDLShow.style.display = 'none...
php javascript
[2, 3]
6,028,300
6,028,301
ListView exception for Images + Text
<p>I am trying to create a simple Icon+Text ListView but it does not work. I am using 2.1 Android SDK.</p> <p>My main class is very small slightly modified from the tutorial:</p> <pre><code>public class Stuffs extends ListActivity { static final String[] COUNTRIES = new String[] {"A", "B","C"}; /** Called wh...
java android
[1, 4]
5,486,921
5,486,922
Image Zoom effect using Cloud Zoom jQuery plugin
<p>I am trying to apply cloud zoom on a single image as in the below Fiddle </p> <p><a href="http://jsfiddle.net/7HDbz/" rel="nofollow">http://jsfiddle.net/7HDbz/</a></p> <p>But it does not seems to be working. Someone have a look at this. Here is another fiddle with working effects </p> <p><a href="http://jsfiddle....
javascript jquery
[3, 5]
1,922,979
1,922,980
Intercept Sent text messages android
<p>I'm creating a Text Encryption app, but I don't want to make a whole new text app, I just want it to handle the encryption/decryption. So I was wondering, is there a way I can somehow intercept text messages sent from an app, encrypt it, and then send it?</p> <p>I know I can get the received messages, that's the ea...
java android
[1, 4]
1,642,859
1,642,860
Get all values of array elements
<p>I have an array with HTML elements from a selector. Looks like this:</p> <pre><code>var selection = $('.features_items'); // selection = [div.features_item, div.features_item]; </code></pre> <p>The div looks like this:</p> <pre><code>&lt;div class="features_item selected" value="2"&gt; </code></pre> <p>Now I wan...
javascript jquery
[3, 5]
2,118,306
2,118,307
Converting a javascript function to pass in an object
<p>I have this javascript which is working great - </p> <pre><code>var employeename = $("#employeename"); var employeenameInfo = $("#employeenameInfo"); employeename.blur(validateEmployeename); function validateEmployeename(){ //if it's NOT valid if(employeename.val().length &lt; 4){ employeename.addC...
javascript jquery
[3, 5]
215,493
215,494
jQuery calculation inside loop
<p>How can i make a loop and add some values for the next iteration together like these in jQuery ?</p> <pre><code>var currLength = length; for (var i = 1; i &lt; dotCount -1; i++) { $("#myElement" + i).css("width", currLength); currLength += length + margin; } </code></pre> <p><strong>Edit: These is just an exam...
javascript jquery
[3, 5]
5,105,398
5,105,399
how to create a dynamic variable in android
<p>I am creating a card game (blackJack) in android. the first two cards are easy card1 and card2, however i want to press a Hit me button and deal a new card and assign it to card3, card4 etc is there any way to do this without essentially creating the maximum number of variables you would need and using if then stat...
java android
[1, 4]
3,995,801
3,995,802
Handling double quotes in mailto:
<p>I am working on Visual Studio 2008 and ASP.net.. I want to preview email that is created in the web page. I have problems in handling double quotes in the email body. </p> <pre><code>string emailbody = "\"some text\""; btPreviewEmail.OnClientClick = "javascript:location.href='mailto:?subject=Chalk Pushcast Softwar...
javascript asp.net
[3, 9]
4,480,737
4,480,738
jQuery accordion header
<p>I want to add some toolbar icons in header of accordion but when i add onclick event handler is in header also nad its toggling accordion. How can i define toggle accordion only for part of header. Header property does not help because then it minimizes the width of accordion depending of the header width ?</p>
javascript jquery
[3, 5]
3,434,201
3,434,202
C# DateTime.Ticks equivalent in Java
<p>What is the Java equivalent of DateTime.Ticks in C#?</p> <pre><code>DateTime dt = new DateTime(2010, 9, 14, 0, 0, 0); Console.WriteLine("Ticks: {0}", dt.Ticks); </code></pre> <p>What will be the equivalent of above mentioned code in Java?</p>
c# java
[0, 1]
3,610,569
3,610,570
retrieve window.location.hash url in php
<p>I am using a jquery tabbed interface here <a href="http://www.imashdigital.com/#2" rel="nofollow">http://www.imashdigital.com/#2</a> and would like to return the tab number in php.</p> <p>Ideally I would like to run a javascript function (on a timer) that continually updates a global <strong>php variable</strong> w...
php javascript jquery
[2, 3, 5]