jquery

jquery extend - array of objects

Say I have a Form object which has an array of Tab objects. var Tab = function (options) { return ($jQuery.extend(true, { id: 'foo', title: 'Foo' }, options)); } var Form = function (options) { return ($jQuery.extend(true, { id: 'foo', tabs: [new Tab()] }, options)); } I can use this: ...

jquery form submission

Can someone show me a tutorial of using jquery to display successful form submission without refreshing the page. Something like that happens on gmail when a message is delivered and the yellow overlay that shows that you message was delivered and then fade outs. ...

Writing image animation (swap images) with jQuery

I'm trying to arbitrarily animate images using jQuery and a timer (http://jquery.offput.ca/every/ works as the timer) so as to simulate an animated GIF but allow the animation to be defined within the HTML file (or in a script at the top of the page for repeated use of the same "animated" image). I've written a specific version in whic...

jQuery getJson() not working with in ASP.NET MVC

I want to use jQuery to make a simple call to my MVC controller. I was able to debug the server side, meaning the controller picked up the ajax call and return the information requested. But the client side is never updated after server side returns. When I use FireBug to debug the script, the client side is stuck on event.isImmediatePro...

Dynamic Google Direction problem

In my site I am trying to generate dynamic google map direction. The destination is dynamic. All I am doing is: Here, {$map_code} is generated by me. This works fine. I am trying this above code to be appeared by jquery ajax within a div. where the locations are generated and also the script code. but problem is that, when ajax is wri...

Least code to create modals in jQuery dynamically based on rows in an HTML table

I've got an HTML table with columns that hold a few words of a comment that when clicked should show a modal dialogue with the full contents of the comment (stored in a DIV on the page). I was going to do this with a jQuery dialog, but can't decide if it's more efficient to put onclick handlers (with this.next.show..) on each cell or to...

Clip content from remote website using javascript and Iframe ??

Is there any helper for Iframe in Rails ?? *EDIT:*I have a link which redirects to a remote website , i need to get the COntent from that website and store in my application is this possible , I dont need a browser extension or plugin. ...

using "if"'s in jQuery tmpl

Is it possible to create if sentences inside a jQuery tmpl template? <script id="template" type="text/html"> <h1>${someVar}</h1> if (${intro}!="") <small>${intro}</small> endif <p>${restOfVariables}</p> </script> Now, this would only write out the if as text, so is there any way to do something like this? Or wo...

Use asp.net AJAX from javascript

This is probably a simple question. I use ASP.NET ajax toolkit and Jquery. I want to call a server-side function/method from Javascript and have it update a control. Can i do this? Client-side send_request(foobar,args); Server-side private void foorbar(){ Label1.Text = "updated"; } ...

jquery checkbox properties

In the below code how to get the checkboxes that are selected only and remove it from the list using jquery and populate the removed html in the div <div id="section_val"> <input type="checkbox" name="a_d" value="1">a_d</input> <input type="checkbox" name="a_d" value="2">a_d1</input> <input type="checkbox" name="a_d"...

appending to links with jquery

I need to append an associate ID to the end of all links that go to a certain URL. Here is what I have but I can't get it to work. (this will be in WordPress) <script type="text/javascript"> jQuery(document).ready(function() { jQuery("a[href*=doitbest]").click(function() { this.append("?memberid=5705&associate=true"); }); ...

Download File Using Javascript/jQuery

I have a very similar requirement specified here http://stackoverflow.com/questions/1296085/download-file-using-jquery need to start download a file when i manually calls $('a#someID').click(); But I cannot use window.href method as solution since it replaces the current page contents with the file you're trying to download. Instead I ...

Reading json return value

Hi there, I have a static web method which returns an object and this object has some values. I am calling this function from an ajax call. $.ajax({ url: "EuclidAktarim.aspx/f_EuclideGonder_", type: "POST", data: "{_sTCKimlikNo:'" + tc + "', _iKlinik_id:" + iKlinikId + ", _iYil:" + iYil + ", _byAy:" ...

how to fix opacity on IE6

how to fix opacity on IE6 This code does not work on IE6 ! filter:alpha(opacity=50); -moz-opacity:0.5; -khtml-opacity: 0.5; opacity: 0.5; And this code ! $('#description').animate({opacity: 0.0}, 1000); ...

Validate form with jQuery in different section

Hi All, I have been thinking how to display the validation messages into different sections of the form. I have an online quotation with single html form. I have put them into different section to ease the user enter the information based on the categories. I have divided the form for example into the Customer Contact Details, Consulta...

Can we split jquery.js in two parts?

Hi, Is it possible to split jquery.js in two or three different part? Currently I am using version 1.4.2, which is too heavy to load in 256kbps internet line. Regards, Vikas Parab ...

multiple divs drag

how to drag and drop multiple divs using jquery ui?any option to accept a array of divs? ...

jQuery Plugin Method Chaining Class Layout

I am creating a jQuery plugin and I am having trouble setting up the class/methods to fit the api access I would like. Here is what I have so far, but it doesn't work (I get an Object doesn't support this property or method error): (function( $ ){ $.kitty= function( name ) { this.name = name; this.cat= function( s...

detecting keydown event with jquery in asp.net

Hi, In my project there is a button search which seems to be the default button to trigger when enter key has been pressed. How can i detect a keydown event with jquery for a login button? Its an asp.net project. ...

After I've validated if some $_POST variables are correct, I want my window to close. How do I do this with JQuery?

<?php if($_POST["some_variable"]){ echo "this window should be closing now"; } ?> How would I call the JQuery code to close the window, and what would the function be? The window was opened with a code resembling the following... $('.new_window').each(function(){ $(this).click(function(){ var center ...