Setting textbox read only property true using javascript
how to set textbox readonly property true or false using javascript....in asp.net ...
how to set textbox readonly property true or false using javascript....in asp.net ...
To check if an element is an array in JavaScript, I have always used Crockford's function (pg 61 of The Good Parts): var is_array = function (value) { return value && typeof value === 'object' && typeof value.length === 'number' && typeof value.splice === 'function' && !(value.propertyIsEnumerable('le...
Possible Duplicate: Javascript === vs == : Does it matter which equal operator I use? Why do I see lots of javascript code lately with expressions that look like this: if(val === "something") Why "===" instead of just "=="? What's the difference? When should I use one or the other? ...
I have a button that closes a modal dialog box on an ASP.NET Ajax form. How do a add a client side function to be called on the same button click? currently firebug has this for the onclick javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions("ctl00$DefaultContent$btnPaymentActionDetailClose", "", true, "", "", false, f...
I'm looking for an open-source javascript solution that would allow me to style a calendar. So far the best I've found has been http://arshaw.com/fullcalendar/ the only problem with this is that it doesn't integrate with multiple Google Calendars. Has anyone seen something that does? ...
I need to implement a flash-based file-uploader, that will allow me to upload multiple files at once and view progress. I tried Uploadify and SwfUpload and it was quite easy getting them to work. However, for both I run into problems, when the users try to upload files, that have filenames with special characters (such as Danish æøå or...
I came across this recently and thought it would make a great SO question. Suppose you are assigning a string to a local variable and you want to vary it by a simple condition. So you insert an inline if statement into the string: var someCondition = true; var url = "beginning-" + (someCondition)?('middle'):('other_middle') + "-end"; ...
I'm looking for some help converting this from prototype to jQuery. I'm doing some free work for a charity and updating a system they use to track and assign volunteers. I've managed to convert everything else so far, however, this has me stumped. Please excuse the spelling mistakes, the code is verbatim what I've been given. I've had ...
Hi, Is there a way for me to find out if the URL in my iframe has been changed, ie, the user has navigated somewhere? Thanks. ...
Hi! Is it possible to have an event that fires when the value of a certain variable changes? Thanks! ...
Hi all, I'm writing a userscript for a website that uses Prototype. Rather than use the GM libs (mainly so I can easily repurpose it for Chrome), I decided to use the already-loaded Prototype functions. I'm iterating through the rows of a table, each signifying a unique user, by checking for an online status element on their profile pa...
Hi, I don't know if what I'm trying to accomplish is possible at all. I would like to override the default behaviour for all the anchor objects ('a' tag) for a given HTML page. I know I can loop through all the 'a' elements and dynamically add an 'onclick' call to each one of them from the body element 'onload' method, but I'm looking f...
I found a method on the internet that can retrieve the Id of a youtube video from the url. this is it. var vid; var results; results = url.match("[\\? vid = ( results === null ) ? url : results[1]; The Id will be contained in "vid". What I don't understand and I find interesting and want to know is this. results = url.match("[\\?...
I have a writeable PDF form made in Acrobat Professional. I want to validate that a numerical entry is in a certain range [a,b]. If it is not, I want an alert to pop up with the message, "Please contact Larry at XXX-XXX-XXXX to get your form processed." Can someone write up a quick snippet of code that does this for a PDF? I know how to ...
I've been trying to learn javascript for 5 years now. I know the basics and can sort of read most javascript that someone else has written but I for some reason still, after 5 years cannot learn this language. My brain just will not let this stuff sink in. I am asked to write javascript from scratch at my new job and they are willing ...
The following code RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, URL.encode("http://localhost:8080/xxxx/yyyy")); try { Request request = builder.sendRequest(null, new RequestCallback() { public void onError(Request request, Throwable exception) { } public void onResponseReceived(Req...
A simplified example: // Let's create a new object function MyObject() { // } // Add some method to this object MyObject.prototype.myFunctionA = function() { // } // Another method MyObject.prototype.myFunctionB = function(arg) { // AJAX GET request $.get('script.php', { par : arg }, function(data) { ...
Is it better to use the RegExp object or the inline style? And why? ...
I'm trying to set a class to active depending on the url. I'm trying to use the code below, but in every case, it activates the active class for the second tab. var pathname = window.location.pathname; if(pathname = '/learn/subsection2') { $("ul.tabs li:eq(1)").addClass("active").show(); //Activate second tab ...
I'm playing now with the Youtube API and I began a small project (for fun). The problem Is that I cant find the way to get Title of a video from the Id. (example: ylLzyHk54Z0) I have looked in the DATA and PLAYER api documentation and I cannot find it. If someone knows how to do this or if someone could help me find the way to do this...