[jQuery] menu using Superfish and jQuery blinking in IE
Here is the page I'm asking about... http://www.tolerase.com/test2.php The navigation for the site above works fine in Firefox. In IE however, the menu rollover blinks everytime a submenu list element is rolled over. What can I do to fix this? Also, in Safari the full width of the submenu does not display until the user rolls over the submenu.
[jQuery] Repost: Dragging from droppable to droppable
This didn't quite work before: So I have two distinct TD tags, and each one is designated droppable. Inside one of the TDs I have a DIV tag that is draggable. Both droppables will accept that draggable. The dragging and dropping works, but *both* droppables call their "drop()" methods when I drag the DIV from one TD to the other. The ui object of first (erroneous) drop() reports that the DIV was dropped into the TD from which it came. The ui of the second drop() says that DIV was dropped into the
[jQuery] Dragging from droppable to droppable
So I have two distinct TD tags, and each one is designated droppable. Inside one of the TDs I have a DIV tag that is draggable. Both droppables will accept that draggable. The dragging and dropping works, but *both* droppables call their "drop()" methods when I drag the DIV from one TD to the other. The ui object of first (erroneous) drop() reports that the DIV was dropped into the TD from which it came. The ui of the second drop() says that DIV was dropped into the other TD (which is accurate).
[jQuery] change css relative to css file
I have this: $('#id').click( function(){ $(this).css('background-image','url(images/ img.jpg)'); } ); Problem is that I want to use a path (images/img.jpg) that is relative to my CSS file, not to the current page... The obvious first question will be "why not just put /path/to/images?" The answer is I'm trying to incorporate something into a drupal module and so I cannot be certain of what the full path will be. Thoughts? Alex
[jQuery] Loading (index.php?option=com_foodmenu) into a DIV
Hey Everyone, I have a site loading content into a DIV using $ ( "#content" ).load( 'home.html' ); however when I try to load a page with variables in the URL like the one in the topic title, it does not work. Is it possible to do this, or is it a limitation of the language? Any advice or tips would be greatly appreciated. Cheers.
[jQuery] Site Submission: http://www.imamuseum.org/
Not my first jQuery-using site, but definitely the most cutting edge: http://www.imamuseum.org/ The site itself is built using Drupal 5.2. Drupal normally ships with jQuery 1.0.4, but we upgraded it to 1.1.x for the purposes of this site. The most-used plugins were Dimensions and jqModal. Despite all the moving stuff, the only place on the site where any Flash is used is for the videos. Those are a flash wrapper. Everything else is jQuery. Please add it to whatever the normal jQuery propaganda lists
[jQuery] Issue w/ AjaxCFC & blockUI
Preface: AjaxCFC is a ColdFusion lib that provides a server-side wrapper for jQuery. It was created by Rob Gonda and allows CF developers to easily include Ajax-capabilities into their applications. Currently, its using jQuery v1.1.3. We're working on moving it to jQuery v1.2.1 and so far, the Ajax code is working fine in AjaxCFC. Issue: One of the features included into AjaxCFC is the ability to call the blockUI plugin to display an Ajax loading message. AjaxCFC currently includes the following
[jQuery] multiple calls to jQuery(document).ready();
I need to call the $(document).ready() function multiple times due to content for the page being compiled from multiple sources. It seems to work just fine, but curious of there might be an issue that I am not seeing? When you call the function, is it just basically assigning that function as a callback? Thanks [m]
[jQuery] Any server status if use script tag for XSS?
Hi, I would like to call crossite script. So I use the script tag technique (create script tag, assign src and append to head) to do so. But unlike xmlhttprequest, I cannot get any response status from it. So I just wonder if there is anyway I can detect if the remote script is not available? I tried to use try-catch, which works on Firefox but not IE. Code: $(document).ready(function(){ try{ var s = document.createElement("script"); s.type = "text/javascript";
[jQuery] jcarousel FF 2.0 flicker fix -- now new problem?
Hello -- I am using jcarousel for my site and was experiencing a flicker issue that has been discussed earlier on this forum. I applied the fix for it: function mycarousel_itemVisibleOutCallback(carousel, item, i, state, evt) { setTimeout(function() { carousel.remove(i); }, 20); }; however, now i am experiencing a new issue and was wondering if anyone knows how to resolve? Now, when i press the "next" button (to progress the carousel forward) really quickly (basically a quick double click), the
[jQuery] Which Validation Verison with jQuery 1.2.1?
<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"> <head> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"> <meta name=Generator content="Microsoft Word 12 (filtered medium)"> <style> <!-- /* Font Definitions */ @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4;} @font-face
[jQuery] good but could be better blur() form submit
Hi guys/gals, Here is a snip of code I was testing for a part of my application. It is very neat but doesn't meld well with my other session stuff. Basically if you remove focus from the text box using blur(), it submits the form and sets the Coldfusion variable. Take a look and see if this could be improved or altered to work better... <script src="js/jquery.js" type="text/javascript"></script> <script> $(document).ready(function() { $('.binky').blur(function() { $("form").submit();
[jQuery] Session management in an Ajax app
A buddy of mine, Raymond Camden, posted an interesting question on his blog: "How can you timeout a session in an Ajax-based application?" http://www.coldfusionjedi.com/index.cfm/2007/10/8/Ask-a-Jedi-How-can-you-timeout-a-session-in-an-Ajaxbased-application The gist is that if you have a dashboard-type app and you need to determine if your session has timed out on the next Ajax request, how would you go about doing it. He mentioned creating a ping-like service that would poll the server every so
[jQuery] Replacing text based on language selection
I think what I need to do will work... I just ran into a road block. One of my co-workers has filled out an XML sheet for me, with REAL japanese values i.e. <subAboutLoc>USロケーション</subAboutLoc> <subAboutWW>グローバルロケーション</subAboutWW> <subAboutProductOverview>製品概要</subAboutProductOverview> <subAboutTradeShows>展示会</subAboutTradeShows> <subAboutEduTraining>セミナー& トレーニング</subAboutEduTraining> <subAboutCareerOpps>就職案内</subAboutCareerOpps> <subAboutFinancial>財政情報</subAboutFinancial>
[jQuery] Animating separate elements
I have two boxes, a yellow one and a blue one, and I want to animate them at separate intervals. This is an example of what I would like to happen: 1. Loading page complete 1. Yellow div box fades to zero opacity. 2. Wait 2 seconds 3. Blue div box moves left to right 100 pixels. I can get them to perform animations at the same time, but I can't seem to wrap my head around getting the script to wait 2 seconds before performing the next command. Is there a simple techinque that already exists to perform
[jQuery] Virtual Earth and Firefox printing
This may not be the most elegant of solutions but--add this to your page after the map is rendered (map.LoadMap()): var map = null; var pinid = 0; function GetMap() { map = new VEMap(); map.LoadMap(); $(function(){ $('.MSVE_Map div').each(function(){ $(this).css("z-index", '0'); }); }); } Our environment: Firefox 2.0.0.7 jquery 1.2.1 Hope this helps in some way.
[jQuery] Validation madness
I'm using the validator plugin, and I have some code like this: var errContainer = $('#CSForm div.error'); $('form#CSForm').validate({ errorContainer: errContainer, errorLabelContainer: $("ol",errContainer), rules: { First_Name: "required", Last_Name: "required", EMail: { required: true, email: true }, Make: "required", Model: "required" }, messages:
[jQuery] animating multiple items at the same time
Hi! I am relatively new to jQuery and recently ran into the following problem. Let's say I have a few DIVs of the same dimensions on top of each other. I need to expand/shrink them at the same time. I tried running a loop through these DIVs and doing something like: for(i=0;i<5;i++){ $('#divid'+i).animate({width: 400}, 'slow'); } this works but the animations don't occur at exactly the same time for each element (loop delay obviously). Is there a way to make all animations start at the same time?
[jQuery] What is the JQuery's equipvalent of this?
Hi, I have following javascript to jump to an anchor point: window.location.hash="mycomments"; what is the JQuery's equivalent? the above code works in all the browser, also Safari except safari will be always in a 'loading' mode, any idea? Thanks. A.C.
[jQuery] Overriding jQuery Function
I would like to be able to 'override' a standard jQuery function to provide it with customised features and/or functionality whilst still being able to call the base/original function from within the new function to do the majority of the work. Is there a recommended approach to achieving this type of extension? [PS I originally posted this question on the Plugin Group - apologies]
[jQuery] Improvements to the docs
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> </head> <body bgcolor="#ffffff" text="#000000"> <font face="Arial">Wouldn't it be a good idea to mention what version of jQuery functions are available in above each function, much like the PHP docs? </font> </body> </html>
[jQuery] jQuery 1.2.1 and Validation Plug-in won't run in IE 7...
<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"> <head> <meta http-equiv=Content-Type content="text/html; charset=us-ascii"> <meta name=Generator content="Microsoft Word 12 (filtered medium)"> <style> <!-- /* Font Definitions */ @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4;} @font-face
[jQuery] 1.2 and XPath Contains Predicate Selector
..mmh, have a bit of a problem with the XPath Contains Predicate Selector.. Updating code based on jQuery-1.1.3 to jQuery-1.2.1 and changing aforementioned selectors I've found that where something like this used to work: $("a[@id *= smenu]") the, obviously only apparent, equivalent: $("a:has(@id *= smenu)") does not. Where do I go wrong? -- View this message in context: http://www.nabble.com/1.2-and--XPath-Contains-Predicate-Selector-tf4555667s27240.html#a13001553 Sent from the jQuery General Discussion
[jQuery] Rotate an Image 90 Degrees with jquery-rotate plugin
I started a rather lengthy discussion about this awhile back and never really found anything to work. However, I just came across this plugin that seems like it might do the trick: http://code.google.com/p/jquery-rotate/ Has anyone else used this plugin? Does it work well for you?
[jQuery] Keeping the calendar plug in open?
Apologies if I'm posting in the wrong place, I'm new to jquery. I've got the calendar plugin working ok, but would I would like it to do is to stay open all the time ( as in google calendar ). I don't see in the calendar docs any options or methods for preventing it from closing. Am I missing something obvious or do I need to go hack the calendar script itself? Or is there a better option for that kind of date picker? Also, if someone knows how to get rid of the clear and close button too, that would
[jQuery] scrolling the browser
hi, is there a way to scroll to the bottom of the page? a.c.
[jQuery] apply a class to the active sub menu
Hello, I would like to apply a class to the active sub menu. I used previously to select the sub menu with this: var $path = location.pathname.substring(1); $('#nav a[@href$="' + $path + '"]').addClass('active'); But it failed with the last jquery version I tried: $('#nav a[href="' + $path + '"]').addClass('active'); But with no success.. Any idea of the problem in the syntax used or of the syntax to use with the new jquery version? Thanks in advance. Xavier
[jQuery] scrolling the browser
hi, I appended a html page to a DIV near the end of page: $(msg).appendTo($('#new_comments').empty()); however the user has to scroll down to view, is there a way to scroll the browser to the last in jquery/javascript? Thanks. A.C.
[jQuery] jQuery Calendar v2.7 and custom date ranges
Hi All, Does anyone know how to get the date range to work for the calendar? I tried adding this code, but maybe I put it in the wrong place or something. Please help. <script> $(document).ready(function(){ $('.calendarRange').calendar({fieldSettings: customRange, autoPopUp: 'focus', dateFormat: 'MDY/'}); function customRange(input) { return {minDate: (input.id == 'dTo' ? getDate($('#dFrom').val()) : null), maxDate: (input.id == 'dFrom' ? getDate($('#dTo').val()) : null)}; } });
[jQuery] Chaining actions & event handling, newbie.
Hi, One year since I discovered jQuery, it's quite the time to use it. So... Let's go... I'm in trouble with a little ajax i'm trying to set up. How to apply an event handler on ajax loaded content ? In my case, I've got a link which load a form in a div with $.get(). In the success callback, I apply an ajaxSubmit() action on form.submit(). On ajaxSubmit() success, response is parsed and form's div content is replaced by the response. The response can handle form. So, when I submit this new form,
[jQuery] Enable/Disable extension
Am I re-inventing the wheel here? I just want a simple extension to test if a control is enabled and to set jQuery objects quickly. If this has already been done, could you point me to it? If not, please offer comments on my approach. Thanks, Dave jQuery.fn.enabled = function(enableIt) { //sets object(s) to enabled/disabled or returns the enabled state of the first element if (enableIt == null || enableIt == undefined) //nothing passed, just return state of first element { return !($(this).attr("disabled")
[jQuery] How to get the value of radio button
For example I have a group of radio buttons and would like to get value of the selected radio button. <div id='Details'><input type="radio" value="Butter"name="Food"
[jQuery] jquery to center a block element, footer bottom
I have two questions: How do you center a block as browser window resized? How to make the footer stay bottom of viewport?
[jQuery] Getting a specific option in a select
Hi, I'm trying to get the option with a specific value in it. This is the syntax I use and doesn't works: alert($('option:[value*=\'2\']', $('#category_1')).size()); It alerts 0, if I try without the value I get the correct size of the options in the select. Where's the error? Thank you
[jQuery] [NEWS] jQuery Crash Course Article
My buddy Nick Dominguez sent this over to me: jQuery Crash Course http://www.digital-web.com/articles/jquery_crash_course Rey
[jQuery] need a simple jquery alert or prompt example with ok or cancel choices
I have a jquery script that gives the user a prompt and a choice to make sure they want to delete a value from a datasource. Here is my code... It prompts funny...and it goes ahead and processes anyways even if you select cancel.. Can someone fix me up here? <script type="text/javascript"> $(document).ready(function() { $("a").click(function() { prompt("Are you sure you want to delete?",{buttons: {Ok:true,Cancel:false}}); } ); }
[jQuery] How to push data to parent iFrame?
I have a page that opens an iFrame with selection information on it. When the user selects one of the options, it needs push certain data back to the parent frame regarding what was choosen (i.e. a description to a textarea, option id, etc). How do I reference the parent frame's fields to change their values? Thanks
[jQuery] How width/height is calculated? [2]
Hi, I have the same problem and didn't find a solution yet. Is there any way that I can get the height of elements not visible (because their display css property is set to none or because parent elements properties hide this element, too). Michael
[jQuery] Chaining actions & event handling, newbie.
Hi, One year since I discovered jQuery, it's quite the time to use it. So... Let's go... I'm in trouble with a little ajax i'm trying to set up. How to apply an event handler on ajax loaded content ? In my case, I've got a link which load a form in a div with $.get(). In the success callback, I apply an ajaxSubmit() action on form.submit(). On ajaxSubmit() success, response is parsed and form's div content is replaced by the response. The response can handle form. So, when I submit this new form,
[jQuery] IE6 Stylesheet Woes
I'm working on fixing my JSS plugin for IE, it appears that IE has really problems with showing you the source of stylesheets that are between style tags. $('style').text() -> returns null $('style').html() -> returns the source but it is modified, e.g. all non-supported selectors are changed to 'UNKOWN' (very unhelpful!) Before I delve deeper into this does anyone have a work around already?? I assume this is supposed to be some sort of security feature but it seems very strange seeing as loading
Next Page