Re: [jQuery] (validate) custom message for maxlength
Sure: messages: { comments: { maxlength: function(max) { return "'Comments' must not exceed " + max + " characters. You entered " + $("input[name=maxlength]").val().length + " characters"; } } } Jörn On Tue, Nov 17, 2009 at 8:16 PM, Kasvis wrote: > Hi, > > I am trying to customize the message for maxlength rule. > > I want to show the current text length entered in the message > something like this. > > 'Comments' must not exceed 660 characters. You entered 754 characters > > Is there a way to create the message to include the current length. > > Thanks > >
Re: [jQuery] file size
hesham shanana ha scritto: i need to get file size from upload control You can't get it with javascript. You can use some flash plugin like swfupload. Bye -- gianiaz.net - web solutions via piedo, 58 - 23020 tresivio (so) - italy +39 347 7196482
Re: [jQuery] Validation and dropdowns
Set the field as required and provide value="" on the default option: Please... Jörn On Tue, Nov 17, 2009 at 7:57 PM, Atkinson, Sarah < sarah.atkin...@cookmedical.com> wrote: > I have several dropdowns in my form. They start on a “please select one” > state. How do I make it so that if one of these is selected then it does not > trigger validation but kicks back an error? > Sarah >
Re: [jQuery] Load image gallery faster - or tips
Liam Byrne wrote: > > Images can only load as quickly as their connection will allow. > > Your best option is to load the first set of thumbnails (if there's, say, > 12 per page I load 24) and the first image, and then dynamically load the > remainder via ajax or other method. > > Liam > > Jerome Chevreau wrote: > > Thanks Liam. You gave a good hint here. I need to ask you another > question. I use my big image to make thumbs so when i load the thumbs i > kind of load the big images too. So would it be best to load the first one > and load the others dynamically then?? so users will see the first image > at least instead of waiting for the whole lot to finish before seeing the > first image. > > Thanks again for your help. > > Regards > > Jerome > > -- View this message in context: http://old.nabble.com/Load-image-gallery-faster---or-tips-tp26387278s27240p26402987.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] Re: how to parse xml with namespace ?????
Can anybody provide me with some suggestions regarding above mentioned issue On Nov 17, 7:15 pm, "g...@iec" wrote: > Hi all, > > I have came across an issue related to xml parsing. > > Here is code for parsing xml with namespace : > > var data = {xml content}; > $(data).find('{namespace}\\:nodename').each(function() { > { Code to perform something.} > > }); > > This code works fine in IE and FF and xml got parsed as expected. > But it is not workng with safari. > > Can anybody help me out to parse xml with namespaces using jquery so > that it work fine in all browsers??? > > Thanks to all for showing there concern.
Re: [jQuery] Newbie question about updating iframe on tab select
you should use ajax. 2009/11/18 zoog22 > > I have some tabs that I want to not update until they are selected. > > Currently, they all load their respective iframes src="x"s when the page > loads. I was thinking I could leave the link blank on loading and change > them as they are clicked. > > $(function() { >$("#tabs").tabs(); > }); > > > #tab1 First TAB > #tab2 Second TAB > #tab3 Third TAB > > > > > your > browser does not support IFRAMEs > > > > your > browser does not support IFRAMEs > > > > your > browser does not support IFRAMEs > > > -- > View this message in context: > http://old.nabble.com/Newbie-question-about-updating-iframe-on-tab-select-tp26402551s27240p26402551.html > Sent from the jQuery General Discussion mailing list archive at Nabble.com. > >
[jQuery] Newbie question about updating iframe on tab select
I have some tabs that I want to not update until they are selected. Currently, they all load their respective iframes src="x"s when the page loads. I was thinking I could leave the link blank on loading and change them as they are clicked. $(function() { $("#tabs").tabs(); }); #tab1 First TAB #tab2 Second TAB #tab3 Third TAB your browser does not support IFRAMEs your browser does not support IFRAMEs your browser does not support IFRAMEs -- View this message in context: http://old.nabble.com/Newbie-question-about-updating-iframe-on-tab-select-tp26402551s27240p26402551.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] Re: imitate link
> > Can make behave as ? > Why would you not just use CSS to style an element > to be bold and not underlined? Definitely the way to go. That way the link works with the keyboard and screen readers as well. Apps that require the mouse drive me crazy.
[jQuery] Re: Konami Code >:]
I posted this before, but i think i replied to the wrong thing, whoops! anyway, How about making it a jquery plugin? :) [code] $.konamiCode = function (toExecute){ var press = 0, keys = [38, 38, 40, 40, 37, 39, 37, 39, 66, 65, 13]; $(document).keydown(function (e){ if (e.which == keys[press]) { press++; } else { press = 0; } if (press == keys.length) { toExecute; } }); } [/code] Usage demo: [code] $.konamiCode(function() {alert('yay');}); [/code] On Nov 17, 7:03 am, Ash wrote: > Every body loves a little treat in their websites... > > Well I believe jQuery holds the PERFECT javascript library for doing > the Konami Code. A fan of Konami, and having such a cool little hidden > feature to your websites, I decided i'd share my code with the world, > or at least > those people who'd like it.. > > Just like the PHP logo change, creativity with this little beauty will > keep your mind going for ever ;) > > [code] > $(function (){ > var press = 0, keys = [38, 38, 40, 40, 37, 39, 37, 39, 66, 65]; > > $(document).keydown(function (e){ > if (e.which == keys[press]) > press++; > else > press = 0; > > if (press == keys.length) > (function (){ > // your little treat... > }); > });}); > > [/code]
Re: [jQuery] imitate link
On Tue, Nov 17, 2009 at 6:56 PM, runrunforest wrote: > Can make behave as ? > > For exmaple, I have Home, I want to go to homepage when i click > b. > Why would you not just use CSS to style an element to be bold and not underlined? -- Charlie Griefer http://charlie.griefer.com/ I have failed as much as I have succeeded. But I love my life. I love my wife. And I wish you my kind of success.
[jQuery] Re: Newbie validator question/problem
Jules, I was thinking that writing a rule would solve the problem but wasn't sure how to do it. Thanks for detailing it out. -ben On Nov 16, 5:02 pm, Jules wrote: > Can't you use remote validation? This code should work. > > $("#password").rules("add", { > messages: { remote: "Invalid password." }, > required: true, > remote: { > url: ".../UVServer/login.php", > type: "get", > data: { > email: function() { > return $("#email").val(); > }, > password: function() { > return hex_md5($('#password').val()); > } > } > } > }); > > On Nov 15, 1:45 pm, sprach wrote: > > > > > I am new to javascript, jquery and validator, but really see the > > potential and am trying to use in a new application. I am having a > > little trouble wrapping my head around the layers of callbacks. > > > I have a simple login form that I want to validate, but want to send > > an md5 encrypted password to the server. All of my validation works > > until I try and submit the form. Here is the code snippet of the > > validator submit handler: > > > > > submitHandler: function(form) { > > > var pwd = $('#password').val(); // md5 encode > > the password > > md5pwd = hex_md5(pwd); > > //$('#password').val(pwd); > > > $.get('../UVServer/login.php','email='+$ > > ('#email').val()+ '&password='+ md5pwd, > > function(resp) { > > if (resp == 'false') > > { > > // password didn't match > > validator.showErrors({"password": > > "Incorrect Password or Email Address!"}); > > > return false; > > } > > form.submit(); // Password matched, submit > > the form > > > }) > > > }, > > ... > > > The problem that I run into is that I cannot call form.submit() in the > > anonymous call back that I use for the jquery $.get call. In the code > > above, firebug claims that form.submit() is not a function. > > > I have tried many work arounds but nothing seems to work. I don't > > want to use the "remote" rule, because I don't want to pass the > > unencrypted password to the server. > > > Help greatly appreciated.- Hide quoted text - > > - Show quoted text -
[jQuery] imitate link
Can make behave as ? For exmaple, I have Home, I want to go to homepage when i click b.
[jQuery] Re: :gt and :lt don't accept variable as a parameter?
Try $('#filterlist_wrapper ul li:gt('+left_col+')') On Nov 17, 3:35 pm, Magnificent wrote: > It should read: > > > I'm storing my counts in variables, but it doesn't look like :gt > > and :lt can accept a VARIABLE value as it's parameter. > > It works when I put in, say :gt(44), but not :gt(left_col) or lt: > (right_col) when those variables are numbers.
[jQuery] Simple JQuery 1.3.2 Multiple Checkbox Select
Hi All, I'm having an issue with Multiple Checkboxes getting selected in JQuery 1.3.2. In this code you can see that I commented out jQuery v 1.2.6, where this code works perfectly. Yet, in 1.3.2 the code no longer works. I would really appreciate it if you would please take a look at my code below and let me know what I'm doing wrong: http://www.w3.org/1999/xhtml";> jQuery Checkboxes v1.3.2 http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/ jquery.min.js" type="text/javascript"> function jqCheckBoxes( id, name ) { $("inp...@name=" + name + "][type='checkbox']").attr('checked', $ ('#' + id).is(':checked')); } Check All named "testCB" with JQuery 1 2 3 1 Thanks in advance
[jQuery] using variable value as buildin function.
Hi. I'm writing a plugin for myself and I stuck.I'm trying to use link's id value for calling function and I couldn't figure it out. Here is the sample html, plugin for my question. Find out more about apples... $.sample = { _init: function(){ return this.each(function() { var item = $(this); item.children('a').bind('click', function() { var functionName = this.id; //this line. I couldn't figure how to call link's id's function it. }); }); }, apple: function() { //function for the link has "apple" as id }; }; I could rewrite plugin but it as to be this way. I thinked to used eval () but i thinked it could be dangerous. any idea?
Re: [jQuery] Load image gallery faster - or tips
Images can only load as quickly as their connection will allow. Your best option is to load the first set of thumbnails (if there's, say, 12 per page I load 24) and the first image, and then dynamically load the remainder via ajax or other method. Liam > > Hi everyone, > > I have an image gallery and i would like to know if there is a way to load > my images faster so the user dont have to wait for a long time. The image > size play a big role in it. > I practically load all the images upfront before showing the big image and > thumbs. Is it a good practice or is there any suggestion that would help > me > stepping up my gallery??? > > Thanks a lot for any help. > > Regards, > > Jerome > -- > View this message in context: > http://old.nabble.com/Load-image-gallery-faster---or-tips-tp26387278s27240p26387278.html > Sent from the jQuery General Discussion mailing list archive at > Nabble.com. >
[jQuery] Interesting side effect of using the RSV plugin
I discovered by accident that if I use the Really Simple Validation (RSV) plugin, hitting enter in a form field advances to the next field just like hitting tab. I am working on an internal data entry form so this is a good thing. My form fields look like this: tagNum enterDate dueDate Description If I enter valid info in the tagNum field and hit enter, the field required message pops up for the enterDate field. At this point I hit enter again and the proper info is entered in the tagNum field and focus is in the enterDate field. This happens on down the form until I submit it by clicking the button to submit the form. If I enter invalid data in any field the proper warning pops up and I can correct it. Does anyone have an idea of how to prevent the field required message poping up before focus shifts to the next field? Thanks, Jim
[jQuery] Re: :gt and :lt don't accept variable as a parameter?
It should read: > I'm storing my counts in variables, but it doesn't look like :gt > and :lt can accept a VARIABLE value as it's parameter. It works when I put in, say :gt(44), but not :gt(left_col) or lt: (right_col) when those variables are numbers.
[jQuery] :gt and :lt don't accept variable as a parameter?
Hello, I'm trying to take a big ul and format it into 2 columns. What I'm doing is cloning the ul, then floating the clone to the left so that gives me my 2 columns (of the same data). I then get a count of the children, split it in half and show the first half in the left column, the 2nd half in the right column. I'm storing my counts in variables, but it doesn't look like :gt and :lt can accept a numerical value as it's parameter. I've tried passing in parseInt() and new Number() but that doesn't work either. I can hard code a number and it works. But my lists will be dynamic so I can't use a hard number. Does anyone know a way to do this? The columns should read top-down so if you have 100 entires, the left column is 1-50, the right is 51-100, both top-down. Here's the relevant code I'm using: var condition_count = $('#filterlist_wrapper ul li').size(), left_col = condition_count / 2; right_col = condition_count - left_col; //if total count is an odd number, we want to add one to the left column //and subtract one from the right column if (condition_count % 2) { left_col = Math.ceil(left_col); right_col = Math.floor(right_col); console.log('left:' + left_col + ' right:' + right_col); } var column1 = $('#filterlist_wrapper ul'), column2 = column1.clone().attr('id', 'col2'); column2.insertAfter(column1); $('#filterlist_wrapper ul li:gt(44)').css('background', 'yellow'); $('#filterlist_wrapper ul#col2 li:lt(44)').remove(); console.log( $('#filterlist_wrapper ul li').size() );
Re: [jQuery] Unordered List question!
Thanks a lot! And no, this is not a homework. I'm just new to JQuery, and it's a work problem. Thanks again! Scott Sauyet-2 wrote: > > On Nov 17, 3:52 pm, szuwei wrote: >> If you have an unordered list with 10 elements. The list has an ID of >> “myList”. Using jQuery, how can you: >> >> 1. Change the fore color of all even list items to red >> 2. Indent the 5th item when the mouse hovers over it > > Is this a homework problem? I guess if it is, your instructor > probably knows enough to monitor this list too. > > It's pretty straightforward: (http://jsbin.com/esole/edit) > > $("#myList li").filter(":odd").css({color: "red"}).end() > .eq(4).hover(function(){$(this).css({textIndent: "2em"})}, >function(){$(this).css({textIndent: "0"})}); > > Cheers, > > -- Scott > > -- View this message in context: http://old.nabble.com/Unordered-List-question%21-tp26396471s27240p26399421.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] Re: Jquery forms ajaxsubmit- 'success' function callback fails with IE
I was having this same problem where my success function wouldn't be called on ajaxSubmit. I ended up looking at the jquery forms plugin code and line 65 forces your ajaxSubmit to use a GET if you haven't specified wrote: > Hello I am havign problem with using a callback function on the 'success' > parameter of the ajaxsubmit function . The callback works fine in FF but > not in IE 6-8 here my code > > $( "#signinform" ).ajaxSubmit({ success: FormResponse}); > > function FormResponse( responseText, statusText ) > { > //Code accesses the responseText > > } > > Syntax taken from jquery forms plugin page > > I tried 'success :FormResponse()' which is able to call the function but it > wont pass the parameters that i need . How is correct syntax to do > register callbacks for IE and also how do I access the rpeonseText that my > server code is printing on a page > > -- > View this message in > context:http://old.nabble.com/Jquery--forms-ajaxsubmit--%27success%27-functio... > Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] Re: Unordered List question!
On Nov 17, 3:52 pm, szuwei wrote: > If you have an unordered list with 10 elements. The list has an ID of > “myList”. Using jQuery, how can you: > > 1. Change the fore color of all even list items to red > 2. Indent the 5th item when the mouse hovers over it Is this a homework problem? I guess if it is, your instructor probably knows enough to monitor this list too. It's pretty straightforward: (http://jsbin.com/esole/edit) $("#myList li").filter(":odd").css({color: "red"}).end() .eq(4).hover(function(){$(this).css({textIndent: "2em"})}, function(){$(this).css({textIndent: "0"})}); Cheers, -- Scott
[jQuery] Re: Functions
You are kind of defeating the purpose of Jquery if you put the call to the function in an A element. Does the parent of the A element in question have an ID? You could then call $('parent a'). If there is more than one A in there you can target it with other selectors (http://docs.jquery.com/Selectors). Lastly, if that isn't possible and you have to put it in the href, use Javascript to call the function, but inside your function you can use Jquery.
[jQuery] Re: Having trouble getting Superfish to work...
I think its talking about editing the superfish.css file. For example in the sample superfish.css that comes with your download, you see something like this: === .sf-menu li:hover ul, .sf-menu li.sfHover ul { left: 0; top:2.5em; /* match top ul list item height */ z-index:99; } === ".sf-menu li:hover ul" must be a selector carried through from suckerfish, and ".sf-menu li.sfHover ul" is new in Superfish. Corresponding selector definitions exist throughout the .css file. I didn't base my use of superfish on suckerfish, so I basically took the sample superfish.css file and tweaked it to suit my needs. It sounds like you're modifying an existing suckerfish menu system, am I right? -GF On Nov 16, 9:23 am, Wiz8ian wrote: > Hi Guys, > > I know this will be a simple fix - but i've downloaded superfish, > installed the css and js files, inserted everything into the of > my site but simply don't understand what i need to change now to get > it all running. > > The superfish homepage states "Begin with a working pure CSS dropdown > menu just like you would if creating a Suckerfish menu - ie. for each > li:hover selector, add an equivalent li.sfHover selector." Maybe it's > just worded strange but i don't get it. Do i make a new selector with > "a:sfhover" on the end of every "li" in my menu? > > Yes, i'm confused. Anyone able to explain this to me in simple steps? > Forgive my noob-ness. Thanks in advance :)
[jQuery] Re: Help newbie with Superfish menu CSS
Fraggy, Change the following lines in your superfish.css file: === .sf-menu li { background: #BDD2FF; background: #003300; /*JM*/ } .sf-menu li li { background: #AABDE6; background: red;/*JM*/ } [...] .sf-menu li:hover, .sf-menu li.sfHover, .sf-menu a:focus, .sf-menu a:hover, .sf-menu a:active { background: #CFDEFF; background: #ffc702;/*JM*/ outline:0; } === and maybe these lines: === .sf-menu .active { background: #ccc; background: #ffc702;/*JM*/ } .sf-menu #current { background: #aaa; background: #ffc702;/*JM*/ } === GF On Nov 16, 2:16 pm, Fraggy wrote: > Hi there, sorry if I am in the wrong forum for this question, but I don > ´t know where else to ask. I got a "simple" CSS problem with the > Superfish menu: how do i change it's skin I edited superfish.css > to get this result:http://www.qomg.com.ar/qomg/index.php/but now I´m > stuck: which file do I have to edit in order to change the other > colors of the menu? > > The things I need to change: > - The dropdown menu background is light grey, I want to change it, > - The hover (mouseover) on the menu items is blue, I want to change > that one too, > - The hover (mouseover) on the dropdown items is light blue, I want to > change that one also. > > I´m quite sure it´s as easy as pie when you know where to look, but > that´s exactly the problem, I dunno where:o( > > I´m using the Superfish menu plugin for Joomla! Please help, I > need this website finished as soon as possible! > > All help will be greatly appreciated.
[jQuery] Re: Trying to update div tag in jQuery DOM window
On Nov 17, 2:33 pm, Richard wrote: > The problem is that the div is not changing in the DOM window. When I > relaunch the DOM window, then I can see the change. It looks as though this plugin is not using your element but its children. You might have to do the same thing to your div and to $DOMWindow. from http://swip.codylindley.com/jquery.DOMWindow.js, lines 313 - 316: case 'inline': $DOMWindow.append($(settings.windowSourceID).children()); $DOMWindow.unload(function(){// move elements back when you're finished $(settings.windowSourceID).append($DOMWindow.children ()); }); // ... Good luck, -- Scott
[jQuery] Datepicker + on select + click function issue
Hi, I explain my problem: I have a datepicker UI, and when i click on a day, I have to refresh the datepicker when I click outside it. onSelect: function(date,inst) { ... alert('A'); $('body').click(function(event){ alert('B); $("#datepickerId").datepicker("refresh"); return false; }); $("#datepickerId").click(function(event){event.stopPropagation ();}); ... } The problem is that "click function" is executed a lot of times, I do an example: 1) click on a day => alert A 2) click on another day => alert A 3) click on another day => alert A 4) click outside the datepicker => alert B B B Why??? Is as there is some kind of "memory" of what i've clicked... Someone can halp me?
Re: [jQuery] Simple XML Parsing Question
$(xml).find('CustomMessage') -- will give you this result: 181 First Message 135 Sample_img.png image/png >2009-08-25 > 11:25:28.34 > > So, when you go searching for 'id' you're getting back 181 and 135: 181 135 -- Wil On Tue, Nov 17, 2009 at 11:56 AM, Joe wrote: > I have been banging my head against the wall and searching for answers > for the past week, so any help or direction would be appreciated. I > am sure that I am missing something obvious. I have some XML that > looks like this: > > > > >181 >First Message > >135 >Sample_img.png >image/png >2009-08-25 > 11:25:28.34 > > > > > > And an AJAX call that looks like this: > > $.ajax({ > type: "GET", > url: myURL, > success: function(xml) { > $(xml).find('CustomMessage').each(function(){ > var id_text = (this).find('id').text(); > var name_text = $(this).find('name').text(); > var contentType_text = > $(this).find('contentType').text(); > }); //close each( > } > } > }); > > > When i run this code, the id and name variables have all the id/name > nodes in them. I only want the id/name for the child node. the > contentType variable works find (but there is only one instance. > > Any ideas on how to fix this? I am at my wits end. > > thx, > > Joe C >
[jQuery] Trying to update div tag in jQuery DOM window
I have a PHP form in a jQuery DOM window (just like jQuery Dialog), and when the form is sent I want to change the HTML in the div in the DOM window. The problem is that the div is not changing in the DOM window. When I relaunch the DOM window, then I can see the change. // When the form is sent, the following change is not being updated live in the inlineContenContactForm div in the DOM window // Only when I relaunch the DOM window I can see the change $('#inlineContenContactForm').html("'Form Submitted""); // To launch the DOM Window: $('.readMoreDOMWindow').click(function(){ $.openDOMWindow({ windowSourceID:'#inlineContenContactForm', height:220, width:320, overlay:0, positionType:'anchoredSingleWindow', windowPadding:20, windowBGColor:'#ccc', borderSize:'0', anchoredSelector:'.readMoreDOMWindow', positionLeft:120, positionTop:-150 }); return false; });
[jQuery] file size
i need to get file size from upload control
[jQuery] (validate) custom message for maxlength
Hi, I am trying to customize the message for maxlength rule. I want to show the current text length entered in the message something like this. 'Comments' must not exceed 660 characters. You entered 754 characters Is there a way to create the message to include the current length. Thanks
[jQuery] Re: IE 7 error with $.getJSON data elements
I am using v1.3.2 I replaced var aIndex = $(this).attr('href'); with var aIndex = +this.href.match( /\d+$/ )[0]; and it works now. Thanks for the help!
[jQuery] Unordered List question!
If you have an unordered list with 10 elements. The list has an ID of “myList”. Using jQuery, how can you: 1. Change the fore color of all even list items to red 2. Indent the 5th item when the mouse hovers over it -- View this message in context: http://old.nabble.com/Unordered-List-question%21-tp26396471s27240p26396471.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] Re: Having trouble getting Superfish to work...
Thanks Charlie. All good now. :) On Nov 17, 10:14 pm, Charlie wrote: > download the example page, there's a full working example in zip download. > Follow the html structure in the example and try adding new elements based on > that markup > sfHover class gets added by script to li tags, you shouldn't need to add any > classes for the script to work other than perhaps a 'current" class. > Wiz8ian wrote:Hi Guys, I know this will be a simple fix - but i've downloaded > superfish, installed the css and js files, inserted everything into the > of my site but simply don't understand what i need to change now to > get it all running. The superfish homepage states "Begin with a working pure > CSS dropdown menu just like you would if creating a Suckerfish menu - ie. for > each li:hover selector, add an equivalent li.sfHover selector." Maybe it's > just worded strange but i don't get it. Do i make a new selector with > "a:sfhover" on the end of every "li" in my menu? Yes, i'm confused. Anyone > able to explain this to me in simple steps? Forgive my noob-ness. Thanks in > advance :)
[jQuery] Functions
Hi, Just to looking for a better way to use jQuery, here is my doubt. There is a page that uses $.post to call another page that build a report in html table format to put the generated code in a div. So far so good...but...in one of the columns of the report, has a link that executes a javascript function with a parameter (ID). I'm created a function in old style and works: function functionName(parameter){ doSomething; } How to create a jQuery function that I can use in a link tag ? Eg.: String Tks. Ps.: My link tags has a class but there are many anothers links with the same class that dont should trigger the function Ps2.: I think that cant use ID in link tags...
[jQuery] Simple XML Parsing Question
I have been banging my head against the wall and searching for answers for the past week, so any help or direction would be appreciated. I am sure that I am missing something obvious. I have some XML that looks like this: 181 First Message 135 Sample_img.png image/png 2009-08-25 11:25:28.34 And an AJAX call that looks like this: $.ajax({ type: "GET", url: myURL, success: function(xml) { $(xml).find('CustomMessage').each(function(){ var id_text = (this).find('id').text(); var name_text = $(this).find('name').text(); var contentType_text = $(this).find('contentType').text(); }); //close each( } } }); When i run this code, the id and name variables have all the id/name nodes in them. I only want the id/name for the child node. the contentType variable works find (but there is only one instance. Any ideas on how to fix this? I am at my wits end. thx, Joe C
[jQuery] Re: jQuery and Cycle plugin
Hey Mike, Thanks for the reply - that's similar to something I tried, however it has the same effect - the slideshow starts once the page is loaded regardless, and continues on hover. On mouseout it resets to the first image and continues - unless you mouseout during the transition in which case it resets to a blank (non-existent) image and continues the slideshow. h James On Nov 17, 7:00 pm, Mike Alsup wrote: > Try something like this: > > $(document).ready(function() { > var $slideshow = $('#slideshow'); > > $slideshow.cycle({ > fx: 'fade' > }).cycle('pause'); > > $slideshow.hover(function() { > $slideshow.cycle('resume'); > }, > function() { > $slideshow.cycle('pause'); > }); > > }); > > On Nov 17, 1:43 pm, j1042 wrote: > > > > > Hey! > > > Been enjoying the Cycle plugin (http://www.malsup.com/jquery/cycle/) > > but I can't get it do do exactly what I want. > > > This image slideshow plugin comes with built in variables to control > > its operation, for example: > > > $(document).ready(function() { > > $(function () { > > $('.slideshow').cycle({ > > fx: 'fade', > > pause: 1 > > }); > > }); > > > }); > > > in this case the 'pause' variable being true means that the image > > slideshow runs until mouseover the .slideshow div - at which point it > > pauses - and continues on mouseout > > > But I'd like the opposite to occur - no slideshow until mouseover, > > then continue until mouseout. > > > There appears to be no way of achieving this using the current version > > of Cycle - so my question is, is there a way to achieve what I want > > with some more convoluted jQuery and the mouseover/mouseout or hover > > events? > > > Thanks
[jQuery] Re: Table sorter plugin not properly sorting Distance column (ie: 17 Miles)
First, understand *why* it doesn't work: - You add "miles" to the table cell, then Tablesorter treats it as a string value Now that this is understoodd, the solution is to use a custom parser to strip out the label, here is an example http://jsbin.com/unepe/edit On Nov 17, 11:17 am, Yvan wrote: > I'm using the tableshorter plugin on a table which lists multiple > locations, and that contains a "Distance" column which displays > distances in the format of "17 Miles" and "5 miles", etc. > > I have the following javascript in my head section, which defines the > sort order of the 1 column that I want to have sortable (and that > specifies which columns I do not want to make sortable): > > > $(document).ready(function() { > $("#locationsTable").tablesorter( {sortList: > [[1,0]], > headers: { > 0: { sorter: false }, > 2: { sorter: false }, > 3: { sorter: false } > } > } > ); > }); > > > I'm finding that I am not able to properly sort the distance column > when I include the word "Miles" in that table cell. It's only when I > remove the word "Miles" from the table cell that the column sorts > properly. > > How can I fix this? > > Thanks, > - Yvan
[jQuery] Re: Table sorter plugin not properly sorting Distance column (ie: 17 Miles)
First, understand *why* it doesn't work: - You add "miles" to the table cell, then Tablesorter treats it as a string value Now that this is understand, the solution is to use a custom parser to strip out the label, here is an example http://jsbin.com/unepe/edit On Nov 17, 11:17 am, Yvan wrote: > I'm using the tableshorter plugin on a table which lists multiple > locations, and that contains a "Distance" column which displays > distances in the format of "17 Miles" and "5 miles", etc. > > I have the following javascript in my head section, which defines the > sort order of the 1 column that I want to have sortable (and that > specifies which columns I do not want to make sortable): > > > $(document).ready(function() { > $("#locationsTable").tablesorter( {sortList: > [[1,0]], > headers: { > 0: { sorter: false }, > 2: { sorter: false }, > 3: { sorter: false } > } > } > ); > }); > > > I'm finding that I am not able to properly sort the distance column > when I include the word "Miles" in that table cell. It's only when I > remove the word "Miles" from the table cell that the column sorts > properly. > > How can I fix this? > > Thanks, > - Yvan
Re: [jQuery] Re: IE 7 error with $.getJSON data elements
That is odd. jQuery's attr() method goes to some amount of work to try to get the raw content href attribute ('0') instead of the fully qualified URL. But it all boils down to a .getAttribute('href',2) call on the DOM element. An interesting test would be to replace this line: var aIndex = $(this).attr('href'); with: var aIndex = this.getAttribute( 'href', 2 ); In theory, those should do exactly the same thing - in a simple test case I tried, they both returned '0'. What version of jQuery are you using? You could also just remove the extraneous part of the URL with a regular expression: var aIndex = $(this).attr('href').match( /\d+$/ )[0]; I would also convert the result to a number by using the + operator on it, whichever form you use: var aIndex = +$(this).attr('href'); var aIndex = +this.getAttribute( 'href', 2 ); var aIndex = +$(this).attr('href').match( /\d+$/ )[0]; Actually on that last one, since you're going to clean up the URL yourself anyway, you may as well simplify it to: var aIndex = +this.href.match( /\d+$/ )[0]; -Mike On Tue, Nov 17, 2009 at 10:44 AM, roryreiff wrote: > Clicking on the first link (i.e. ): > > http://pomona.edu/dev/home/0 > string > [object Object] > [object Object], [object Object], [object Object], [object Object], > [object Object] > 5 > > I think the problem is in my var aIndex = $(this).attr('href'); > > In IE 7 it is appending the full URL...any ideas how to get around > this? Thanks, > > On Nov 17, 10:37 am, Michael Geary wrote: > > No, the scope of the data parameter is not the problem. The data > parameter > > is already in scope inside your click handler. (Michel, check the code > > carefully - don't you agree? The click handler is nested inside the > getJSON > > callback.) > > > > If it were broken in IE8 as well as IE7, then I would guess that you > > probably have a trailing comma at the end of your data.items array. If > you > > have an array like [ 'a', 'b', ] then IE gives it a length of 3 with an > > undefined element at the end. But that should affect IE8 the same as IE7. > > > > But let's stop guessing. Get in there and have a look at the actual data. > > > > The error is occuring on this line in your click handler: > > > > var aIndexBG = data.items[aIndex].background; > > > > So add this code right before that line: > > > > alert( aIndex ); > > alert( typeof aIndex ); > > alert( data ); > > alert( data.items ); > > alert( data.items.length ); > > alert( data.items[aIndex] ); > > alert( data.items[aIndex].background ); > > > > What do the alerts say? > > > > -Mike > > > > On Tue, Nov 17, 2009 at 10:26 AM, roryreiff wrote: > > > So I guess that is the problem then? How would I work towards a > > > solution in making 'data' available to that .click() function? > > > > > On Nov 17, 10:02 am, Michel Belleville > > > wrote: > > > > Oh, yeah, now I see. > > > > > > Of course data is probably not what you expect where you're reading > it. > > > Why > > > > would it ? It's set in a callback as a function's parameter, it's not > > > meant > > > > to get out of the callback's scope, and even when it would, you don't > > > know > > > > when the callback is triggered, that can be right before, right > after, a > > > > month after, never, depending on how the AJAX call ends. > > > > > > Michel Belleville > > > > > > 2009/11/17 roryreiff > > > > > > > Could it have something to do with the 'data' variable not being > > > > > available to the function that I have placed inside the $.getJSON > > > > > call? Is there a way to force it to pass on/be available to my > > > > > ppButton.click(...) function? This is all I can think of for now. >
[jQuery] Re: jQuery and Cycle plugin
Try something like this: $(document).ready(function() { var $slideshow = $('#slideshow'); $slideshow.cycle({ fx: 'fade' }).cycle('pause'); $slideshow.hover(function() { $slideshow.cycle('resume'); }, function() { $slideshow.cycle('pause'); }); }); On Nov 17, 1:43 pm, j1042 wrote: > Hey! > > Been enjoying the Cycle plugin (http://www.malsup.com/jquery/cycle/) > but I can't get it do do exactly what I want. > > This image slideshow plugin comes with built in variables to control > its operation, for example: > > $(document).ready(function() { > $(function () { > $('.slideshow').cycle({ > fx: 'fade', > pause: 1 > }); > }); > > }); > > in this case the 'pause' variable being true means that the image > slideshow runs until mouseover the .slideshow div - at which point it > pauses - and continues on mouseout > > But I'd like the opposite to occur - no slideshow until mouseover, > then continue until mouseout. > > There appears to be no way of achieving this using the current version > of Cycle - so my question is, is there a way to achieve what I want > with some more convoluted jQuery and the mouseover/mouseout or hover > events? > > Thanks
Re: [jQuery] Re: IE 7 error with $.getJSON data elements
2009/11/17 Michael Geary > No, the scope of the data parameter is not the problem. The data parameter > is already in scope inside your click handler. (Michel, check the code > carefully - don't you agree? The click handler is nested inside the getJSON > callback.) > Apparently. Indenting is such a good habit though... Michel Belleville
[jQuery] Validation and dropdowns
I have several dropdowns in my form. They start on a "please select one" state. How do I make it so that if one of these is selected then it does not trigger validation but kicks back an error? Sarah
[jQuery] jQuery and Cycle plugin
Hey! Been enjoying the Cycle plugin ( http://www.malsup.com/jquery/cycle/ ) but I can't get it do do exactly what I want. This image slideshow plugin comes with built in variables to control its operation, for example: $(document).ready(function() { $(function () { $('.slideshow').cycle({ fx: 'fade', pause: 1 }); }); }); in this case the 'pause' variable being true means that the image slideshow runs until mouseover the .slideshow div - at which point it pauses - and continues on mouseout But I'd like the opposite to occur - no slideshow until mouseover, then continue until mouseout. There appears to be no way of achieving this using the current version of Cycle - so my question is, is there a way to achieve what I want with some more convoluted jQuery and the mouseover/mouseout or hover events? Thanks
[jQuery] Re: Selectors, Escaping special Character in JQuery 1.3.2 not working as expected.
FYI: It was the validate/validation plugin that was breaking my example. When i commented out the include everything worked as expected. I needed to upgraded to the newer version of the validation plugin and everything is back to normal! Too many version dependencies, bah! It's too bad there isn't svn setup (that i know of) which tags all plugins with jQuery core so the versions could be resolved a bit easier. -phil On Nov 17, 9:17 am, phil wrote: > Yes thats true. > > I just tested the exact code I have on jsbin and it worked > fine.http://jsbin.com/uhane source:http://jsbin.com/uhane/edit > I wonder if there is a difference in the included JQuery library on > jsbin and what jQuery currently has on their web site. > > I will try to replace my local copy of jQuery and see if that resolves > this issue. > > thanks. > > On Nov 17, 4:53 am, "Richard D. Worth" wrote: > > > Works for me: > > >http://jsbin.com/izoco > > > source:http://jsbin.com/izoco/edit > > > - Richard > > > On Tue, Nov 17, 2009 at 4:01 AM, phil wrote: > > > I just recently attempted to upgrade from jQuery 1.2.6 to jQuery 1.3.2 > > > and it broke several web pages where my selectors are escaping special > > > characters - the period. > > > > Here is a quick example: > > > > > > > > The selector $("#first\\.name") works in jQuery 1.2.6, but is broken > > > in jQuery 1.3.2. > > > > Is this intentional or a is it a bug? > > > I would be grateful if there is a workaround!
[jQuery] Re: IE 7 error with $.getJSON data elements
Clicking on the first link (i.e. ): http://pomona.edu/dev/home/0 string [object Object] [object Object], [object Object], [object Object], [object Object], [object Object] 5 I think the problem is in my var aIndex = $(this).attr('href'); In IE 7 it is appending the full URL...any ideas how to get around this? Thanks, On Nov 17, 10:37 am, Michael Geary wrote: > No, the scope of the data parameter is not the problem. The data parameter > is already in scope inside your click handler. (Michel, check the code > carefully - don't you agree? The click handler is nested inside the getJSON > callback.) > > If it were broken in IE8 as well as IE7, then I would guess that you > probably have a trailing comma at the end of your data.items array. If you > have an array like [ 'a', 'b', ] then IE gives it a length of 3 with an > undefined element at the end. But that should affect IE8 the same as IE7. > > But let's stop guessing. Get in there and have a look at the actual data. > > The error is occuring on this line in your click handler: > > var aIndexBG = data.items[aIndex].background; > > So add this code right before that line: > > alert( aIndex ); > alert( typeof aIndex ); > alert( data ); > alert( data.items ); > alert( data.items.length ); > alert( data.items[aIndex] ); > alert( data.items[aIndex].background ); > > What do the alerts say? > > -Mike > > On Tue, Nov 17, 2009 at 10:26 AM, roryreiff wrote: > > So I guess that is the problem then? How would I work towards a > > solution in making 'data' available to that .click() function? > > > On Nov 17, 10:02 am, Michel Belleville > > wrote: > > > Oh, yeah, now I see. > > > > Of course data is probably not what you expect where you're reading it. > > Why > > > would it ? It's set in a callback as a function's parameter, it's not > > meant > > > to get out of the callback's scope, and even when it would, you don't > > know > > > when the callback is triggered, that can be right before, right after, a > > > month after, never, depending on how the AJAX call ends. > > > > Michel Belleville > > > > 2009/11/17 roryreiff > > > > > Could it have something to do with the 'data' variable not being > > > > available to the function that I have placed inside the $.getJSON > > > > call? Is there a way to force it to pass on/be available to my > > > > ppButton.click(...) function? This is all I can think of for now.
[jQuery] Re: JQuery - how to fade and loop background style
That works when I click the box. How would I make it work as a slideshow that requires no action and loops indefinitely? On Nov 17, 12:00 pm, "Richard D. Worth" wrote: > jQuery UI effects core adds color animation and class transitions: > > http://jqueryui.com/demos/animate/ > > http://docs.jquery.com/UI/Effects/animate > > You can download it here: > > http://jqueryui.com/download > > just check 'Effects Core' > > - Richard > > On Tue, Nov 17, 2009 at 11:43 AM, Dan wrote: > > Hi All, > > > Is there a way to fade and loop a background-color of a div element? I > > would like it to change every 10 seconds or so, from green to orange > > to purple and then loop back to green and start again. With a fade > > effect. > > > I have searched high and low for a plugin, or tutorial, to no avail. > > > Thanks. > > > Dan
Re: [jQuery] Re: IE 7 error with $.getJSON data elements
No, the scope of the data parameter is not the problem. The data parameter is already in scope inside your click handler. (Michel, check the code carefully - don't you agree? The click handler is nested inside the getJSON callback.) If it were broken in IE8 as well as IE7, then I would guess that you probably have a trailing comma at the end of your data.items array. If you have an array like [ 'a', 'b', ] then IE gives it a length of 3 with an undefined element at the end. But that should affect IE8 the same as IE7. But let's stop guessing. Get in there and have a look at the actual data. The error is occuring on this line in your click handler: var aIndexBG = data.items[aIndex].background; So add this code right before that line: alert( aIndex ); alert( typeof aIndex ); alert( data ); alert( data.items ); alert( data.items.length ); alert( data.items[aIndex] ); alert( data.items[aIndex].background ); What do the alerts say? -Mike On Tue, Nov 17, 2009 at 10:26 AM, roryreiff wrote: > So I guess that is the problem then? How would I work towards a > solution in making 'data' available to that .click() function? > > On Nov 17, 10:02 am, Michel Belleville > wrote: > > Oh, yeah, now I see. > > > > Of course data is probably not what you expect where you're reading it. > Why > > would it ? It's set in a callback as a function's parameter, it's not > meant > > to get out of the callback's scope, and even when it would, you don't > know > > when the callback is triggered, that can be right before, right after, a > > month after, never, depending on how the AJAX call ends. > > > > Michel Belleville > > > > 2009/11/17 roryreiff > > > > > Could it have something to do with the 'data' variable not being > > > available to the function that I have placed inside the $.getJSON > > > call? Is there a way to force it to pass on/be available to my > > > ppButton.click(...) function? This is all I can think of for now. >
Re: [jQuery] Re: IE 7 error with $.getJSON data elements
Well, you can call the click method inside the getJSON callback, that's the most straightforward way to do it, and probably the cleanest. Michel Belleville 2009/11/17 roryreiff > So I guess that is the problem then? How would I work towards a > solution in making 'data' available to that .click() function? > > On Nov 17, 10:02 am, Michel Belleville > wrote: > > Oh, yeah, now I see. > > > > Of course data is probably not what you expect where you're reading it. > Why > > would it ? It's set in a callback as a function's parameter, it's not > meant > > to get out of the callback's scope, and even when it would, you don't > know > > when the callback is triggered, that can be right before, right after, a > > month after, never, depending on how the AJAX call ends. > > > > Michel Belleville > > > > 2009/11/17 roryreiff > > > > > Could it have something to do with the 'data' variable not being > > > available to the function that I have placed inside the $.getJSON > > > call? Is there a way to force it to pass on/be available to my > > > ppButton.click(...) function? This is all I can think of for now. >
[jQuery] Re: Script works in Firefox but not in IE.
Seems like IE is stucked in one of the while loops, but I can't figure out why. Anyone got a hint? On Nov 17, 9:49 am, hagbardceline wrote: > Hi > > The following script works fine on FF but crashes IE (7 + 8). > > - > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";> > http://www.w3.org/1999/xhtml"; xml:lang="en-us"> > > > > src="http://tablesorter.com/jquery-latest.js";> > > > jQuery(function(){ > > var nodes = new Array(); > nodes = $(".modAccordion").children(); > $(".modAccordion").children().remove(); > > var i = 0; > var headerTest = /.(Head)./; > > while(i < nodes.length) > { > var testNode = nodes[i].toString(); > > if((testNode.match(headerTest))){ > $(".modAccordion").append(nodes[i]); > i++; > > var newDiv = document.createElement("div"); > newDiv.className="new"; > > while(i < nodes.length && !((nodes[i].toString()).match > (headerTest))) > { > newDiv.appendChild(nodes[i]); > i++; > } > $(".modAccordion").append(newDiv); > } > > } > > }); > > > > div.new > { > background: #00ff00; > > } > > .modAccordion > { > background: #ff; > > } > > > TableSorter > > > > header 1 > some text > some other text > header 2 > some text > > list element 1 > list element 2 > > header 3 > some text > some other text > some more text > some different text > > > > -- > > Anyone knows how to fix for IE? > > Thx in advance, > hagbard
[jQuery] Re: IE 7 error with $.getJSON data elements
So I guess that is the problem then? How would I work towards a solution in making 'data' available to that .click() function? On Nov 17, 10:02 am, Michel Belleville wrote: > Oh, yeah, now I see. > > Of course data is probably not what you expect where you're reading it. Why > would it ? It's set in a callback as a function's parameter, it's not meant > to get out of the callback's scope, and even when it would, you don't know > when the callback is triggered, that can be right before, right after, a > month after, never, depending on how the AJAX call ends. > > Michel Belleville > > 2009/11/17 roryreiff > > > Could it have something to do with the 'data' variable not being > > available to the function that I have placed inside the $.getJSON > > call? Is there a way to force it to pass on/be available to my > > ppButton.click(...) function? This is all I can think of for now.
Re: [jQuery] Re: IE 7 error with $.getJSON data elements
Oh, yeah, now I see. Of course data is probably not what you expect where you're reading it. Why would it ? It's set in a callback as a function's parameter, it's not meant to get out of the callback's scope, and even when it would, you don't know when the callback is triggered, that can be right before, right after, a month after, never, depending on how the AJAX call ends. Michel Belleville 2009/11/17 roryreiff > Could it have something to do with the 'data' variable not being > available to the function that I have placed inside the $.getJSON > call? Is there a way to force it to pass on/be available to my > ppButton.click(...) function? This is all I can think of for now. > >
[jQuery] Re: IE 7 error with $.getJSON data elements
Could it have something to do with the 'data' variable not being available to the function that I have placed inside the $.getJSON call? Is there a way to force it to pass on/be available to my ppButton.click(...) function? This is all I can think of for now.
[jQuery] Re: IE 7 error with $.getJSON data elements
I am using Firebug, and everything works fine in FF, Safari, Opera, and even IE 8. Something about IE 7 though is throwing that error and I can't for the life of me track what it is. :( On Nov 17, 9:19 am, Michel Belleville wrote: > Well, when I've got an error saying something is null or not an object, and > that very something is obtained from a query response, first thing I do is > checking what was the response. Firebug may help if you're not using it > already, and my shot in the dark here would be to think you've either > received something you didn't expect, or in a format you didn't exepct, or > that the data.items[0].background didn't fit the provided format. > > Michel Belleville > > 2009/11/17 roryreiff > > > //This code is withing a larger function, but the error is coming into > > play when the 'ppButton' is clicked > > // It throws the following error in IE 7 (6 not yet tested): > > // > > // Error: 'data.items[...].background' is null or not an object > > // Code: 0 > > // > > > var PP = $('.pomonaPeople'); > > > $.getJSON("/dev/home/pp.json", > > function(data){ > > PP.css('background', 'url(' + data.items[0].background + > > ' )' ); > > > // create navigation > > var ppButton = $('#pp-nav ul li a'); > > ppButton.qtip({ style: { name: 'pomonastandard', 'font- > > size': '70%', tip: true }, position: { adjust: { mouse: true, x:0, y: > > 0, screen: true }, corner: { target: 'topRight', tooltip: > > 'bottomLeft'}} }); > > var currentPP = PP.find('#pp-0'); > > > ppButton.click( function(event) { > > event.preventDefault(); > > var ppDivs = PP.children('div'); > > var aIndex = $(this).attr('href'); > > var destination = PP; > > destination.append(''); > > var aIndexBG = data.items[aIndex].background; > > destination.css('background', 'url(' + aIndexBG + > > ' )' ); > > // set z-index of current div to be above others, and > > reset rest > > currentPP.css('z-index', '100'); > > currentPP = $('#pp-' + aIndex); > > //console.log(currentPP); > > currentPP.css('z-index', '125'); > > destination.find('.loading').fadeOut(FADE); > > }); > > > PP.find('.loading').fadeOut(FADE); > > > });
[jQuery] Re: IE 7 error with $.getJSON data elements
I am using Firebug, and everything works fine in FF, Safari, Opera, and even IE 8. Something about IE 7 though is throwing that error and I can't for the life of me track what it is. :( On Nov 17, 9:19 am, Michel Belleville wrote: > Well, when I've got an error saying something is null or not an object, and > that very something is obtained from a query response, first thing I do is > checking what was the response. Firebug may help if you're not using it > already, and my shot in the dark here would be to think you've either > received something you didn't expect, or in a format you didn't exepct, or > that the data.items[0].background didn't fit the provided format. > > Michel Belleville > > 2009/11/17 roryreiff > > > //This code is withing a larger function, but the error is coming into > > play when the 'ppButton' is clicked > > // It throws the following error in IE 7 (6 not yet tested): > > // > > // Error: 'data.items[...].background' is null or not an object > > // Code: 0 > > // > > > var PP = $('.pomonaPeople'); > > > $.getJSON("/dev/home/pp.json", > > function(data){ > > PP.css('background', 'url(' + data.items[0].background + > > ' )' ); > > > // create navigation > > var ppButton = $('#pp-nav ul li a'); > > ppButton.qtip({ style: { name: 'pomonastandard', 'font- > > size': '70%', tip: true }, position: { adjust: { mouse: true, x:0, y: > > 0, screen: true }, corner: { target: 'topRight', tooltip: > > 'bottomLeft'}} }); > > var currentPP = PP.find('#pp-0'); > > > ppButton.click( function(event) { > > event.preventDefault(); > > var ppDivs = PP.children('div'); > > var aIndex = $(this).attr('href'); > > var destination = PP; > > destination.append(''); > > var aIndexBG = data.items[aIndex].background; > > destination.css('background', 'url(' + aIndexBG + > > ' )' ); > > // set z-index of current div to be above others, and > > reset rest > > currentPP.css('z-index', '100'); > > currentPP = $('#pp-' + aIndex); > > //console.log(currentPP); > > currentPP.css('z-index', '125'); > > destination.find('.loading').fadeOut(FADE); > > }); > > > PP.find('.loading').fadeOut(FADE); > > > });
Re: [jQuery] IE 7 error with $.getJSON data elements
Well, when I've got an error saying something is null or not an object, and that very something is obtained from a query response, first thing I do is checking what was the response. Firebug may help if you're not using it already, and my shot in the dark here would be to think you've either received something you didn't expect, or in a format you didn't exepct, or that the data.items[0].background didn't fit the provided format. Michel Belleville 2009/11/17 roryreiff > //This code is withing a larger function, but the error is coming into > play when the 'ppButton' is clicked > // It throws the following error in IE 7 (6 not yet tested): > // > // Error: 'data.items[...].background' is null or not an object > // Code: 0 > // > > var PP = $('.pomonaPeople'); > > $.getJSON("/dev/home/pp.json", >function(data){ >PP.css('background', 'url(' + data.items[0].background + > ' )' ); > >// create navigation >var ppButton = $('#pp-nav ul li a'); >ppButton.qtip({ style: { name: 'pomonastandard', 'font- > size': '70%', tip: true }, position: { adjust: { mouse: true, x:0, y: > 0, screen: true }, corner: { target: 'topRight', tooltip: > 'bottomLeft'}} }); >var currentPP = PP.find('#pp-0'); > >ppButton.click( function(event) { > event.preventDefault(); > var ppDivs = PP.children('div'); > var aIndex = $(this).attr('href'); > var destination = PP; > destination.append(''); > var aIndexBG = data.items[aIndex].background; > destination.css('background', 'url(' + aIndexBG + > ' )' ); > // set z-index of current div to be above others, and > reset rest > currentPP.css('z-index', '100'); > currentPP = $('#pp-' + aIndex); > //console.log(currentPP); > currentPP.css('z-index', '125'); > destination.find('.loading').fadeOut(FADE); >}); > >PP.find('.loading').fadeOut(FADE); > >}); >
[jQuery] Re: Selectors, Escaping special Character in JQuery 1.3.2 not working as expected.
Yes thats true. I just tested the exact code I have on jsbin and it worked fine. http://jsbin.com/uhane source: http://jsbin.com/uhane/edit I wonder if there is a difference in the included JQuery library on jsbin and what jQuery currently has on their web site. I will try to replace my local copy of jQuery and see if that resolves this issue. thanks. On Nov 17, 4:53 am, "Richard D. Worth" wrote: > Works for me: > > http://jsbin.com/izoco > > source:http://jsbin.com/izoco/edit > > - Richard > > On Tue, Nov 17, 2009 at 4:01 AM, phil wrote: > > I just recently attempted to upgrade from jQuery 1.2.6 to jQuery 1.3.2 > > and it broke several web pages where my selectors are escaping special > > characters - the period. > > > Here is a quick example: > > > > > > The selector $("#first\\.name") works in jQuery 1.2.6, but is broken > > in jQuery 1.3.2. > > > Is this intentional or a is it a bug? > > I would be grateful if there is a workaround!
[jQuery] IE 7 error with $.getJSON data elements
//This code is withing a larger function, but the error is coming into play when the 'ppButton' is clicked // It throws the following error in IE 7 (6 not yet tested): // // Error: 'data.items[...].background' is null or not an object // Code: 0 // var PP = $('.pomonaPeople'); $.getJSON("/dev/home/pp.json", function(data){ PP.css('background', 'url(' + data.items[0].background + ' )' ); // create navigation var ppButton = $('#pp-nav ul li a'); ppButton.qtip({ style: { name: 'pomonastandard', 'font- size': '70%', tip: true }, position: { adjust: { mouse: true, x:0, y: 0, screen: true }, corner: { target: 'topRight', tooltip: 'bottomLeft'}} }); var currentPP = PP.find('#pp-0'); ppButton.click( function(event) { event.preventDefault(); var ppDivs = PP.children('div'); var aIndex = $(this).attr('href'); var destination = PP; destination.append(''); var aIndexBG = data.items[aIndex].background; destination.css('background', 'url(' + aIndexBG + ' )' ); // set z-index of current div to be above others, and reset rest currentPP.css('z-index', '100'); currentPP = $('#pp-' + aIndex); //console.log(currentPP); currentPP.css('z-index', '125'); destination.find('.loading').fadeOut(FADE); }); PP.find('.loading').fadeOut(FADE); });
Re: [jQuery] JQuery - how to fade and loop background style
jQuery UI effects core adds color animation and class transitions: http://jqueryui.com/demos/animate/ http://docs.jquery.com/UI/Effects/animate You can download it here: http://jqueryui.com/download just check 'Effects Core' - Richard On Tue, Nov 17, 2009 at 11:43 AM, Dan wrote: > Hi All, > > Is there a way to fade and loop a background-color of a div element? I > would like it to change every 10 seconds or so, from green to orange > to purple and then loop back to green and start again. With a fade > effect. > > I have searched high and low for a plugin, or tutorial, to no avail. > > Thanks. > > Dan >
Re: [jQuery] JQuery/Java script Help required
hey thanks for the suggestion i will try this .. brian ally-3 wrote: > > You cannot have more than one element in a page with the same ID. The > entire point of an ID is to *uniquely identify* an element. > >> This page is dynamically generated by ( Template Toolkit ) so I can not >> hardcode the ID. > > Change the server-side code. Give the select elements a classname if > it must be the same and use that in your jquery selector. > > @ Peter-422 Thanks a lot ... it did solve the problem .. to some extent but we Use IE6 and its not working so still trying my luck with JQuery + Java script -- View this message in context: http://old.nabble.com/JQuery-Java-script-Help-required-tp26385438s27240p26393307.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] JQuery - how to fade and loop background style
Hi All, Is there a way to fade and loop a background-color of a div element? I would like it to change every 10 seconds or so, from green to orange to purple and then loop back to green and start again. With a fade effect. I have searched high and low for a plugin, or tutorial, to no avail. Thanks. Dan
Re: [jQuery] Filling an autocomplete field with JS
On Tue, Nov 17, 2009 at 11:08 AM, presto wrote: > > Hi all. > [...] > So, how can I send a "focus and 'un-focus'" "function" to the country > field? > [...] Doing more test, I found that the event that I want to simulate, is a tab after a focus and a double click. Both focus and double click I can already simulate. How can I simulate the tab keypress? (In other words: I want to switch to the next field just like the user would did if he was filling the form manually) I'm trying to use .trigger({type: 'keypress', which: 9}), but this is giving me the error: h.indexOf is not a function http://dev.domain.tld/js/libs/jquery.js Line 11 I'm using jQuery 1.2.6 and autocomplete 1.0.2. What am I missing? regards, -- davi
[jQuery] Re: Konami Code >:]
Love it, although I had to make some modifications to get it to work. Your function without the {} brackets didn't run, also add in the key '13' as this is the enter key (aka start). [code] $(function (){ var press = 0, keys = [38, 38, 40, 40, 37, 39, 37, 39, 66, 65, 13]; $(document).keydown(function (e){ if (e.which == keys[press]) { press++; } else { press = 0; }; if (press == keys.length) {function (){ // your little treat... }; }); }); [/code] On Nov 16, 3:03 pm, Ash wrote: > Every body loves a little treat in their websites... > > Well I believe jQuery holds the PERFECT javascript library for doing > the Konami Code. A fan of Konami, and having such a cool little hidden > feature to your websites, I decided i'd share my code with the world, > or at least > those people who'd like it.. > > Just like the PHP logo change, creativity with this little beauty will > keep your mind going for ever ;) > > [code] > $(function (){ > var press = 0, keys = [38, 38, 40, 40, 37, 39, 37, 39, 66, 65]; > > $(document).keydown(function (e){ > if (e.which == keys[press]) > press++; > else > press = 0; > > if (press == keys.length) > (function (){ > // your little treat... > }); > });}); > > [/code]
[jQuery] Table sorter plugin not properly sorting Distance column (ie: 17 Miles)
I'm using the tableshorter plugin on a table which lists multiple locations, and that contains a "Distance" column which displays distances in the format of "17 Miles" and "5 miles", etc. I have the following javascript in my head section, which defines the sort order of the 1 column that I want to have sortable (and that specifies which columns I do not want to make sortable): $(document).ready(function() { $("#locationsTable").tablesorter( {sortList: [[1,0]], headers: { 0: { sorter: false }, 2: { sorter: false }, 3: { sorter: false } } } ); }); I'm finding that I am not able to properly sort the distance column when I include the word "Miles" in that table cell. It's only when I remove the word "Miles" from the table cell that the column sorts properly. How can I fix this? Thanks, - Yvan
[jQuery] Scrollable Image Gallery - Looks Like a Grid Instead of a Carousel??
Hi everyone, I'm struggling to find something and hoped someone here would be able to help. I'd like to implement a thumbnail gallery in the form of a 4x3 grid (the number of items is irrelevant though) on my web page. I would like to be able to page the grid, so that you could click on left and right hyperlinks to scroll the grid page by page. So if I had 36 images, 12 would be shown at a time, and by clicking on the left / right links the entire page would scroll and present 12 new images. A good example would be the Facebook image gallery when you click on someone photos. It displays thumbnails in a grid form and allows you to scroll the grid back and forth using the numerical hyperlinks. i've seen lots of carousel's which only display a sinle line of thumbnails (or whatever you put into them), but I've not seen anything which handles multiple rows of images? If there's nothing out there really, could someone give me a good idea where to start? Thanks all, apologies for the 'newbie' post. Chubby
[jQuery] getjson request an unavailable page
Hi guys, I write a web page that retrieve the data from a JSON formatted file but when this fiel doesn't exist I can't see any error; how I can handle this situation thanks
[jQuery] Re: Strange behavior experienced when using the show and hide effects
I only posted to jQuery's Google Group. If you're receiving my post via e-mail that means you are somehow subscribed to receive e-mail digests of the posts here in which case you'll have to remove yourself. Sorry. On Nov 13, 11:59 am, Dharshini Nathan wrote: > Please unsubscribe me from your mailing listy. Thank you. > > On Fri, Nov 13, 2009 at 7:31 AM, The alMIGHTY N wrote: > > > I have a page with a DIV at the top that is shown and hidden with the > > jQueryUI show and hide effects. Underneath it is a TABLE whose > > vertical position shifts up and down depending on whether the DIV is > > shown or hidden. > > In Internet Explorer 7, when the hide animation is just about done, > > the TABLE suddenly shifts to a vertical position even lower than when > > the DIV is shown but only for a split second after which it returns > > to > > the spot where it should be. This happens no matter what speed I > > assign to the effect. > > In Firefox 3, when the show animation is in progress, a "memory" of > > the TABLE remains within the DIV even as the TABLE itself is visibly > > shifting downwards on the page. This only seems to happen when the > > table has a lot of row/columns *and* a decent amount of styling > > (background colors, padding, alignment, etc.) - if I use a table with > > no styling and/or few columns and rows, this behavior doesn't > > manifest. It also only happens the first time the show effect occurs. > > I've included the complete HTML/JavaScript/CSS below. Thanks for any > > help! I need it badly because the real page on which this example is > > based is one part of my attempt to convince the company that we > > should > > use jQuery. > > > > > > > > > > body { font-family: Calibri, Arial, Helvetica, > > sans-serif; } > > .data { margin-top: 5px; } > > .data td { padding: 3px 5px; font-size: > > 10pt; } > > .data th { padding: 3px 5px; background-color: > > #003399; font-size: > > 8pt; color: #ff; } > > > > http://ajax.googleapis.com/%0Aajax/libs/jquery/1.3.2/jquery.min.js> > > "> > > http://ajax.googleapis.com/%0Aajax/libs/jqueryui/1.7.2/jquery-ui.min.js> > > "> > > > > $(document).ready(function() { > > $("#toggler").toggle(function() { > > $("#hiddenInPlainSight").show > > ("fast"); > > }, function() { > > $("#hiddenInPlainSight").hide > > ("fast"); > > }); > > }); > > > > > > > > Show > > > > AB > option>CD > > Nothing for right now. > > > value="Cancel"/> > > > > to > type="text"/> > > > cellspacing="0"> > > > > > > Name > > ID > > My Opinion > > Your Opinion > > Original Quantity > > Original Price > > Discounted Quantity > > Discounted Price > > Bulk Quantity > > Bulk Price > > > > > > A > > 1 > > Blah blah blah blah blah > > Yadda yadda yadda yadda yadda > > 123 > > $9.99 > > 123 > > $9.99 > > 123 > > $9.99 > > > > > > B > > 2 > > Blah blah blah blah blah > > Yadda yadda yadda yadda yadda > > 123 > > $9.99 > > 123 > > $9.99 > > 123 > > $9.99 > > > > > > C > > 3 > > Blah blah blah blah blah > > Yadda yadda yadda yadda yadda > > 123 > > $9.99 > > 123 > > $9.99 > > 123 > > $9.99 > > > > > > D > > 4 > > Blah blah blah blah blah > > Yadda yadda yadda yadda yadda > > 123 > > $9.99 > > 123 > > $9.99 > > 123 > > $9.99 > > > > > > E > > 5 > > Blah blah blah blah blah > > Yadda yadda yadda yadda yadda > >
[jQuery] Re: (validate) error in IE7
I couldn't figure out how to include stuff like css and images at that link. http://www.michaelandregina.com/chris/form.html Thanks Mike On Nov 17, 9:43 am, Jörn Zaefferer wrote: > Could you provide some code? A testpage? jsbin.com works great for that. > > Jörn > > On Tue, Nov 17, 2009 at 4:39 PM, dmikester1 wrote: > > Here is the screenshot of the bug or error in IE7. Can anyone help me > > figure this one out? > >http://www.michaelandregina.com/jqueryErrorInIE7.png > > Thanks > > Mike
Re: [jQuery] newbie plugin question
On Mon, Nov 16, 2009 at 7:06 PM, echobase wrote: > > I call the plugin like so: > >
Re: [jQuery] JQuery/Java script Help required
On Tue, Nov 17, 2009 at 2:21 AM, ninadmhatre wrote: > > HI > I am very new to Java scripting. I am stuck at one html page which has 6 > blocks with same ID attribute and options in this blocks > are nothing but the links to different pages ( ALL LINKS ARE UNIQUE ) . You cannot have more than one element in a page with the same ID. The entire point of an ID is to *uniquely identify* an element. > This page is dynamically generated by ( Template Toolkit ) so I can not > hardcode the ID. Change the server-side code. Give the select elements a classname if it must be the same and use that in your jquery selector.
Re: [jQuery] (validate) error in IE7
Could you provide some code? A testpage? jsbin.com works great for that. Jörn On Tue, Nov 17, 2009 at 4:39 PM, dmikester1 wrote: > Here is the screenshot of the bug or error in IE7. Can anyone help me > figure this one out? > http://www.michaelandregina.com/jqueryErrorInIE7.png > Thanks > Mike >
Re: [jQuery] Validation (groups, rules and messages)
It affects the message display, producing only a single error label for a given group. Jörn On Tue, Nov 17, 2009 at 4:35 PM, Atkinson, Sarah < sarah.atkin...@cookmedical.com> wrote: > > So what exactly does the group option do? > > > > On 11/17/09 10:30 AM, "Jörn Zaefferer" > wrote: > > You need to specify the rules for each individual field, here firstname and > lastName. The group name doesn't have any meaning outside the groups-option > itself. > > Jörn > > On Tue, Nov 17, 2009 at 4:23 PM, Atkinson, Sarah < > sarah.atkin...@cookmedical.com> wrote: > > I’m working with the validation plugin > I have a first name and last name field and I want to have these grouped > together with one message. This is what I have: > But the message still isn’t showing. > groups: { >fullName: "firstname lastName", },rules:{fullName: > "required", },messages:{fullName: "Both first and last name > are required", > > > >
[jQuery] (validate) error in IE7
Here is the screenshot of the bug or error in IE7. Can anyone help me figure this one out? http://www.michaelandregina.com/jqueryErrorInIE7.png Thanks Mike
[jQuery] I'm getting what looks like a bug in IE7
Here is the screenshot of the bug or error in IE7. Can anyone help me figure this one out? http://www.michaelandregina.com/jqueryErrorInIE7.png Thanks Mike
Re: [jQuery] Validation (groups, rules and messages)
So what exactly does the group option do? On 11/17/09 10:30 AM, "Jörn Zaefferer" wrote: You need to specify the rules for each individual field, here firstname and lastName. The group name doesn't have any meaning outside the groups-option itself. Jörn On Tue, Nov 17, 2009 at 4:23 PM, Atkinson, Sarah wrote: I'm working with the validation plugin I have a first name and last name field and I want to have these grouped together with one message. This is what I have: But the message still isn't showing. groups: {fullName: "firstname lastName", },rules:{fullName: "required", }, messages:{fullName: "Both first and last name are required",
Re: [jQuery] Validation (groups, rules and messages)
You need to specify the rules for each individual field, here firstname and lastName. The group name doesn't have any meaning outside the groups-option itself. Jörn On Tue, Nov 17, 2009 at 4:23 PM, Atkinson, Sarah < sarah.atkin...@cookmedical.com> wrote: > I’m working with the validation plugin > I have a first name and last name field and I want to have these grouped > together with one message. This is what I have: > But the message still isn’t showing. > groups: { >fullName: "firstname lastName", },rules:{fullName: > "required",},messages:{fullName: "Both first and last name > are required", >
[jQuery] Superfish IE6 Issue
I've finally been able to the get the Superfish plugin script to work on our new website in the nav-bar format www.georgeforeman.co.uk/beta but unfortunatley in IE6 its doesn't seem to work the way it should as the drop down menu list appears under each other until you rollover them and then they snap in to place but this only a selected few drop downs I've tried setting a set with but still nothing any ideas?? Thanks Simon
[jQuery] Validation (groups, rules and messages)
I'm working with the validation plugin I have a first name and last name field and I want to have these grouped together with one message. This is what I have: But the message still isn't showing. groups: {fullName: "firstname lastName", },rules:{fullName: "required",}, messages:{fullName: "Both first and last name are required",
Re: [jQuery] Change all CSS background images url
Why are you using a root-relative URL ? If the entire site is in a folder, and then you move everything into another folder, everything will stay relative. Therefore, having the path as "img" (or whatever the relative path to that folder is) should work, no ? Liam nomen wrote: Hi all: I have a website. All my images are in "/img" directory. Now, my client needs to put the site in a subdirectory, so, my images are now in "/subdir/img". In the future, maybe we have to change the site to another subdirectory. I don´t want to change all my CSS anytime the client changes the subdirectory. So my question is: Is there a simple way to change all CSS background-image property with the next logic: "Change all the existing CSS background-image properties in this way: if the url starts with "/img" change to "/subdir/ img" else do nothing" Thank you for your help in advance. No virus found in this incoming message. Checked by AVG - www.avg.com Version: 8.5.425 / Virus Database: 270.14.67/2506 - Release Date: 11/16/09 07:43:00
[jQuery] Re: confirm does not work
Hi again, Nevermind that, it works afterall. My bandwidth and FF were the actual problem in picking up the modifications i was making to the code. Cheers, God bless jquery ;p On Nov 17, 12:52 pm, Adonis wrote: > Hi, > > My confirm pop up window does not pop up using the code bellow, > * > function initialiseLegendLayerDeletion(project_name, layer_name, > unslug_project_name, unslug_layer_name){ > // This function deletes the corresponding layer - ajax deletion > $("#" + layer_name + "_legend_layer_header_delete_layer").click > (function(){ > if(confirm("Are you sure you want to delete "+unslug_layer_name > +"?")){ > $.ajax({ > type: 'POST', > url: '/deleteLegendLayer/', > data: { layer_name: unslug_layer_name, project_name: > unslug_project_name }, > success: function(data){ > $("#" + project_name + "_" + layer_name + > "_layer_in_legend").remove(); > $("#" + project_name + "_" + layer_name + > "_legend_accodion_layer_entry").remove(); > > // remove all spatial features under this layer from the > associative arrays and the google map > // remove areas from map > createPolygon(project_name, "0", unslug_layer_name, > unslug_project_name); > // remove area from array > delete polygon_assoc_array[unslug_project_name] > [unslug_layer_name]; > > } > }); > } > });} // end of function initialiseLegendLayerDeletion() > > * > > I have tried bind, click, live, $post, $ajax but none of them gives me > a confirmation window when i click on the deletion button.. > > Any suggestions? Thanks in advance!
[jQuery] Re: Integration between different domains.
Take a look at this link, esspecialy part where cURL is mentioned http://techrageo.us/2007/08/03/jquery-makes-ajax-easy-part-1/
[jQuery] Is It Possible For FullCalendar To Work With Multiple Google Calendars?
I have been exploring the FullCalendar plugin (http://arshaw.com/ fullcalendar/), which works nicely. I have been able to display information from one of my Google calendars, but have not had success with multiple calendars. Does anyone know if this is possible? Thanks - george
Re: [jQuery] Re: XML Writing
Is the xml file can be saved as a file? or just change on the fly? On Tue, Nov 17, 2009 at 9:21 PM, g...@iec wrote: > Here is code : > > var xml = {xml content}; > > $(xml).find('{nodename}').text({changed value}); > > This code works fine. > And content should be proper xml and not string. > > On Nov 16, 12:39 pm, Shane wrote: >> Hey guys, >> >> Is it possible to use jQuery to write to XML nodes for example I have: >> >> a >> >> >> I want to do something like: >> $(xml).find('type').text("b"); >> >> This however isn't working. So I was wondering if there was a >> different way to do this. >> >> Thanks, >> Shane. > -- Mufti Ali 087831163105 http://wordtaps.com http://blogfreakz.com
[jQuery] Re: XML Writing
Here is code : var xml = {xml content}; $(xml).find('{nodename}').text({changed value}); This code works fine. And content should be proper xml and not string. On Nov 16, 12:39 pm, Shane wrote: > Hey guys, > > Is it possible to use jQuery to write to XML nodes for example I have: > > a > > > I want to do something like: > $(xml).find('type').text("b"); > > This however isn't working. So I was wondering if there was a > different way to do this. > > Thanks, > Shane.
[jQuery] Re: Newbie Superfish Issues
Any body know where I'm going wrong with Superfish or could it be something else causing the menu not to work on www.georgeforeman.co.uk/beta How is it possible i've got it working on one example and not the other very strange when its the same code Thanks Simon On Nov 16, 12:11 pm, sroyle82 wrote: > Has any body used superfish with the hoverIntent script? > > I've followed the online examples but I'm still seem to be having > problems getting it to work its doesn't appear in IE6 and the rollover > doesn't seem to work > > http://www.georgeforeman.co.uk/beta- Not working > > http://www.esaltoneurope.co.uk/menu- working fine > > any ideas where I'm going wrong?? > > Thanks > Simon
[jQuery] how to parse xml with namespace ?????
Hi all, I have came across an issue related to xml parsing. Here is code for parsing xml with namespace : var data = {xml content}; $(data).find('{namespace}\\:nodename').each(function() { { Code to perform something.} }); This code works fine in IE and FF and xml got parsed as expected. But it is not workng with safari. Can anybody help me out to parse xml with namespaces using jquery so that it work fine in all browsers??? Thanks to all for showing there concern.
[jQuery] Re: BlockUi - blue ring?
If you don't want a wait cursor then just set the css cursor prop: $.blockUI({ css: { cursor: 'default' } }); Mike On Nov 17, 4:05 am, "Jonathan Vanherpe (T & T NV)" wrote: > I don't see a busy cursor in Ubuntu, but I do see it in Win 7 and win XP > (on pretty much any browser). The example page > onhttp://malsup.com/jquery/block/stylesheet.htmlalso seems to do this. So > I guess this is just a Windows thing. > > It doesn't stop you from using your browser or anything so it's mostly a > cosmetic issue. You could try using something other than blockui to show > a modal dialog. > > Jonathan > > > > heohni wrote: > > Well, we are only on localhost right now, but one example is: > >http://www.iwb-stahldesign.de/produkte_blumenkuebelgrau.php > > if you add the item to the shopping cart, you will see it, too. Inside > > the div all is fine, outside, I see the blue ring cursor. > > I am on a windows 7 machine, and I have the same behavoir on all > > browsers, so I guess, you will see the same effect? > > > And the same happen on our localhost example, just with the difference > > that there I see the blue ring also inside the div area. > > > On 17 Nov., 09:30, "Jonathan Vanherpe (T& T NV)" > > wrote: > >> heohni wrote: > >>> Hi, > > >>> I am using theBlockUIin 2 apps. > >>> In the first, The overlay works fine, but as soon as I go with my > >>> mouse outside the div, into the grey area, my mouse pointer turns to a > >>> blue ring (ring of death). > > >>> In my second, I have the blue ring also within my div area. > > >>> What am I doing wrong? > >>> Can someone please help? > > >> A link to the page would be nice. Also some information about the > >> browser and operating system you're using (I suspect you're on Windows > >> as you're using the 'blue something of death' terminology). > > >> Jonathan > > >> -- > >> Jonathan Vanherpe - Tallieu& Tallieu NV - jonat...@tnt.be > > -- > Jonathan Vanherpe - Tallieu & Tallieu NV - jonat...@tnt.be
[jQuery] OK newb question... what is jQuery
Before any one says so, yes I am jumping the gun posting here but I have been looking around and i cant find anything that answers the simple question: What is jQuery - my best guess is that its a library of javascript coding that developers download and sit in their site structure and link HTML code off too to do nifty things. Is that right? i.e. can i download one library and then take different HTML and javascript codes and from different developers and theyll work? -- View this message in context: http://old.nabble.com/OK-newb-question...-what-is-jQuery-tp26390570s27240p26390570.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] Integration between different domains.
Hallo all. I got this problem My web site has this architetcture. The homepage defines a sidebar and a header menu: then is defined an iframe where is loaded the dynamic content. The homepage defines some utility functions that are called from the iframe with this style: parent.myFunction(); This all work but when I try to insert in the iframe a web application that lives on a different domain the calls to the utility functions do not work any more. Is there a security issue in this behaviour? Kind regards Massimo
[jQuery] Integration between different domains.
Hallo all. I got this problem My web site has this architetcture. The homepage defines a sidebar and a header menu: then is defined an iframe where is loaded the dynamic content. The homepage defines some utility functions that are called from the iframe with this style: parent.myFunction(); This all work but when I try to insert in the iframe a web application that lives on a different domain the calls to the utility functions do not work any more. Is there a security issue in this behaviour? Kind regards Massimo
Re: [jQuery] Re: XML Writing
Nice idea, if this can implemented On Tue, Nov 17, 2009 at 4:41 PM, Peter wrote: > > $(function(){ > $('settings').find('type').text("b"); > }); > > > > a > > > You mean that? > > where is your xml? > get by ajax? > inpage? > > On Nov 16, 3:39 pm, Shane wrote: >> Hey guys, >> >> Is it possible to use jQuery to write to XML nodes for example I have: >> >> a >> >> >> I want to do something like: >> $(xml).find('type').text("b"); >> >> This however isn't working. So I was wondering if there was a >> different way to do this. >> >> Thanks, >> Shane. > -- Mufti Ali 087831163105 http://wordtaps.com http://blogfreakz.com e
[jQuery] Re: Problem adding values in select box ()
> but this line $('#state').add(option); is not adding value to the > select box "state" The .add() method only adds the option element to the jQuery object, it doesn't modify the document. You probably wanted this: $('#state').append(option);
[jQuery] Re: simeple drop down menu
YEah i works right on! Thank you, Michel, for helping me debug that stuff.
[jQuery] Re: Document Click triggered onSubmit
> I'm having a bit of trouble understanding why a click event attached > to the document is being triggered when submitting a form through the > enter key. When you press Enter, Firefox (looks like this wasn't tested in IE) triggers the click event on the default submit button. That bubbles up to the document. Put an event handler on the submit button's click and you'll see what I mean.
[jQuery] Re: newbie plugin question
$(document).ready() { should be $(document).ready(function(){ On Nov 17, 8:06 am, echobase wrote: > Hi- > > I'm just getting into jQuery plugins and I wanted to do a sort of > 'hello world' exercise with a barebones plugin template. My template > code is below but I can't get the console.log statement in the setup() > function to show in a firebug console window. IIf I put a console.log > statement immediately following the top line: > > ;(function($) { > console.log('hello world'); > > .it does work. Can someone please tell me what I'm doing wrong? > > I call the plugin like so: > > >