jquery

if $(document).not-ready()? How can I check if the page is still loading with Jquery?

I want to call a function only if the document is still loading.. how can I? ...

Jquery add drop shadow to layover

I am using this layover plugin to display content: http://jquery.com/demo/grey/ I know there must be a simple way to add a drop shadow border to the layover, similar to: http://fancybox.net/ but I can't figure out what the best method would be. Any suggestions? ...

How do I get selected date set by jQuery UI Datepicker

I'm setting the start date of an event using jQuery UI Datepicker. Now I need to retrieve the date I selected. I'm trying to use $('#startDate').datepicker('getDate'), but this returns NULL. Using FirBug, I see that the input value is nothing> <input type="text" name="startDate" value="" id="startDate" class="hasDatepicker"> So how ca...

Prototype or jQuery for DOM manipulation (client-side dynamic content)

I need to know which of these two JavaScript frameworks is better for client-side dynamic content modification for known DOM elements (by id), in terms of performance, memory usage, etc.: Prototype's $('id').update(content) jQuery's jQuery('#id').html(content) EDIT: My real concerns are clarified at the end of the question. BTW, bot...

jQuery and margin: 0 auto

So, this is a problem that's been asked before, but I'm hoping we can lay it to rest: I'm using jQuery 1.4. If I define the style #obj { margin: 0 auto; } and then do $('#obj').css('marginLeft'); the result is the computed value in pixels. Is there any way to tell whether those pixels come from the auto calculation or not, without ...

jQuery Tablesorter - disabled headers show progress bar, sortEnd never triggered

I'm combining Tablesorter's 'disable headers using options' function and the 'trigger sortStart / sortEnd' function and have run into an issue. The following code works fine for the most part, BUT: when you click on a disabled header, the progress-indicating #overlay div appears and never goes away. <script type="text/javascript" id="js...

Take <span> class and put in <a> attribute jquery

Hello, I have html like this. <span class="gallery-open-item year-icon-Yes 2010"> <a href="/year/none"> </a> </span> I need to check using jQuery if span.gallery-open-item has year-icon-Yes class, and if so take the next (for this example is 2010) class and place it in the href attribute like this: <a href="/year/2010"/> All this ...

How do I make the "back button" work with jQuery hide/show functions?

I'm looking for a way to append text to the url with jQuery so that the back button is not broken when a user loads new content with jQuery. For example, I have a three step form - the first step is (www.xyz.com/form-1). When the user clicks next step, jQuery slides in the next page. I would like that page to be (www.xyz.com/form-2)...

Jquery.load returns 206 Partial Content and no content shows.

I'm calling $('#help').load('http://recaptcha.net/popuphelp/'); but it returns 206 Partial Content and doesn't fill the div with the help information. I think it has something to do with cross-domain request limitations. How can I get it to work? ...

Good Notification Plugin For Jquery?

Hi I am looking at pines notify(http://pines.sourceforge.net/pnotify/) and it looks good but it seems to have little actual documentation so I am wondering is there anything more established and worked on out there? Like I don't want to spend time trying to figure out how to use pines and then find out it is missing some feature that I...

Is there any downside to using height: 0px; overflow: hidden; instead of display: none?

Is there any downside to using height: 0px; overflow: hidden; instead of display: none? ...

Dynamically created iframe not working on Safari

I have a weird problem and I find no answer on google... I dynamically create and fullfil an iframe with jquery on a page. It works fine withFF and IE, but not with Safari. The iframe is created but empty (the message "greetings from the iframe !" is missing). Here is a piece of code to illustrate it : <!DOCTYPE html PUBLIC "-//W3C//DT...

jQuery timer, ajax, and "nice time"

So for this is what I've got: $(document).ready(function () { $("#div p").load("/update/temp.php"); function addOne() { var number = parseInt($("#div p").html()); return number + 1; } setInterval(function () { $("#div p").text(addOne()); }, 1000); setInterval(function () { $("#geupdate p").load("/update/temp.php");} ,10000); }); So th...

my jquery code dont work?

UCCN1003Edit <script type="text/javascript"> $(function(){ $('a.edit').click(function(event){ var change = $(this).parent('div').find('p'); var changeText = change.text(); var wrapper = $(this).parent('div'); var clone = change.clone(true); var changeBox = $(...

jQuery serialize does not register checkboxes

I'm using jQuery.serialize to retrieve all data fields in a form. My problem is that it does not retriev checkboxes that is not checked. It includes this: <input type="checkbox" id="event_allDay" name="event_allDay" class="checkbox" checked="checked" /> but not this <input type="checkbox" id="event_allDay" name="event_allDay" class...

Move iFrame in the DOM using jQuery

My overall aim is to create an editor which I can skin using jQuery UI (by creating a custom toolbar which uses integration calls), using TinyMCE. Lets say I have a TinyMCE editor on a page. The actual editor is an iFrame contained inside a lot of horrible table code, which is also where the current (to be scrapped) toolbar is. I want ...

How can I create a file upload progress bar with PHP and jQuery?

How can I create a file upload progress bar with PHP and jQuery? Please don't refer me to Flash stuff like Uploadify. I want to create my own. ...

Moved from Jquery 1.2.6 to 1.4.1 > Script errors :(

Hi, Ive been playing with some jQuery script that was originally written using 1.2.6. I want to use his try this script along side some other jquery stuff whilst moving upto the latest 1.4.1, however i get an error. The code is: GlobalHeader={ globalNav:function(){ var recipeLbl="recipes-and-cooking"; var navT...

How to switch vertical and horizontal mouse scroll?

I have website with horizontal layout and i what to make mouse wheel scroll it relative to axis x (not y, like usual). I use jQuery plugins mousewheel and scrollTo, but I can't achieve soft, natural scroll. You can look at the example on my test site ...

Help with Jquery + Masonry Plugin: How to expand/collapse boxes to reveal content

I'm using the masonry jquery plugin on a project: (http://desandro.com/resources/jquery-masonry) Basically I have a set of boxes (thumbnails) in a grid. When one is clicked, I want it to expand to a larger size to show more content (additional images and text). I'm struggling with how to make the thumbnail dissappear and then have new c...