jquery

People who double click everything on web pages... jQuery double click problemo

I have a link on a web page opens up a modal dialog. The first time the link is clicked initialization code executes. Subsequent clicks do not need to do any processing. The problem here is when people double click the link the initializing code runs twice -even though I am setting a flag immediately to say that I am initialized, and if...

My Dropdown menu works right on every browser but IE 7. Why?

I'm making some basic drop down menus based on this tutorial So its all dandy except for IE7. It appears when you hover on it but when you move the mouse from the main element to the ones below it it hides again. /* General */ #cssdropdown { position:absolute; right:0px; top:0px; font-size:medium; font-weight:bold; } #cssdropdown, #cssd...

Form input loses focus on scroll bar click in IE

Hello everyone, I hope someone can help me. I know this has been discussed here before but the example is prototype and foreign to me. I'm looking for a strict javascript or jquery solution. I have an example setup here. Click on the scrollbar in FF and you don't get an alert but click on it in IE and you do. Please help me, thanks! ...

jQuery addClass for hover effect not working in Safari.

This code works in FF 3.5.7 and ie7 and ie8. I'm just adding and removing a class which has a background image (a subtle off-white gradient) to change the background image on hover. Can anyone help me get this working in Safari? Thanks! the example page is @ http://cambridgeuplighting.com/home (look in the footer in the three colum...

Best method for selecting multiple checkbox items

I am developing an internal messaging application which is to be used by approximately 500 users. When composing a new message it will ask who you want to send the message to. Instead of presenting the user with a checkbox list of 500 users which they can pick from (i.e they may only wish to send to 20-30 of the 500 users) I wanted to as...

Getting JQuery to act on class name dynamically added by GWT

Hello, I'm trying to get jquery to do some ui affects for me while using GWT. I have notifications that I add to a page that when clicked should disappear. Since there could be multiple notifications of the same type (warning, error, etc.) I'm trying to dynamically add a style name only when they are clicked through GWT and then hav...

jQuery getting element relative position

Hi, I have the following markup: <div id="selectable1"> <span class="drag">Some Text</span> <span class="drag">Some Text</span> <span class="drag">Some Text and <span class="drag">Some Other Text</span></span> </div> I need to create a function that will get the relative position of any span (nested or not) to the main parent - #selec...

How do I make a jQuery dropdown checklist hide until it's built properly in IE6?

I'm using the jQuery dropdown checklist plug-in. When the it gets wired up to a multi-select box, you can see the multi-select render for an instant then the correct looking dropdown shows up. It's noticeable on page load but it's especially ugly on partial postbacks when it flashes the larger multi-select for an instant. I was thin...

jQuery: how to filter out non-character keys on keypress event?

I tried searching but unsure of what terms to look for. I'm using jQuery and would like to use the keypress event in a textbox, but prevent all non-printable characters (ie. Enter, ESC, arrow keys, backspace, tab, ctrl, insert, F1-F12, etc) from triggering the event. Is there an easy way to determine if it is printable? ...

jQuery: Most efficient way to create blocks of HTML based on number of selected items?

So I have a basic HTML <select> element where a user can select a number. What I then need to do is create some list items in an unordered list based on the number they selected. What's the most efficient way to do that with jQuery? ...

Simply jQuery $.get call to twitter failing

I'm trying to write my first ever bit of AJAX, reading the public tmeline from Twitter. I have the following bits of code: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt; <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Javascript Twitter ...

Remove JQuery validationEngine from form

I am using Position Absolute's jQuery validationEngine but I need to remove it after attaching it to a form. I have 2 submit buttons on my form - one for save and one for save as draft. I attach the validationEngine to the form when Save is clicked. If the validation fails, and the user clicks Save as Draft (by passing the validatio...

jquery autocomplete with servlet

how to use jquery autocomplete with a servlet please provide a brief example. $("#a").autocomplete("What i need to write hear if i want to retrieve data from a servlet"); ...

More than one slideshow on one page using jQuery

Is it possible to create more than one slideshow (each slideshow having a different set of images, of course) on the same web page using jQuery (or some similar package)? If so, how? All tries so far failed because all images were either shown in both slideshows, the numbering was incorrect or other interference effects occured. ...

jquery function not working in Safari?

Is there something unique about Safari that would render the code below useless? While it works as expected in all the other browsers, it fails in Safari, insomuch that the attribute isn't removed at all... $('ul.nice-menu a').each(function() { $(this).removeAttr('title'); }); ...

jquery, safari & jqzoom plugin - issue with document.ready

Hi, I have a small issue with jQuery on Safari (Mac OSX 10.6) - the page loads fine under Firefox (Mac) and Internet Explorer (Win) but has to be refreshed to work properly in Safari... http://7souls.co.uk/store/index.php?dispatch=products.view&amp;product_id=29788 If you hover over the image it is meant to show a magnified version to...

asp.net mvc JavaScript in View User Controls rendered through regular browser request and AJAX request

I have this code in some of my ASCX files: <%=Html.ActionLink(Resources.Localize.Routes_WidgetsEdit, "Edit", "Widget", new { contentType = Model.ContentType, widgetSlug = Model.Slug, modal=true}, new { rel = "shadowbox;height=600;width=700", title = Resources.Localize.Routes_WidgetsEdit, @class = "editWidget" })%> Take note of ...

ajax and no forms, what will happen?

I notice my site does not have a single <form> with the exception of logging in. I am not sure how or why it happened but i found i use jquery and ajax to post everything then refresh (or not if i dont need to). How and why would the user suffer from this? Some of my 'forms' include Leaving a comment on a page Removing messages Send...

Problem with CSS postion: relative with position: absolute children

Usually this sort of thing I can do, but today it is bugging me. See this page at JSbin. Essentially what I'm doing is have a list of unordered items they all have a link jQuery loops through and makes an extra link inside the list item, which is expanded to the whole list item using CSS this gives users a larger place to click For...

jquery apply an attribute to only the first element?

I'm trying to set an a name to the first link with a specific class, but I'm kinda unsure as to how to apply something to just the first one? So, I'm trying to find the first div with the sample class and then wrap the text within the div.title with the : <div class="sample"> <div class="title"><a name="thisone">title</a></div> <p>blah...