jquery

posting form and retieving posted data in another page using jquery

Hi, I am trying to post a form to another php page. The posted data is processed in the php page and page needs to be redirected to a new url. 1) Where do i give this code for posting the data to test.php. Do i have to call this in a function when the submit button is clicked? $.post("test.php", { name: "John", time: "2pm" } ); 2) ...

Retrieving an attribute from the next associated class

Hey folks, diving into jQuery and loving it. I have a set of links ex: <a href="#" title="Link 1" class="links">First Link</a> <a href="#" title="Link 2" class="links">Second Link</a> and also have a function that alerts the user what the link title is when they click on one: $(".links").click(function(){ var a_link = $(this); ...

jquery ajax request firebug error

I am using php/ajax to submit a form without page refresh. Here are my files- coupon.js jQuery(document).ready(function(){ jQuery(".appnitro").submit( function(e) { $.ajax({ url : "http://174.132.194.155/~kunal17/devbuzzr/wp-content/themes/street/sms.php", type : "post", dataType: "jso...

Looping through Elements

Hey guys, I want to make a function loop over all elements that have the class of ".block-header-tabs" and do the following: $(function(){ function cssTabs(){ var firstTab = $(".block-header-tabs").find("a:first"); var firstBlock = $(".block-header-tabs").find("a:first").attr('href'); $(firstBlock).parent().css({position: "relative"})...

jquery bind submit event - find caller

Hi, How would I be able to find out the caller/sender of an event on binding. $(this).bind("submit", function(caller) { ... }); I found out that I could use "caller.originalEvent.explicitOriginalTarget", but this only works in firefox. EDIT: I'm using the jquery validation library from position-relative.net I want to make it so tha...

How to check display (none/block) of a div in jquery?

I am using this, $("#loginanchor1").click(function (e) { e.preventDefault(); $("#signin_menu1").slideDown("slow"); }); $(document).mouseup(function (e) { if ($(e.target).parent("a.loginanchor1").length == 0) { //$(".signin").removeClass("menu-open"); $("#signin_menu1").slideUp("slow"); } }); Everything ...

jQuery - missing } after function body

Where is problem: I got error: missing } after function body (function($) { $(document).ready( function() { $("div.area_map").click( function () { alert('clicked'); $('img.hoverswap', this).css({ position:"absolute", left:"0px", top:"0px", width: "120", ...

how to trigger onclick function in Html Check box when its status changed to checked.

Hi, I have a page which lists the Employee. In the left side of the list i have checkboxes to select. So, i have Select all checkbox also in header.When i click on select all check box it will selects all check boxes below. But i have javascript in onclick event for checkboxes in down not for select all checkbox. when i select all the ch...

jQuery clone() doesn't copy <select> DOM properties?

Consider the following HTML : <a id="add" herf="#">add</a> <div class="list"> <select> <option>1</option> <option>2</option> </select> </div> And Javascript : $('#add').click(function() { var copy = $('.list').last().clone(); copy.appendTo('body'); }); (OR : http://jsfiddle.net/5A5pN/) If you choos...

Where is memory leak in JavaScript / jquery ?

Hello! I have two singletons: Search - performs the search functionality Topic - presentation of topics (search results) var Search = new function () { this.GetTopics = function () { var query = $("#globalSearch").val(); $.ajax({ url: 'Search/GetTopics', dataType: 'json', dat...

JQuery - Abort each function

Hi, how can I abort the jquery each function? $.each(big_test_object, function(i) { // some code }); Thanks in advance! Peter ...

jQuery: press J and have it do something, press H and have it do something else

I can't get a simple answer to this: When I press the letter J, i want it to hide $('.something') and when i press the letter H, I want it to show $('.something') press the letter J $('.something').hide() press the letter H $('.something').show() ...

Why is my tooltip not remaining visible on mouseover? (jQuery)

I'm trying to get a tooltip to remain visible on mouseover. It works when you mouseover the first time. But try to mouseout, then mouseover another link and mouseover that tooltip. It will fade. Check out the code on jsFiddle. Would love to know what I'm doing wrong here. http://jsfiddle.net/6FpM8/7/ ...

How can I give slide effect to image when changing source of image dynamically

Im changing image source from javascript like <img src="image1.gif" name="imagename"> //Array img[0]='image1.gif' img[1]='image2.gif' ... //onclick event changing img src document.images[imagename].src = img[1] Its working fine. How can I give it a slide effect to image when changing source of image? I can use jquery. ...

Refresh div using JQuery in Django while using the template system

I want to refresh a in django that contains temperature data. The data is fetched every 20 seconds. So far I have achieved this using these functions: function refresh() { $.ajax({ url: '{% url monitor-test %}', success: function(data) { $('#test').html(data); } }); }; $(function(){ refresh(); var int = setInterval("ref...

How to use jQuery SlickGrid with PHP / MySQL (load server data and save changes)

Please, in all the examples found in the SlickGrid code, the data array was randomly generated on the client side. Getting: I need to know how to use PHP to fetch this information from a MySQL Database and return it using jQuery / AJAX to the SlickGrid. Saving: I already found a link on StackOverflow for saving data from the grid using...

Twitter Top Tweets like jQuery Plugin

I'm looking for a JavaScript or a jQuery plugin has an effect like the twitter top tweets. Thanks in advance. http://img52.imageshack.us/img52/6899/twitterl.jpg ...

Form submit without page refresh

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. I want the message to be displayed depending on the result of the form su...

How to Use jQuery Calender in jQuery shadowbox Popup Box

Hi All, I want to call jQuery Calender in jQuery shadowbox Popup Box. Please help me regarding this. I am using following code for that function singleConfigPopup() { Shadowbox.open({ content: '<div id="popup" class="clearfix"><h3>Calender</h3><form><input type="input" id="datepicker"></p></form></div>', ...

iframe load event not working in ie6

iframe load event in jQuery is not working in IE6 var iframe = this.iframe; iframe.load(function(){ }); ...