jquery

jQuery Validate Plugin: How can I add groups to a validator after its been initialized?

On our site we are using an embedded sign-up form from our ESP that uses the jQuery validate plugin. We are customizing the form a bit, adding a couple of custom fields (first name, last name) and we want them to be grouped so there is only one error message for both the fields. Since the form's validator has already been initialized I ...

jQuery: How do I fade-out a list of less frequently used divs, and fade-in on mouseover?

Say you have a bunch of elements on a webpage you don't use much, how can jQuery fade them a little, but only when there is no mouseover? It must fade back on mouseover! ...

JQuery: How do you change a graphic on a mouse hover event?

Using JQuery, how do I change a map icon whenever I mouse hover over a row in an HTML table/div? Here is an example: http://www.sfsunriseidx.com/homes/94131/?uuid=9ed7269b-5327-4c88-ba15-f700ed343d69&source=REDIR Notice when you mouse hover over a home listing on the left, the corresponding map icon on the right changes. Question...

what is the jQuery / javascript context of a frame within an iframe?

Let me preface this with... I have referenced this question/answers and it seems to contain clues, but i'm still missing the whole picture http://stackoverflow.com/questions/539504/run-jquery-in-the-context-of-another-frame Essentially, the structure of the index page is this <html> <body> <div class="frames-wrap"> <iframe id=...

jQuery: passing value of a select radiobutton

How can I pass the value of the radio button below to the copy_select_val() function? <input type="radio" name="selected_invoice" value="35" onclick="copy_select_val(); return false;"> ...

jQuery selector problem. :last-child not doing what I need

What jQuery selector would allow me to select the last <td> in a <tr> that has more than 1 <td>? NOTE: I am trying to find an answer which will allow me to use a single selector or a selector followed by a .filter() rather than using .each() <table> <tr> <td colspan="2">First Cell</td> <td>Second Cell</td> </tr> <tr> <...

Load and display image as slideshow from the Server directory(folder)

I use .NET C# , I dynamically create folder to store the image I upload, ex: strFolder = Server.MapPath("./folder/folder_"+folid+"/") So I could create different folders according to the page unique id. I have also created a thumbnail image from the image I have upload (cropped ones). The problem I am trying to figure out is to disp...

html gets wiped on dialog call

I am using $(selector).dialog(); to call a tag in my html code. When I click on the link that sends me to this dialog, firebug (a firefox add on) shows that the tag gets erased!! The html code in the tag gets displayed fine the first time, but when the dialog box is closed by the default X in the upper corner, the dialog box won't re...

handle exception into alert box

Hi All, How can I coerce an exception message that has bubbled from my business layer into an alert box in javascript? BTW, I'm using ASP.NET MVC 1.0. Thanks, Rod. ...

Adding Event to YUI Rich Text Editor

Is it possible to add an event to the YUI rich text editor. I am trying to attach a kepress event to the YUI rich text editor module for drupal and am using jquery but am having no luck. ...

onclick form submit, open jQuery loading image until form submit complete

Hi Team, Can you offer a bit of advice. I am using a hosted SAAS CMS solution that enables you to create basing apps with a web apps system. I have created a form for members to submit a bunch of images and content to their own area. Everything is working great except if the images being submitted via the form are large, it takes ages ...

JQuery: Help with $("#div")

I just started using JQuery, as such, I'm cleaning up old code of mine to use JQuery throughout. Question: How would I convert the following code to use JQuery? // enable the other link document.getElementById("asc").setAttribute("href", "#"); document.getElementById("asc").onclick = function() {displayHomeListings("asc")}; document.ge...

JQuery Selectors: Select element with specific class and 'title' attribute

Hi all, This should be an easy one, but I can't find a good example anywhere. I'm trying to select a particular element on my page that has a class of 'statuslight' and a title attribute of one of three options. The option (it will depend) is stored in a variable called 'currentStatus'. I've seen some examples, and I'm guessing this is ...

Jquery find image height not working

I'm trying to use jQuery to find the image height of the first "grand children" of a container, then set the container to that height. But, I can't seem to pull the image height attribute - getting the src works. Any ideas? Is it just trying to pull the heights via CSS? How do i get the "real heights" I can't input the width and hei...

Mutliple file upload with jquery, php array problem

I'm trying to make a multi file uploader. I'm using "Multiple File Upload Magic With Unobtrusive Javascript" None of the files upload. I'm pretty sure this is because it's putting the files into a array and I don't have my php set to handle the array (which I don't know how to do). Any help on what I'm doing wrong? Thanks in advance! :...

Help Me With css() method

So, I am trying to change background of two input fields after the document loads. I use this jquery code: $(document).ready(function() { $('#login').css('background', "url('login-bg.gif') 3em center no-repeat"); $('#password').css('background', "url('password-bg.gif') 3em center no-repeat"); }); I have looked at the code in...

convert some jQuery based code to native javascript, is it possible for this case?

peace folks, I have this small piece of jquery based code, that grabs all tags that has class "foo" and their childs and assign them some value, my question how could i get this working in the same exact way but not using jquery, but native javascript jQuery.each(data.results, function(index, value) { jQuery(".foo").find("*") ...

How to make my code more secure

Hello, I've made a voting on comments like the one this website has(something similar), and I'm slightly concerned about possible http request misuse. You'll know what I mean after I show you the questionable code: $.ajax({ type: 'POST', url: 'http://localhost/comments/vote_down/' + post_id }); Now its still on localhost but it wi...

jQuery autopostback problem

I am working on ASP.NET 3.5 website project and using jQuery to warn users if they modified a page and attempt to leave the page without saving, so doing something like this: var warning = "Please save changes you made."; var isDirty = false; $(document).ready(function() { $('input:text,input:checkbox,input:radio').bind('change...

Using jQuery to iterate across like named checkboxes

Hi folks, I am trying to use jQuery each() to iterate across a group of checkboxes named supplier_type[]. They all have unique ids so I could just re-write this to handle an array of unique ids but I wanted to figure out where I went wrong here. The alert shows that while intIndex sees the correct number of elements this always holds ...