[jQuery] Re: Google Reader style endless scroll library?
In case anyone is looking for the same thing: I have released a jQuery plugin: http://www.beyondcoding.com/2009/01/15/release-jquery-plugin-endless-scroll/ Enjoy! :) Cheers, Fred On Dec 21 2008, 8:47 am, Eeby wrote: > Hey y'all. I'd like to provide "endless scrolling" of search results > in the manner of Google Reader. The thing where an AJAX call loads > more results when you scroll to the bottom of the list of results. A > Google search turned up a lot of articles on the theory of how to do > it. I also searched the jQuery plugin repository. Is there a reliable > library or jQuery plugin that provides this functionality? If not I'll > roll my own. Just thought I'd check first. > > Thanks, > > Ethan
[jQuery] Possible 1.3 bug
I was checking all of my random plugins/scripts to make sure they all work with jQuery 1.3 and I found one that is having problems. An example of it is available at: http://digitalinferno.net/temp/ If you enter some text into the input firebug will report that "filter is not a function" in http://digitalinferno.net/temp/js/jquery.js on line 1961 Anyone know if this is a bug or if I have to change something in my code for the new 1.3 release?
[jQuery] Re: [validate plugin] Conflict in using validation plugin with custom submit code
hi Jorn, Done: http://dev.jquery.com/ticket/3862 On Jan 15, 12:01 am, Jörn Zaefferer wrote: > I agree that the missing submit button is a problem. Could you file a > ticket for that?http://dev.jquery.com/newticket(requires > registration) > > Thanks > Jörn > > > > On Wed, Jan 14, 2009 at 6:33 PM, Fledder wrote: > > > Jorn, > > > Thank you for responding. I seem to have been wrong in the information > > I provided: > > > The form DOES submit, but it does it so fast that it is hard to see. > > Normally the submit would cause a redirect. The reason it is not > > redirecting is because my back-end PHP script relies on the post > > containing the submit button name, which it doesn't. > > > Luckily I can quite easily work around this in my situation. I know > > you are aware of the submit button name issue from other threads in > > this forum. It's perhaps not really a bug, but I would definitely see > > it as an improvement if it would be fixed. > > > Either way, I'm helped for now, thanks again for such a great plugin! > > > On Jan 14, 11:26 am, Jörn Zaefferer > > wrote: > >> Could you post a complete testpage? Looks like your extracts are > >> missing something... > > >> Jörn > > >> On Wed, Jan 14, 2009 at 12:00 AM, Fledder > >> wrote: > > >> > hi, > > >> > Like others I seem to have ran into the "double-click to submit > >> > problem". Allow me to explain: > > >> > I have a registration form which validates just fine using the > >> > excellent validate plugin. It's working perfectly. However, I now want > >> > to run some custom code after the validation event. Specifically, I > >> > want to disable the submit button when validation is passed. After > >> > that, a normal post should follow to the server, no Ajax post. > > >> > My first try was to do this: > > >> > // disable the submit button upon submit event > >> > $("#frmEditUser").submit( > >> > function() { > >> > $("#submSave").attr("disabled","true").attr("value", "Updating, > >> > please wait..."); > >> > } > >> > ); > > >> > // validation code follows here > >> > $("#frmEditUser").validate({ > >> > .. > > >> > This indeed changes the submit button and validation still works. > >> > However, it does not submit the form to the server, instead, nothing > >> > happens. My 2nd try was to use the validation plugin's submitHandler. > >> > Mind you this code is a bit long, but I think only the bottom part is > >> > relevant: > > >> > $("#frmEditUser").validate({ > >> > onkeyup:false, > >> > rules: { > >> > username: { > >> > required:true, > >> > minlength:5, > >> > maxlength:45, > >> > validChars:true, > >> > > >> > usernameCheck:[$("#username").val(),oldusername] // remote check > >> > for duplicate username > >> > } > >> > }, > >> > messages: { > >> > username: { > >> > required: "username is required.", > >> > minlength: jQuery.format("username must > >> > be at least {0} characters > >> > in length."), > >> > maxlength: jQuery.format("username can > >> > not exceed {0} characters > >> > in length."), > >> > validChars: "please supply valid > >> > characters only.", > >> > usernameCheck:"this username is already > >> > in use." > >> > } > >> > } > >> > , > >> > submitHandler: function(form) { > >> > // do other stuff for a valid form > >> > > >> > $("#submSave").attr("disabled","true").attr("value", "Updating, > >> > please wait..."); > >> > form.submit(); > >> > } > > >> > }); > > >> > This approach I have seen elsewhere in the forum, but it does not work > >> > for me. Validation runs fine, yet when the form is valid it once more > >> > does not actually post it to the server. It does post when I double- > >> > click (only when I uncomment the button-disabling code, otherwise I > >> > cannot double-click). > > >> > So my question in general is: how can I have my own custom submit code > >> > that does not conflict with the validation plugin and that does an > >> > actual post? I thoroughly looked through the forum but I still do not > >> > see the solution. > > >> > I will be very grateful for a solution, I've spent so many precious > >> > hours on accomplishing such a small thing (disabling a submit button). > >> > Thanks in advance!- Hide quoted text - > > - Show quoted text -
[jQuery] Re: $("area") not working in IE (sorry if this is a repost)
Let me try to clear this up in FF when you hover over a state (an "area" element) one (or more) of the images below should get a border around them, however, in IE nothing happens.. and I put an alert box in to see if anything was going on when you hover a state but in IE the alert box never showed, and in FF the alert did show up. -c On Jan 14, 9:36 pm, Chrisw wrote: > Sorry about all the alert boxes they should be gone now, also thank > you for the shorter code I was going to make the code shorter once I > got this error worked out and you just saved me sometime ;) ... but I > still have the same issue I cannot get $("area").hover(or mouseover) > to work in IE. > > On Jan 14, 9:00 pm, James Van Dyke wrote: > > > Ok... that's a hard page to get away from with all those alert boxes. > > I know... no Firebug in IE. Poo. > > > I believe that "class" is not what IE calls that attribute. For > > instance, element.class will return nothing. element.className is the > > correct property. Try that. > > > Plus, you could shorten your code and make it a bit more readable: > > > $("area").mouseover( function(){ > > $("#" . $(this).attr("class")).addClass('selected');}.mouseout( > > function() { > > > $("#" . $(this).attr("class")).removeClass('selected'); > > > }; > > > Let me know how that works out. > > > On Jan 14, 6:30 pm, Chrisw wrote: > > > > sorry if this is a repost but I didn't see it in the group and I > > > didn't get a copy in my email. I am working with an image map and i am > > > using the maphilight plugin and I want to add a border to an image > > > below the image map when a user hovers over an area (based on the > > > iamges ID and the area's class)(see code below) I got it to work in FF > > > but I cannot get it to work in IE. Any help? > > > > URL:http://oregonstate.edu/admissions/firstyear/recruitmap/map/ > > > > Code: > > > $("area").hover(function(){ > > > var stateClass; > > > stateClass = $(this).attr("class"); > > > var stateClassQuery; > > > stateClassQuery = "#"+stateClass; > > > alert(stateClassQuery);//for testing > > > $(stateClassQuery).addClass('selected'); > > > //mouse out > > > }, > > > function(){ > > > var stateClass; > > > stateClass = $(this).attr("class"); > > > var stateClassQuery; > > > stateClassQuery = "#"+stateClass; > > > > > > $(stateClassQuery).removeClass('selected'); > > > }
[jQuery] Re: $("area") not working in IE (sorry if this is a repost)
Sorry about all the alert boxes they should be gone now, also thank you for the shorter code I was going to make the code shorter once I got this error worked out and you just saved me sometime ;) ... but I still have the same issue I cannot get $("area").hover(or mouseover) to work in IE. On Jan 14, 9:00 pm, James Van Dyke wrote: > Ok... that's a hard page to get away from with all those alert boxes. > I know... no Firebug in IE. Poo. > > I believe that "class" is not what IE calls that attribute. For > instance, element.class will return nothing. element.className is the > correct property. Try that. > > Plus, you could shorten your code and make it a bit more readable: > > $("area").mouseover( function(){ > $("#" . $(this).attr("class")).addClass('selected');}.mouseout( > function() { > > $("#" . $(this).attr("class")).removeClass('selected'); > > }; > > Let me know how that works out. > > On Jan 14, 6:30 pm, Chrisw wrote: > > > sorry if this is a repost but I didn't see it in the group and I > > didn't get a copy in my email. I am working with an image map and i am > > using the maphilight plugin and I want to add a border to an image > > below the image map when a user hovers over an area (based on the > > iamges ID and the area's class)(see code below) I got it to work in FF > > but I cannot get it to work in IE. Any help? > > > URL:http://oregonstate.edu/admissions/firstyear/recruitmap/map/ > > > Code: > > $("area").hover(function(){ > > var stateClass; > > stateClass = $(this).attr("class"); > > var stateClassQuery; > > stateClassQuery = "#"+stateClass; > > alert(stateClassQuery);//for testing > > $(stateClassQuery).addClass('selected'); > > //mouse out > > }, > > function(){ > > var stateClass; > > stateClass = $(this).attr("class"); > > var stateClassQuery; > > stateClassQuery = "#"+stateClass; > > $(stateClassQuery).removeClass('selected'); > > }
[jQuery] Re: How to use the simple modal if there are two modal windows need be pop-up on ready method?
SimpleModal does not currently support multiple dialogs being displayed at the same time. Is that what you want? On Jan 14, 3:14 pm, camel wrote: > Hi all > How to use the simple modal if there are two modal windows need > be pop-up on ready method? > I use the confirm style of simple modal and only the fist window can > be pop-up, the second doesn't work. > thanks for your help. > thanks > Camel > > BTW: the code of javascript is following > > > $(document).ready(function(){ > $('#confirm').modal({ > close:false, > position: ["20%",], > overlayId:'confirmModalOverlay', > containerId:'confirmModalContainer', > onShow: function (dialog) { > dialog.data.find('.yes').click(function () { > alert("click Yes in the confirm > window."); > $.modal.close(); > }); > } > }); > }); > $(document).ready(function(){ > $('#duplicated').modal({ > close:false, > position: ["20%",], > overlayId:'confirmModalOverlay', > containerId:'confirmModalContainer', > onShow: function (dialog) { > dialog.data.find('.yes').click(function () { > alert("click Yes"); > $.modal.close(); > }); > } > }); > }); >
[jQuery] Re: getJSON - how to retrieve plain text?
It's almost certainly giving you an error about cross-domain XHR requests. Simply, you can't call URL's that start with "http://"; or else it will throw an error. Someone else may know how to get around that, but if you're referring to your own host, just use a relative path. To debug the issue, you may just want to wrap the getJSON() call inside a try block and catch any errors. Then, you can just use an alert box to read the message. If the message is too long, use jQuery to insert it inside an existing visible element. Good luck. On Jan 14, 7:08 pm, MorningZ wrote: > "So i want to see what the plaintext is that's returned in the success > callback" > > Use Fiddler (http://www.fiddlertool.com) and it will show you exactly > what IE is seeing when it makes the AJAX request and gets a result > back > > On Jan 14, 6:51 pm, Rene Veerman wrote: > > > I have a getJSON call that works fine in FF, but bugs in IE. > > > I get no data. :( > > > So i want to see what the plaintext is that's returned in the success > > callback.. > > > Using the new 1.3 jQuery, btw.. > > > code: > > > var rc = $('select#regions_countries')[0]; > > var rr = $('select#regions_regions')[0]; > > var url = > > 'http://www.myhost.com/members/ajax_fetch_regions_for_countries.php'; > > > var countries = []; > > for (var i=0; i > if (rc.options[i].selected) { > > countries[countries.length] = rc.options[i].text; > > } > > }; > > > $.getJSON (url, {countries:countries.join('|-|')}, function (data, ts) { > > var regions = data.regions.split('|-|').sort(); > > > var html = ''; > > for (var i=0; i > html+=' > value="'+regions[i].replace(/\s\(.*\)/,'')+'">'+regions[i]+''; > > } > > rr.innerHTML = html; > > > }); > >
[jQuery] Re: Weirdest thing on Firefox 3 on MacOSX
I still desperately need help for this, since I dont have Mac to test and debug it. If you can help please let me know, I will pay for your time or donate the amount to jquery, whichever method you wants. Thanks so much for your help Regards Raine On Jan 13, 6:01 pm, yellow1912 wrote: > I encounter a rather weird problem where my plugin would run on all > platforms except Firefox 3 on MacOSX, and since I don't have Mac I can > not debug it. > (this plugin uses jquery 1.2.6 and jq form, jq validation and > livequery plugins.) > > This is still under development I can not post the link directly here, > but if you can email me at yellow1...@gmail.com I will send you a link > along with the steps to reproduce the problem right away > > I desperately need help here, I suspect this is somewhat a small > glide, if you have firebug and can catch the error message on it then > it would be easy to work it out. If you can just check the problem and > send me the bugs reported that would help greatly as well. > > I understand that this will cost your time and effort, and I'm willing > to pay for your help. > > Thank you all! Love Jquery (\/) > > Regards > > Raine
[jQuery] Re: Condense this function
Let me know what's not working, and maybe I can help you out. I don't have firebug handy, so I didn't test it. On Jan 14, 11:44 pm, DJCarbon43 wrote: > I haven't gotten it working yet, but I understand the concept, and its > brilliant! > > Thank you very much! > > On Jan 14, 11:28 pm, James Van Dyke wrote: > > > $(function() { > > var i, numStickies = 9; > > for (i = 1; i <= numStickies; i += 1) { > > setTimeout( function() { > > $(".sticky" + i + ":hidden").fadeIn(500); > > }, 100 * i); > > } > > > }); > > > Not sure if that's faster, but it's shorter and easier to change. > > > On Jan 14, 11:19 pm, DJCarbon43 wrote: > > > > Being a bit of a newfie, I was wondering how this function could be > > > condensed: > > > > $(document).ready = > > > setTimeout(function(){ $(".sticky1:hidden").fadeIn(500); }, 100); > > > setTimeout(function(){ $(".sticky2:hidden").fadeIn(500); }, 200); > > > setTimeout(function(){ $(".sticky3:hidden").fadeIn(500); }, 300); > > > setTimeout(function(){ $(".sticky4:hidden").fadeIn(500); }, 400); > > > setTimeout(function(){ $(".sticky5:hidden").fadeIn(500); }, 500); > > > setTimeout(function(){ $(".sticky6:hidden").fadeIn(500); }, 600); > > > setTimeout(function(){ $(".sticky7:hidden").fadeIn(500); }, 700); > > > setTimeout(function(){ $(".sticky8:hidden").fadeIn(500); }, 800); > > > setTimeout(function(){ $(".sticky9:hidden").fadeIn(500); }, 900); > > > > Is it possible, or is that as clean as can be? fadein time is the same > > > accross all sticky classes, but the timeout must be different for each. > >
[jQuery] Re: Standards box model
I've always used transitional and had no problems, even with 1.3. Transitional is still a standard, but let's some things slide. However, if you're so concerned with bugs, you may want to wait until 1.3.1 or later. 1.3 is bound to have some lurking issues. On Jan 15, 12:15 am, Karl Rudd wrote: > Try it and see what Internet Explorer 6 does. > > Karl Rudd > > On Thu, Jan 15, 2009 at 3:53 PM, Ami wrote: > > > So you for you fast answer. > > 5 point > > (: > > > Do I must to change all my pages from Transitional to strict? > > Or can I leave it as Transitional > > (I afraid from CSS bugs, so i don't want to cahnge) > > > On 15 ינואר, 06:48, Karl Rudd wrote: > >> That will work, but you do not need to change to using XHTML. You > >> could use HTML Strict: > > >> >> "http://www.w3.org/TR/html4/strict.dtd";> > > >> More information here: > >> http://en.wikipedia.org/wiki/Quirksmode > > >> Karl Rudd > > >> On Thu, Jan 15, 2009 at 3:08 PM, Ami wrote: > > >> > Hello, > >> > Sorry about my grammar, English isn't my tang. > > >> > I read in the Jquery 1.3:release notes, that I must use W3c standards > >> > mode. > >> > I tried to understand what it's mean. > > >> > Now my HTML start like that: > >> > >> > dir="rtl"> > > >> > DO I need to replace it to this: (Like in Jquery website) > >> > >> > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> > > >> > Thank you. > >
[jQuery] Re: Standards box model
Try it and see what Internet Explorer 6 does. Karl Rudd On Thu, Jan 15, 2009 at 3:53 PM, Ami wrote: > > So you for you fast answer. > 5 point > (: > > Do I must to change all my pages from Transitional to strict? > Or can I leave it as Transitional > (I afraid from CSS bugs, so i don't want to cahnge) > > On 15 ינואר, 06:48, Karl Rudd wrote: >> That will work, but you do not need to change to using XHTML. You >> could use HTML Strict: >> >> > "http://www.w3.org/TR/html4/strict.dtd";> >> >> More information here: >> http://en.wikipedia.org/wiki/Quirksmode >> >> Karl Rudd >> >> >> >> On Thu, Jan 15, 2009 at 3:08 PM, Ami wrote: >> >> > Hello, >> > Sorry about my grammar, English isn't my tang. >> >> > I read in the Jquery 1.3:release notes, that I must use W3c standards >> > mode. >> > I tried to understand what it's mean. >> >> > Now my HTML start like that: >> > > > dir="rtl"> >> >> > DO I need to replace it to this: (Like in Jquery website) >> > > >"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> >> >> > Thank you.
[jQuery] Re: IE Problem with (function($)
The initial (function($) { was never closed. Here's how I formatted it so everything lines up: (function($){ var EYE = window.EYE = (function() { var _registered = { init: [] }; return { init: function() { $.each(_registered.init, function(nr, fn) { fn.call(); }); }, extend: function(prop) { for (var i in prop) { if (prop[i] != undefined) { this[i] = prop[i]; } } }, register: function(fn, type) { if (!_registered[type]) { _registered[type] = []; } _registered[type].push(fn); } }; })(); $(EYE.init); })(jQuery); I think that's about the most obfuscated thing I've seen this week. I hope you're doing something cool. Let us know if that helps. On Jan 14, 11:57 pm, "Sagar Arya" wrote: > Hello, I tried changing the braces.. It seems they were proper... > Here i am attaching all the files... Can anyone help me out pls... its > perfectly running in mozilla, chrome.. but not in IE.. :( > > Cheers ! > Sagar > > On Wed, Jan 14, 2009 at 12:08 PM, Sagar Arya wrote: > > hey thanks so much.. :-) > > > Cheers ! > > Aryan > > > On Wed, Jan 14, 2009 at 10:26 AM, Karl Swedberg > > wrote: > > >> good eye, Ricardo! thanks for the back up. :-) > > >> --Karl > > >> > >> Karl Swedberg > >>www.englishrules.com > >>www.learningjquery.com > > >> On Jan 13, 2009, at 5:54 PM, Ricardo Tomasi wrote: > > >> You're missing a parenthesis when closing the anonymous function: > > >> }(); should be })(); > > >> And I'm guessing '$' is there for jQuery, so that should actually be > > >> })(jQuery); > > >> - ricardo > > >> On Jan 13, 3:56 pm, "Sagar Arya" wrote: > > >> may be i should check with the other files and let you know... thanks for > > >> the information.. > > >> Cheers ! > > >> Aryan > > >> On Tue, Jan 13, 2009 at 7:06 PM, Karl Swedberg >> >wrote: > > >> I'm not seeing anything obvious. Taking a stab in the dark here ... I've > > >> received a similar error in the past when a reference to one of my > > >> JavaScript files was resulting in a 404. The browser would try to parse > >> the > > >> file as JavaScript, but of course it would be met with a syntax error on > > >> line 1. Is it possible that the problem is not with this file, but with > > >> another one that you're trying to include? Just a guess. > > >> --Karl > > >> > > >> Karl Swedberg > > >> www.englishrules.com > > >> www.learningjquery.com > > >> On Jan 13, 2009, at 5:35 AM, Aryan wrote: > > >> I have a problem with Internet Explorer ( all versions ) . The > > >> following is my JQuery Code , which executes perfectly in mozilla and > > >> chrome.. But it doesn't work in Internet Explorer. > > >> It says : Syntax error ( line 1 )... Can anyone help me out here.. > > >> Thanks for your time in reading this. > > >> (function($){ > > >> var EYE = window.EYE = function() { > > >> var _registered = { > > >> init: [] > > >> }; > > >> return { > > >> init: function() { > > >> $.each(_registered.init, function(nr, fn){ > > >> fn.call(); > > >> }); > > >> }, > > >> extend: function(prop) { > > >> for (var i in prop) { > > >> if (prop[i] != undefined) { > > >> this[i] = prop[i]; > > >> } > > >> } > > >> }, > > >> register: function(fn, type) { > > >> if (!_registered[type]) { > > >> _registered[type] = []; > > >> } > > >> _registered[type].push(fn); > > >> } > > >> }; > > >> }(); > > >> $(EYE.init); > > >> })(jQuery); > > > > colorpicker.js > 22KViewDownload > > eye.js > < 1KViewDownload > > jquery.js > 136KViewDownload > > layout.js > 2KViewDownload > > utils.js > 9KViewDownload
[jQuery] Re: $("area") not working in IE (sorry if this is a repost)
Ok... that's a hard page to get away from with all those alert boxes. I know... no Firebug in IE. Poo. I believe that "class" is not what IE calls that attribute. For instance, element.class will return nothing. element.className is the correct property. Try that. Plus, you could shorten your code and make it a bit more readable: $("area").mouseover( function(){ $("#" . $(this).attr("class")).addClass('selected'); }.mouseout( function() { $("#" . $(this).attr("class")).removeClass('selected'); }; Let me know how that works out. On Jan 14, 6:30 pm, Chrisw wrote: > sorry if this is a repost but I didn't see it in the group and I > didn't get a copy in my email. I am working with an image map and i am > using the maphilight plugin and I want to add a border to an image > below the image map when a user hovers over an area (based on the > iamges ID and the area's class)(see code below) I got it to work in FF > but I cannot get it to work in IE. Any help? > > URL:http://oregonstate.edu/admissions/firstyear/recruitmap/map/ > > Code: > $("area").hover(function(){ > var stateClass; > stateClass = $(this).attr("class"); > var stateClassQuery; > stateClassQuery = "#"+stateClass; > alert(stateClassQuery);//for testing > $(stateClassQuery).addClass('selected'); > //mouse out > }, > function(){ > var stateClass; > stateClass = $(this).attr("class"); > var stateClassQuery; > stateClassQuery = "#"+stateClass; > $(stateClassQuery).removeClass('selected'); > }
[jQuery] Re: Standards box model
So you for you fast answer. 5 point (: Do I must to change all my pages from Transitional to strict? Or can I leave it as Transitional (I afraid from CSS bugs, so i don't want to cahnge) On 15 ינואר, 06:48, Karl Rudd wrote: > That will work, but you do not need to change to using XHTML. You > could use HTML Strict: > > "http://www.w3.org/TR/html4/strict.dtd";> > > More information here: > http://en.wikipedia.org/wiki/Quirksmode > > Karl Rudd > > > > On Thu, Jan 15, 2009 at 3:08 PM, Ami wrote: > > > Hello, > > Sorry about my grammar, English isn't my tang. > > > I read in the Jquery 1.3:release notes, that I must use W3c standards > > mode. > > I tried to understand what it's mean. > > > Now my HTML start like that: > > > dir="rtl"> > > > DO I need to replace it to this: (Like in Jquery website) > > > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> > > > Thank you.
[jQuery] Re: updating flash after changing flashvars
No idea why. You should be able to work around it by setting the FlashVars "attribute" directly: $("#playersettings")[0].FlashVars = "color=00"; Karl Rudd On Thu, Jan 15, 2009 at 10:11 AM, EugeneS wrote: > > Hello, > > i have embed flash element on the page > it looks like > wmode="transparent" FlashVars="color=FF" > > > if i'm trying to change the FlashVars with new value it doesnt seem to > be working but i see that new values was implemented > >alert($("#playersettings").attr("FlashVars")); >$("#playersettings").attr("FlashVars", "color=00"); >alert($("#playersettings").attr("FlashVars")); > > if i'm trying to change code manually in FireBug i see that Flash > color canged ... but by means of Jquery it doesnt work ... why ? > > any ideas how to make it working ? > > Thanks. >
[jQuery] Re: Standards box model
That will work, but you do not need to change to using XHTML. You could use HTML Strict: http://www.w3.org/TR/html4/strict.dtd";> More information here: http://en.wikipedia.org/wiki/Quirksmode Karl Rudd On Thu, Jan 15, 2009 at 3:08 PM, Ami wrote: > > Hello, > Sorry about my grammar, English isn't my tang. > > I read in the Jquery 1.3:release notes, that I must use W3c standards > mode. > I tried to understand what it's mean. > > Now my HTML start like that: > dir="rtl"> > > > DO I need to replace it to this: (Like in Jquery website) > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> > > > Thank you. >
[jQuery] Re: why i dont see my post
On Jan 14, 2009, at 6:19 PM, Eugene Sosnovschi wrote: I’m trying to create my post with a question but I don’t see it in the list of themes … why ? My nickname “seugenev” Eugene. The list is moderated for new users. --Karl Karl Swedberg www.englishrules.com www.learningjquery.com
[jQuery] Re: Condense this function
I haven't gotten it working yet, but I understand the concept, and its brilliant! Thank you very much! On Jan 14, 11:28 pm, James Van Dyke wrote: > $(function() { > var i, numStickies = 9; > for (i = 1; i <= numStickies; i += 1) { > setTimeout( function() { > $(".sticky" + i + ":hidden").fadeIn(500); > }, 100 * i); > } > > }); > > Not sure if that's faster, but it's shorter and easier to change. > > On Jan 14, 11:19 pm, DJCarbon43 wrote: > > > > > Being a bit of a newfie, I was wondering how this function could be > > condensed: > > > $(document).ready = > > setTimeout(function(){ $(".sticky1:hidden").fadeIn(500); }, 100); > > setTimeout(function(){ $(".sticky2:hidden").fadeIn(500); }, 200); > > setTimeout(function(){ $(".sticky3:hidden").fadeIn(500); }, 300); > > setTimeout(function(){ $(".sticky4:hidden").fadeIn(500); }, 400); > > setTimeout(function(){ $(".sticky5:hidden").fadeIn(500); }, 500); > > setTimeout(function(){ $(".sticky6:hidden").fadeIn(500); }, 600); > > setTimeout(function(){ $(".sticky7:hidden").fadeIn(500); }, 700); > > setTimeout(function(){ $(".sticky8:hidden").fadeIn(500); }, 800); > > setTimeout(function(){ $(".sticky9:hidden").fadeIn(500); }, 900); > > > Is it possible, or is that as clean as can be? fadein time is the same > > accross all sticky classes, but the timeout must be different for each.
[jQuery] Re: Issue upgrading to 1.3
Try $("#emilyLogin:not(.loggedIn), #joeLogin:not(.loggedIn)").click( function(){} ); I'm thinking that the nested IDs are causing issues that the new selector engine can't handle. Since IDs are supposed to be unique per page, listing a hierarchy is unnecessary. Multiple IDs on a page would violate W3C standards. On Jan 14, 3:32 pm, "Joe Morgan" wrote: > Hello, > > When I attempt to upgrade my site from 1.2.6 to 1.3, I get an unresponsive > script error that causes my browser (both IE7 and FF3) to hang if the script > is not stopped. > > I've tracked down the bit of script causing the problem: > $("ul#loginSection li#emilyLogin:not(.loggedIn), ul#loginSection > li#joeLogin:not(.loggedIn)").click( > function(){} > ); > As you can see, the problem exists even when the function defined for the > click event is empty, leading me to wonder if it is some problem in the CSS > selector that is being used, given the engine changes from 1.2.6 to 1.3. Am > I doing something incorrectly? > > - Joe
[jQuery] Re: The new core LIVE.
Thank you. Do you know also about the standards model? that I asked before? Link to the question: http://groups.google.com/group/jquery-en/browse_thread/thread/6545a6ced519de33# On 15 ינואר, 06:36, Karl Rudd wrote: > Yes. > > Karl Rudd > > > > On Thu, Jan 15, 2009 at 3:10 PM, Ami wrote: > > > The new core LIVE. > > > Hello. > > Can I use a namespace with live? > > $.live('click.fuc1',function1 }; > > $.live('click.fun2'); > > > $.die('click.func1');
[jQuery] Re: The new core LIVE.
Yes. Karl Rudd On Thu, Jan 15, 2009 at 3:10 PM, Ami wrote: > > The new core LIVE. > > Hello. > Can I use a namespace with live? > $.live('click.fuc1',function1 }; > $.live('click.fun2'); > > $.die('click.func1'); >
[jQuery] Re: [ TR.click not work in Firefox]
Trying changing: x.css("background-color","ee"); to: x.css("background-color","#ee"); Karl Rudd On Thu, Jan 15, 2009 at 10:15 AM, Lord Gustavo Miguel Angel wrote: > hi, > > Look this do not work in firefox, in IE yes. why? > > Thank´s > > > -- index.html - > > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";> > http://www.w3.org/1999/xhtml";> > > > > src="jvs/jquery-1.2.6.js"> > src="jvs/funciones.js"> > > Documento sin título > > > > > > > > t1 c1 > t1 c2 > t1 c3 > > > t2 c1 > t2 c2 > t2 c3 > > > t3 c1 > t3 c2 > t3 c3 > > > > > > > EOF --- > > -funciones.js--- > // JavaScript Document > var x; > x=$(document); > x.ready(inicializarEventos); > > function inicializarEventos() > { > var x; > x=$("tr"); > x.click(presionFila); > } > > function presionFila() > { > var x; > x=$(this); > x.css("background-color","ee"); > } > - EOF
[jQuery] Re: Condense this function
$(function() { var i, numStickies = 9; for (i = 1; i <= numStickies; i += 1) { setTimeout( function() { $(".sticky" + i + ":hidden").fadeIn(500); }, 100 * i); } }); Not sure if that's faster, but it's shorter and easier to change. On Jan 14, 11:19 pm, DJCarbon43 wrote: > Being a bit of a newfie, I was wondering how this function could be > condensed: > > $(document).ready = > setTimeout(function(){ $(".sticky1:hidden").fadeIn(500); }, 100); > setTimeout(function(){ $(".sticky2:hidden").fadeIn(500); }, 200); > setTimeout(function(){ $(".sticky3:hidden").fadeIn(500); }, 300); > setTimeout(function(){ $(".sticky4:hidden").fadeIn(500); }, 400); > setTimeout(function(){ $(".sticky5:hidden").fadeIn(500); }, 500); > setTimeout(function(){ $(".sticky6:hidden").fadeIn(500); }, 600); > setTimeout(function(){ $(".sticky7:hidden").fadeIn(500); }, 700); > setTimeout(function(){ $(".sticky8:hidden").fadeIn(500); }, 800); > setTimeout(function(){ $(".sticky9:hidden").fadeIn(500); }, 900); > > Is it possible, or is that as clean as can be? fadein time is the same > accross all sticky classes, but the timeout must be different for each.
[jQuery] Problems with the New API Browser
Does anyone else find the new API browser to be a bit cumbersome? My gripes: 1) No "back" link at top of vertical navigation list. You must click the category to cancel your choice and essentially go back. However, this isn't very intuitive and there aren't any affordances to this behavior save for a small 'x' in the highlighted category box that doesn't do anything on hover or even have a tooltip. 2) The browser's back button is broken. Kind of a big annoyance when you're not used to the application. 3) Recovering from a mistake is more punishing than it should be. Clicking on a category hide the other categories. Since the title of the category moved from under your mouse, you now have to scan to the top of the list. Once you make sure you're in the category you meant to click on, but don't find the function you were looking for, you click the category name and wait as everything moves around, then repeat scanning through list again. A good example of this is trying to find an unfamiliar selector in the Selectors category. 4) Little distinction between categories, subcategories, and items. They're all the same color and categories and subcategories share the same faded 'x' icon. The only difference is that the category has bold text and the subcategory has a white line under the box, but not between it and its category. 5) When hovering over a list of options for a function (e.g., $.ajax) only the item you're hovering over has full opacity making the others hard to read. I'm ok with the distinction, but I think it's a little extreme. I found myself avoiding hovering over the list, which is hard since I tend to scan the page with my eyes as my mouse follows my line of sight. Try scrolling through the options for $.ajax while trying to read them. 6) The window title changes when viewing an item, which makes one think that the URL will map to that page. However, the URL does not change and I can't find a permanent link to paste to a co-worker. Don't get me wrong, I think Remy has made a great step towards a better API, but design efforts seem to have favored neat effects over human factors. I deal with a lot of these design issues at work so I tend to have a keen eye for these things and can be too picky at times. Has anyone else been bothered by this? If not, what do you like or what makes up for the negatives? Maybe we can compile a list of existing *good* things as well so that those features can be brought to the fore while the problems are resolved.
[jQuery] Condense this function
Being a bit of a newfie, I was wondering how this function could be condensed: $(document).ready = setTimeout(function(){ $(".sticky1:hidden").fadeIn(500); }, 100); setTimeout(function(){ $(".sticky2:hidden").fadeIn(500); }, 200); setTimeout(function(){ $(".sticky3:hidden").fadeIn(500); }, 300); setTimeout(function(){ $(".sticky4:hidden").fadeIn(500); }, 400); setTimeout(function(){ $(".sticky5:hidden").fadeIn(500); }, 500); setTimeout(function(){ $(".sticky6:hidden").fadeIn(500); }, 600); setTimeout(function(){ $(".sticky7:hidden").fadeIn(500); }, 700); setTimeout(function(){ $(".sticky8:hidden").fadeIn(500); }, 800); setTimeout(function(){ $(".sticky9:hidden").fadeIn(500); }, 900); Is it possible, or is that as clean as can be? fadein time is the same accross all sticky classes, but the timeout must be different for each.
[jQuery] $("area") not selecting in IE
I am using an image map and some jquery to highlight (by applying a border) an image outside of the image map. I am using the code below: $("area").hover(function(){ var stateClass; stateClass = $(this).attr("class"); var stateClassQuery; alert(stateClass);//for testing stateClassQuery = "#"+stateClass; $(stateClassQuery).addClass('selected'); //mouse out }, function(){ var stateClass; stateClass = $(this).attr("class"); var stateClassQuery; stateClassQuery = "#"+stateClass; $(stateClassQuery).removeClass('selected'); } ); It works in FF and Safire however, it will not work in IE. For some reason IE dose not seem to be selecting any of the “area” elements. -chris
[jQuery] Condense this function
Being a bit of a newfie, I was wondering how this function could be condensed: $(document).ready = setTimeout(function(){ $(".sticky1:hidden").fadeIn(500); }, 100); setTimeout(function(){ $(".sticky2:hidden").fadeIn(500); }, 200); setTimeout(function(){ $(".sticky3:hidden").fadeIn(500); }, 300); setTimeout(function(){ $(".sticky4:hidden").fadeIn(500); }, 400); setTimeout(function(){ $(".sticky5:hidden").fadeIn(500); }, 500); setTimeout(function(){ $(".sticky6:hidden").fadeIn(500); }, 600); setTimeout(function(){ $(".sticky7:hidden").fadeIn(500); }, 700); setTimeout(function(){ $(".sticky8:hidden").fadeIn(500); }, 800); setTimeout(function(){ $(".sticky9:hidden").fadeIn(500); }, 900); Is it possible, or is that as clean as can be? fadein time is the same accross all sticky classes, but the timeout must be different for each.
[jQuery] The new core LIVE.
The new core LIVE. Hello. Can I use a namespace with live? $.live('click.fuc1',function1 }; $.live('click.fun2'); $.die('click.func1');
[jQuery] Standards box model
Hello, Sorry about my grammar, English isn't my tang. I read in the Jquery 1.3:release notes, that I must use W3c standards mode. I tried to understand what it's mean. Now my HTML start like that: DO I need to replace it to this: (Like in Jquery website) http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> Thank you.
[jQuery] updating flash after changing flashvars
Hello, i have embed flash element on the page it looks like if i'm trying to change the FlashVars with new value it doesnt seem to be working but i see that new values was implemented alert($("#playersettings").attr("FlashVars")); $("#playersettings").attr("FlashVars", "color=00"); alert($("#playersettings").attr("FlashVars")); if i'm trying to change code manually in FireBug i see that Flash color canged ... but by means of Jquery it doesnt work ... why ? any ideas how to make it working ? Thanks.
[jQuery] .animate() custom animation callback?
hi, im using .animate() to create a custom animation. is there any way to handle a callback function? "normal" . animation() has a parameter for a callback function but not the one for own animations?
[jQuery] Re: How best to create Google Calendar functionality in Jquery?
I am also looking to implement the same thing for an upcoming project, doing the research now... If anyone has any pointers, that would be awesome. Ill keep you updated with my progress. On Jan 9, 2:02 am, Val wrote: > Hi, > > I'm rather new to Jquery and hope someone can point me in the right > direction here. > > In my current project I need to implement some calendar event > functionality (similar to Google Calendar or Mobile Me calendar). In > a nutshell, I need to be able to: > - Create new div with click and drag > - Resize div by clicking on handles (while updating start and end > times) > - Drag divs to reposition on day grid (while updating new start and > end times) > > I know that JQuery UI offers some basic dragging and resizing, but > I've been looking all over for a plug-in or other project that would > provide the more advanced "calendar" functionality of tracking start > and end times as a div is moved or resized. > > I haven't been able to find any such project in Google, however. Can > anyone point me in the direction on where to start for this type of > thing? > > Thanks for your help, > Val
[jQuery] Filter problem on tablesort 2 table
Hello, I've made a table with Tablesort 2 and tablesort pager. It's a very nice plugin and it works fine. But I added a form with the UITableFilter plugin for searching a word in the table. But the problem is that the search is made only on the visible data of the table and not the hidden ones made by the pager. This is my jquery code that is set up on the table. var tableFacts = $('#table_facts').tablesorter({widthFixed: true, widgets['zebra']}) .tablesorterPager({container: $('#pager')}); $("#filter").keyup(function() { $.uiTableFilter( tableFacts, this.value ); }) I think there's no problem with the code here above. Do I have to change something in the plugin scripts? Any ideas? -- View this message in context: http://www.nabble.com/Filter-problem-on-tablesort-2-table-tp21451622s27240p21451622.html Sent from the jQuery General Discussion mailing list archive at Nabble.com.
[jQuery] updating flash after changing flashvars
Hello, i have embed flash element on the page it looks like if i'm trying to change the FlashVars with new value it doesnt seem to be working but i see that new values was implemented alert($("#playersettings").attr("FlashVars")); $("#playersettings").attr("FlashVars", "color=00"); alert($("#playersettings").attr("FlashVars")); if i'm trying to change code manually in FireBug i see that Flash color canged ... but by means of Jquery it doesnt work ... why ? any ideas how to make it working ? Thanks.
[jQuery] jQuery 1.3: Sweet upgrade, but can we use it?
New blog post, "jQuery 1.3: Sweet upgrade, but can we use it?" here: http://tr.im/751a The gist is that I'm concerned that jQuery is progressing faster than users are upgrading their browsers, making it increasingly difficult for web developers to sell the use of the library to management and clients. I *hope* I'm wrong because I would love to take full advantage of the improvements in 1.3. I welcome your comments. -Andrew - http://andrew.hedges.name/blog/
[jQuery] How to use the simple modal if there are two modal windows need be pop-up on ready method?
Hi all How to use the simple modal if there are two modal windows need be pop-up on ready method? I use the confirm style of simple modal and only the fist window can be pop-up, the second doesn't work. thanks for your help. thanks Camel BTW: the code of javascript is following $(document).ready(function(){ $('#confirm').modal({ close:false, position: ["20%",], overlayId:'confirmModalOverlay', containerId:'confirmModalContainer', onShow: function (dialog) { dialog.data.find('.yes').click(function () { alert("click Yes in the confirm window."); $.modal.close(); }); } }); }); $(document).ready(function(){ $('#duplicated').modal({ close:false, position: ["20%",], overlayId:'confirmModalOverlay', containerId:'confirmModalContainer', onShow: function (dialog) { dialog.data.find('.yes').click(function () { alert("click Yes"); $.modal.close(); }); } }); });
[jQuery] trouble with offset();
I have this code here and i am trying to get the offset of element. the idea is that i will eventually be able to make it hook - right now i just want it to get the position. everthing else works... just not the positioning. can anyone help me fix that? (function($){ $.fn.extend({ bstip: function() { return this.each(function(i){ var nowid=$(this).id, nowtitle=$(this).attr("title"); here=$(this); //Math Vars var offset = here.offset(); nowidth=$(this).width(); nowheight=$(this).height(); $("body").append(""+nowtitle+""); $('#bs'+i).css({"top":offset.top+"px","left":offset.left +"px","position":"absolute"}); $('#bs'+i).append("poop"); var bs_tooltip = $("#bs"+i); $(this).removeAttr("title").mouseover(function(){ bs_tooltip.css({"opacity":.8}).fadeIn("fast"); }).mouseout(function(){ bs_tooltip.fadeOut("fast"); }); }); } }); })(jQuery);
[jQuery] Form plugin and ui-dialog issue (never submits)
I am using the Form plugin to do an ajaxSubmit on a form that contains a file upload. The form submits fine on a regular HTML page, but when I use the form on a dialog (http://docs.jquery.com/UI/Dialog), the form churns and never submits. Relevant code below Form Description: File: javascript that fires the dialog function addDocument() { $("#addDocument").dialog("close"); $("#addDocument").removeClass("hideElement").dialog( {draggable: true, bgiframe: false, resizable: false, title:'Add A Supporting Document', width: 500, height: 280}); } Submit ( ajaxSubmit() ) Code $('form#incidentDocumentForm').submit(function(){ var oldhtml = $('#addDocument').html(); var errorSendingMsg = 'Your document could not be saved. Please try again'; var loadingImgSrc = '${pageContext.request.contextPath}/styles/images/indicator.gif'; var options = { //url: 'ajax.do?serviceName=saveLegalComment&serviceType=xml', url: 'ajax.do', type: 'POST', dataType: 'html', iframe: true, target: '#addDocument', timeout: 1, beforeSubmit: function(formData, jqForm, options) { $('#addDocument').html(" "+loadingImgSrc+" "); return true; }, error: function(){ $('#addDocument').html(oldhtml); alert(errorSendingMsg); }, success: function(response){ $("#addDocument").dialog("close"); //location.reload(); } }; $(this).ajaxSubmit(options); return false; }); Thoughts?
[jQuery] Safely Extend Native Objects
First post on here so hello everybody :o) I've been looking at different javascript libraries for a while now to see what one suits best. The 2 I'm interested in are jQuery and mooTools. I've been messing with both and I really like them, however, the way they get the job done is completely different. I have to admit, I prefer the mooTools syntax as it is how javascript intended e.g. " lots of spaces before and after ".trim(); //mooTools $.trim(" lots of spaces before and after "); //jQuery But I hate how it pollutes and extends native objects, as it has caused us problems in the past with other scripts. Now jQuery's one global symbol method is excellent and stops all the compatibility problems with other scripts, which is why I think we'll be going with jQuery. So my question is this, why doesn't jQuery apply the same compatibility method to Native types (exc Object) as it does to the global namespace? e.g. var natives = { extend: function(sType,sAlias) { for(var e in this[sType]) { String.prototype[sAlias + e] = this[sType][e]; } }, 'String': { trim: function() { return (this || "").replace(/^\s+|\s+$/g,""); }, repeat: function(iCount) { for(var i = 0,str = '';i < iCount;i++) { str += this; } return str }, format: function() { var a = arguments,i = -1; return this.replace(/#/g,function() { return a[+ +i] }); } }, 'Array': { //extend array }, 'Date': { //extend date } //bla bla bla } natives.extend('String','$'); alert(' lots of spaces before and after '.$trim()); alert('I love you ' + 'x'.$repeat(5)); alert('hi #, want to go to the ##'.$format('John','foo','bar')); In terms of the global namespace it's a tried and tested method so I'm sure it could work on Natives too, plus, it would mean jQuery javascript is more like javascript. It would be good to get some feedback on why this sort of thing isn't employed. Thanks, Reiss
[jQuery] Covering multiple elements with a single function, but passing a variable?
Hi. I'm stuck trying to figure out the jQuery way to code this functionality I have in my project. Below is a stripped down example of what I'm trying to do. When I click the "Add Item" link below any list, I want to just append a new element to the end of that list. What I do now is just use an onclick element for each anchor tag, and call addItem and pass the specific list_id for that list. The function then dynamically locates that specific list and appends a new item. What I have here works (excuse any typos, I'm writing from memory), but I'd like to make it cleaner by getting rid of the onclick calls and just having jQuery bind a function to the "additem" class. I just can't figure out how to pull in the list_id variable in each case. Any ideas? ... function addItem(list_id) { $('#list_'+list_id+' > ul').append('data'); return false; } ... data data Add Item data data Add Item ...
[jQuery] why i dont see my post
I'm trying to create my post with a question but I don't see it in the list of themes . why ? My nickname "seugenev" Eugene.
[jQuery] Re: Performance penalty for creating dom element from a string?
is a tag which doesn't require an ending tag. is another as is . The W3C validator will actually warn you if you end tags like that, though it's not a big deal. When jQuery creates the HTML, I believe the code is injected into an empty element and jQuery sees what the browser made of the string. The browser decides the proper syntax for the element; your code style including <'s, etc are ignored (though needed to understand what kind of input you're giving the $ function). If you would like a deeper understanding of why these tags have different endings, look the issue up on google. It's an interesting story of a holdover from the early days of HTML (that's why it's found on these basic, older tags). And as always, if you're interested a deeper understanding of jQuery, you might just want to give the $ function's code a look. It's really fairly simple to follow if you know your inputs. On Jan 14, 10:39 pm, RWF wrote: > This also confused me. I tried creating the element as the1.3 docs > show (as noted in the OP) and then appending it to a div and it did > not generate a closing tag. This is what I did: > var image=$(""); > image.alt="hello world"; > > $("#maindiv").append(image); > > The result was a single without a / like this: > > > Am I misunderstanding something? > > On Jan 14, 3:13 pm, Ricardo Tomasi wrote: > > > With the string, jQuery has to parse it, to find the tagname and any > > attributes. For a dozen elements it doesn't make any real difference, > > but when you get to the hundreds or thousands of elements it's > > significant: > > > 100 elements: > > String: 34ms > > DOMElement: 5ms > > > 1000 elements: > > String: 339ms > > DOMElement: 40ms > > > This in Firefox 3, Core 2 Duo 1.6ghz, using Firebug (code below). > > > cheers, > > - ricardo > > > (function(){ > > var i=1001, r=i; > > console.time('string'); > > while(--i){ > > $('');} > > > console.timeEnd('string'); > > > i=r; > > console.time('DOMEl'); > > while(--i){ > > $(document.createElement('div'));}; > > > console.timeEnd('DOMEl'); > > > })(); > > > On Jan 14, 3:04 pm, thomasvsundert > > wrote: > > > > Hi, > > > the new documentation for jQuery 1.3 states that: > > > > "To create a span use $(""). As of jQuery 1.3 this syntax is > > > completely equivalent to $(document.createElement("span"))." > > > > First of all, what does this mean? What was the difference before? > > > > My real question is, what is the performance penalty for using $(" > > > >") vs $(document.createElement("div")) > > > > thanks, > > > Thomas
[jQuery] jQuery Sortables and connectWith going behind second list
Hello, I have two lists that I am trying to connect. They connect as expected and everything works except the following issue. In IE if I drag an item from a list [center] to the list on the right (there are two lists contained in divs) the element from the first list goes behind the elements on the second list. This is without any z-index, and with adding z-index as indicated below. The code I have for both lists is the same: $('#centerlist').sortable({ connectWith: ['#rightlist'], placeholder: "sortHelper", handle: 'div.itemHeader', forcePlaceholderSize: 'true', items: '.groupItem', dropOnEmpty: true, tolerance: 'tolerance', sort:sortObject, stop: updatePostions }); } ); I have attempted to use the z-index option, but to no avail. The lists drag correctly in FireFox. I've also added the following code that is called on the sort function: function sortObject(e,ui){ ui.helper.css('z-index', 95); ui.item.css('z-index', 95); ui.placeholder.css('z-index', 1).css('opacity', .6).css('-moz - opacity', .6); } Is there anything further I can do, or anything that I am doing incorrectly?
[jQuery] Issue upgrading to 1.3
Hello, When I attempt to upgrade my site from 1.2.6 to 1.3, I get an unresponsive script error that causes my browser (both IE7 and FF3) to hang if the script is not stopped. I've tracked down the bit of script causing the problem: $("ul#loginSection li#emilyLogin:not(.loggedIn), ul#loginSection li#joeLogin:not(.loggedIn)").click( function(){} ); As you can see, the problem exists even when the function defined for the click event is empty, leading me to wonder if it is some problem in the CSS selector that is being used, given the engine changes from 1.2.6 to 1.3. Am I doing something incorrectly? - Joe
[jQuery] $("area") not working in IE (sorry if this is a repost)
sorry if this is a repost but I didn't see it in the group and I didn't get a copy in my email. I am working with an image map and i am using the maphilight plugin and I want to add a border to an image below the image map when a user hovers over an area (based on the iamges ID and the area's class)(see code below) I got it to work in FF but I cannot get it to work in IE. Any help? URL: http://oregonstate.edu/admissions/firstyear/recruitmap/map/ Code: $("area").hover(function(){ var stateClass; stateClass = $(this).attr("class"); var stateClassQuery; stateClassQuery = "#"+stateClass; alert(stateClassQuery);//for testing $(stateClassQuery).addClass('selected'); //mouse out }, function(){ var stateClass; stateClass = $(this).attr("class"); var stateClassQuery; stateClassQuery = "#"+stateClass; $(stateClassQuery).removeClass('selected'); }
[jQuery] FadeIn Event loop
Hi peeps, looking for some assistance. How would I go about fading in a series of divs with the same classname on after another? Any help is much appreciated!
[jQuery] Re: Event delegation in CLosest()
Closest is not part of delegation. Closest is a way to traverse the dom tree to find an elements parent that matches the selector used. I think the reason this is helpful in event delegation is because some browsers may not register the click if it occurs inside of a child element of the li. For example, the source of the example In document tree there are 2 list items, 1 of which has only a bold element inside of it while the other has a text node and a bold node. If you were using a browser which used event bubbling, I believe that clicking inside of the bold element with a normal click event linked directly to the li could actually interfere. Also, in the example this was attached to the $(document) element not the ul element. This could serve as another advantage. in your example above, there's only 1 ul that you are attaching to, but you may want to attach this to several. $(document) would be a convenient way to do this. On Jan 14, 7:03 pm, Pedram wrote: > Dear Folk , > how does the $(document).closest() work I could not understand . > > for example this is our HTML code > > > a > > > b > > c > > > > javascript code : > > $("#main").bind("click", function (e) { > $(e.target).closest("li").css("background","red") > > }); > > so how doesthis exactly do , how is this relate to event delegation
[jQuery] Re: Performance penalty for creating dom element from a string?
This also confused me. I tried creating the element as the1.3 docs show (as noted in the OP) and then appending it to a div and it did not generate a closing tag. This is what I did: var image=$(""); image.alt="hello world"; $("#maindiv").append(image); The result was a single without a / like this: Am I misunderstanding something? On Jan 14, 3:13 pm, Ricardo Tomasi wrote: > With the string, jQuery has to parse it, to find the tagname and any > attributes. For a dozen elements it doesn't make any real difference, > but when you get to the hundreds or thousands of elements it's > significant: > > 100 elements: > String: 34ms > DOMElement: 5ms > > 1000 elements: > String: 339ms > DOMElement: 40ms > > This in Firefox 3, Core 2 Duo 1.6ghz, using Firebug (code below). > > cheers, > - ricardo > > (function(){ > var i=1001, r=i; > console.time('string'); > while(--i){ > $('');} > > console.timeEnd('string'); > > i=r; > console.time('DOMEl'); > while(--i){ > $(document.createElement('div'));}; > > console.timeEnd('DOMEl'); > > })(); > > On Jan 14, 3:04 pm, thomasvsundert > wrote: > > > Hi, > > the new documentation for jQuery 1.3 states that: > > > "To create a span use $(""). As of jQuery 1.3 this syntax is > > completely equivalent to $(document.createElement("span"))." > > > First of all, what does this mean? What was the difference before? > > > My real question is, what is the performance penalty for using $(" > > >") vs $(document.createElement("div")) > > > thanks, > > Thomas
[jQuery] Trying to mesh UI slider with jCarouselLite
So I have an interface mockup here that will eventually be a real estate property search by price range. http://viewwestaspen.com/new/quicksearch_jcl.html I have the UI slider working, and was using the default array of items from the UI site real-world demo. On update of the slider range, the property elements nicely fade in and out if they are in/out of the range. However, what I would like to do is use jCarouselLite to scroll left and right on the matching elements instead of the default execution. I have implemented the JCL, and it is working fine, and the elements are fading in/out on update of the slider min/max, but the JCL still wants to scroll to the inactive items. How can I make the JCL refresh whenever the slider is updated?? Ideally, I'd love to have it disappear, show a loader gif while updating, then re-appear allowing proper # of 'next' clicks given the new # of properties in the range. I'd also be open to another option for the carousel if something else might play nicer with the slider. Thanks in advance for any help!! -Adam
[jQuery] Re: Noob
Never mind I figured it out. What I needed to was add the autocomplete after I put the row onto the table. Doh! // put the row into the table $('#' + tableID).append(clonedRow); $('#IngredientList'+newIndex+'Ingredient').autocomplete(data); Which makes perfect sense now that I look at it. Thanks -Original Message- From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On Behalf Of Mauricio (Maujor) Samy Silva Sent: Wednesday, January 14, 2009 5:20 PM To: jquery-en@googlegroups.com Subject: [jQuery] Re: Noob Use the new event feature .live(type, fn) [1] provided with the just launched realease: jQuery 1.3 [2] [1] - http://docs.jquery.com/Events/live [2] - http://docs.jquery.com/Release:jQuery_1.3 Maurício - > Hello, > I have a table that has some form inputs in a single row. One of the > text inputs is an autocomplete that gets its data from a PHP variable. > I have all that working. > > I have a button that clones this row and all its inputs incrementing > the IDs and then appending it to the table. That works fine. > > The problem I am having is that I dont know how to attach the > autocomplete to the input in the new row. > > I have pasted my code below. If you read it you can probably tell that > I ran into the same issue with the delete row button, but I got around > by using straight Javascript. But if I can solve how to attach to a > new element I can fix both problems. > > > Thanks in advance. > Steve
[jQuery] Re: Noob
Hi Maurício I can get this work using the regular events but not with autocomplete. If you dont mind can you point me in the right direction? This is how I currently assign autocomplete to my input: $(document).ready(function() { str = ''; data = str.split('|'); $('#IngredientList0Ingredient').autocomplete(data); }); When I tried to this: $(document).ready(function() { str = ''; data = str.split('|'); $('#IngredientList0Ingredient').live('onkeyup', autocomplete(data)); }); I get an error saying the autocomplete is not defined. I think I have to look into bind. But am not sure. Thanks for any advice you can offer. -Original Message- From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On Behalf Of Mauricio (Maujor) Samy Silva Sent: Wednesday, January 14, 2009 5:20 PM To: jquery-en@googlegroups.com Subject: [jQuery] Re: Noob Use the new event feature .live(type, fn) [1] provided with the just launched realease: jQuery 1.3 [2] [1] - http://docs.jquery.com/Events/live [2] - http://docs.jquery.com/Release:jQuery_1.3 Maurício - > Hello, > I have a table that has some form inputs in a single row. One of the > text inputs is an autocomplete that gets its data from a PHP variable. > I have all that working. > > I have a button that clones this row and all its inputs incrementing > the IDs and then appending it to the table. That works fine. > > The problem I am having is that I dont know how to attach the > autocomplete to the input in the new row. > > I have pasted my code below. If you read it you can probably tell that > I ran into the same issue with the delete row button, but I got around > by using straight Javascript. But if I can solve how to attach to a > new element I can fix both problems. > > > Thanks in advance. > Steve
[jQuery] Re: $(window).bind('resize', fn) not working in IE
I believe I found the bug. Seems like that if you set window.onresize in IE before the document is completely loaded, it won't work. Whatever.
[jQuery] sortable jQuery 1.3 don't work well
Now I'm using the great 1.3 version, but some plugins don't work very well such as Sortable which no trigger update callback if the DOM position has changed and Tab UI which trigger a JS error in Firebug when try access a disabled Tab. And Now What We can do? Thz... Happy birthday jQuery!!! I wish you lot of years and sucess!!!
[jQuery] Re: getJSON - how to retrieve plain text?
"So i want to see what the plaintext is that's returned in the success callback" Use Fiddler (http://www.fiddlertool.com) and it will show you exactly what IE is seeing when it makes the AJAX request and gets a result back On Jan 14, 6:51 pm, Rene Veerman wrote: > I have a getJSON call that works fine in FF, but bugs in IE. > > I get no data. :( > > So i want to see what the plaintext is that's returned in the success > callback.. > > Using the new 1.3 jQuery, btw.. > > code: > > var rc = $('select#regions_countries')[0]; > var rr = $('select#regions_regions')[0]; > var url = > 'http://www.myhost.com/members/ajax_fetch_regions_for_countries.php'; > > var countries = []; > for (var i=0; i if (rc.options[i].selected) { > countries[countries.length] = rc.options[i].text; > } > }; > > $.getJSON (url, {countries:countries.join('|-|')}, function (data, ts) { > var regions = data.regions.split('|-|').sort(); > > var html = ''; > for (var i=0; i html+=' value="'+regions[i].replace(/\s\(.*\)/,'')+'">'+regions[i]+''; > } > rr.innerHTML = html; > > });
[jQuery] Re: $(window).bind('resize', fn) not working in IE
TI'm injecting jQuery into any webpage (via a bookmarklet). This works fine, but for some strange reason $(window).bind("resize") doesn't work with IE. No errors, just doesn't fire the event. To see this, execute this code while on any webpage (using Firebug Javascript Console): //load jQuery var js = document.createElement('script'); js.type = "text/javascript"; js.src = "http://localhost/js/jquery-1.3.js";; document.body.appendChild(js); //this is strange: $ is undefined until a setTimeout. //even stranger: setTimeout must be at least 50 (for me) setTimeout(function(){ //change all link colors to random. var r = function(){ var hex = Math.floor(Math.random()*255*255*255).toString(16); while (hex.length<6) hex = "0" + hex; hex = "#" + hex; $("a").css("color", hex); }; //bind it. resize wont work in IE. $(window).bind("resize", r); $(window).bind("scroll", r); r(); }, 50); On Jan 13, 9:32 pm, Dave Methvin wrote: > Do you have a simple test case? Resize works for me in IE.
[jQuery] Event delegation in CLosest()
Dear Folk , how does the $(document).closest() work I could not understand . for example this is our HTML code a b c javascript code : $("#main").bind("click", function (e) { $(e.target).closest("li").css("background","red") }); so how doesthis exactly do , how is this relate to event delegation
[jQuery] Re: In this code, what would $(this) in the success part refer to?
Rick, while I can appreciate your unhappiness Matt and MorningZ, responding doesn't help anyone. Let's leave thread alone now. Or if need be perhaps you guys can take it to personal emails. Karl Rudd (not a moderator, just someone who prefers quiet discussion) :) On Thu, Jan 15, 2009 at 10:47 AM, Rick Faircloth wrote: > Matt… > > > > I defy you to find references to where I've asked about the same topic > > more than a few times, especially over years. I haven't even been on > > the list that long. And where, even once, have I asked someone to write > > code for me? Never, except for examples as guides… > > > > And if you'll look back over the last couple of threads you're alluding to, > > you'll find two completely different situations concerning the use of > $(this). > > > > No one has asked you, specifically to answer *any* questions, and if you > don't > > want to be of assistance, even to those who may ask something over and > > over again (which I have not), then just answer the ones you like. > > > > But you are not the list moderator and have no business attempting to > control > > how anyone interacts with this list. And I doubt we'll find it in the list > > guidelines that everyone has to conduct themselves in manner that is > pleasing > > to Matt Quackenbush. So help when you want and the rest of the time, just > shut up. :o) > > > > Rick > > > > PS – And if you offered quality assistance to those who ask questions, they > > would learn from your help… > > > > > > From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On > Behalf Of Matt Quackenbush > Sent: Wednesday, January 14, 2009 5:46 PM > To: jquery-en@googlegroups.com > Subject: [jQuery] Re: In this code, what would $(this) in the success part > refer to? > > > > Just to be clear, I'm kinda doubting that anyone has an issue with "n00b" > questions. I believe what people take exception to is the exact same person > asking the exact same type of questions over and over and over and over > again (for years, even), with the expectation of someone else writing all of > the code for them, rather than learning from the help they've received. ;-)
[jQuery] Re: jQuery 1.3 Released
Very goood nice and smooth On Jan 14, 1:51 pm, Alexsandro_xpt wrote: > Uau... very good jQuery 1.3 :) > > On 14 jan, 18:12, Nikola wrote: > > > Well done!
[jQuery] getJSON - how to retrieve plain text?
I have a getJSON call that works fine in FF, but bugs in IE. I get no data. :( So i want to see what the plaintext is that's returned in the success callback.. Using the new 1.3 jQuery, btw.. code: var rc = $('select#regions_countries')[0]; var rr = $('select#regions_regions')[0]; var url = 'http://www.myhost.com/members/ajax_fetch_regions_for_countries.php'; var countries = []; for (var i=0; i html+='value="'+regions[i].replace(/\s\(.*\)/,'')+'">'+regions[i]+''; } rr.innerHTML = html; });
[jQuery] Re: nod names in from fields id
Since you've got jQuery available, i'd suggest using "$.each" instead of for $.each(serverVals, function(name, val) { alert("Name: " + name + "\nType: " + $("*[name='" + name + "']")[0].type); }); On Jan 14, 6:24 pm, bob wrote: > Hi, > How do i get nod names in for loop based on fields id? > > var serverVals = { > 'firstName':'John', // > 'city':'NY', > 'state':6, > 'gender':1, > > }; > > > > > Alabama > Alaska > > Male > Female > > for(var i in serverVals){ > alert(jq('#'+i).nodeName); ??? undefined > //I would like to get > text > radio > ... > > }
[jQuery] Re: In this code, what would $(this) in the success part refer to?
Matt. I defy you to find references to where I've asked about the same topic more than a few times, especially over years. I haven't even been on the list that long. And where, even once, have I asked someone to write code for me? Never, except for examples as guides. And if you'll look back over the last couple of threads you're alluding to, you'll find two completely different situations concerning the use of $(this). No one has asked you, specifically to answer *any* questions, and if you don't want to be of assistance, even to those who may ask something over and over again (which I have not), then just answer the ones you like. But you are not the list moderator and have no business attempting to control how anyone interacts with this list. And I doubt we'll find it in the list guidelines that everyone has to conduct themselves in manner that is pleasing to Matt Quackenbush. So help when you want and the rest of the time, just shut up. :o) Rick PS - And if you offered quality assistance to those who ask questions, they would learn from your help. From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On Behalf Of Matt Quackenbush Sent: Wednesday, January 14, 2009 5:46 PM To: jquery-en@googlegroups.com Subject: [jQuery] Re: In this code, what would $(this) in the success part refer to? Just to be clear, I'm kinda doubting that anyone has an issue with "n00b" questions. I believe what people take exception to is the exact same person asking the exact same type of questions over and over and over and over again (for years, even), with the expectation of someone else writing all of the code for them, rather than learning from the help they've received. ;-)
[jQuery] nod names in from fields id
Hi, How do i get nod names in for loop based on fields id? var serverVals = { 'firstName':'John', // 'city':'NY', 'state':6, 'gender':1, }; Alabama Alaska Male Female for(var i in serverVals){ alert(jq('#'+i).nodeName); ??? undefined //I would like to get text radio ... }
[jQuery] Re: ajaxForm returns error in IE7
Thanks Brian for the help. I completely forgot that I even posted this and I was searching again for an answer...I saw this post and was like "holy crap, that is the same exact problem I am having...wait a minute...". hahaha. Thanks again. On Dec 9 2008, 11:28 pm, "Brian J. Cohen" wrote: > Okay, I found a post that the plugin author responded to, that details > the > problem:http://groups.google.com/group/jquery-en/browse_thread/thread/e52fe0b... > > Apparently he used certain reserved words that you must avoid in your > form element names, like "action" and "method". I had a hidden element > named "action" that I had to rename, and it started working in IE7. > > On Dec 8, 1:14 am, cjokomay wrote: > > > > > I am using ajaxForm to upload an excel file and then display whether > > or not it uploaded successfully. The following jQuery code works fine > > in Firefox, but when I try to run it in IE7 it fails. The beforeSubmit > > function is executed but then it craps out after that with the > > following error: "Object doesn't support this property or method." The > > form is generated dynamically, hence the reason for livequery. > > > $("#taskplans form.upload-form").livequery(function() { > > var h3 = $("#taskplans h3"); > > var content = $("#taskplans div.content"); > > > $(this).ajaxForm({ > > beforeSubmit: function() { > > h3.append(" " + loaderImg); > > }, > > error: function(data) { > > h3.find("img").remove(); > > content.html(data); > > }, > > success: function(data) { > > h3.find("img").remove(); > > content.html(data); > > } > > }); > > > });- Hide quoted text - > > - Show quoted text -
[jQuery] Re: Capture a click outside of a specific object?
Hmmm, I wasn't able to find anything about that, though I checked only quickly. What section fo the docs would that be in? On Jan 13, 5:44 pm, Kean wrote: > You might want to look at live and die method now posted in jQuery > documentation. > > On Jan 13, 11:32 am,riotbrrd wrote: > > > > > Hi all, > > > Is there a simple way to capture a click event in a window/document > > and then determine whether the click was inside an element #foo, or > > outside of that element? > > > Thanks! > > -Kim- Hide quoted text - > > - Show quoted text -
[jQuery] Re: Capture a click outside of a specific object?
Thanks, Sam! I had to make one change, then it worked. I got an error message that "event" was undefined, so I changed the first line from: $(document.body).click(function(){ to $(document.body).click(function(event){ Gotta tell ya, when I hear the phrase "event delegation" my head starts to hurt. I need something like "Event Delegation for Idiots." ;-) Thanks for the help! -Kim
[jQuery] Re: [validate plugin] Conflict in using validation plugin with custom submit code
I agree that the missing submit button is a problem. Could you file a ticket for that? http://dev.jquery.com/newticket (requires registration) Thanks Jörn On Wed, Jan 14, 2009 at 6:33 PM, Fledder wrote: > > Jorn, > > Thank you for responding. I seem to have been wrong in the information > I provided: > > The form DOES submit, but it does it so fast that it is hard to see. > Normally the submit would cause a redirect. The reason it is not > redirecting is because my back-end PHP script relies on the post > containing the submit button name, which it doesn't. > > Luckily I can quite easily work around this in my situation. I know > you are aware of the submit button name issue from other threads in > this forum. It's perhaps not really a bug, but I would definitely see > it as an improvement if it would be fixed. > > Either way, I'm helped for now, thanks again for such a great plugin! > > On Jan 14, 11:26 am, Jörn Zaefferer > wrote: >> Could you post a complete testpage? Looks like your extracts are >> missing something... >> >> Jörn >> >> On Wed, Jan 14, 2009 at 12:00 AM, Fledder wrote: >> >> > hi, >> >> > Like others I seem to have ran into the "double-click to submit >> > problem". Allow me to explain: >> >> > I have a registration form which validates just fine using the >> > excellent validate plugin. It's working perfectly. However, I now want >> > to run some custom code after the validation event. Specifically, I >> > want to disable the submit button when validation is passed. After >> > that, a normal post should follow to the server, no Ajax post. >> >> > My first try was to do this: >> >> > // disable the submit button upon submit event >> > $("#frmEditUser").submit( >> >function() { >> > $("#submSave").attr("disabled","true").attr("value", "Updating, >> > please wait..."); >> >} >> > ); >> >> > // validation code follows here >> > $("#frmEditUser").validate({ >> > .. >> >> > This indeed changes the submit button and validation still works. >> > However, it does not submit the form to the server, instead, nothing >> > happens. My 2nd try was to use the validation plugin's submitHandler. >> > Mind you this code is a bit long, but I think only the bottom part is >> > relevant: >> >> > $("#frmEditUser").validate({ >> >onkeyup:false, >> >rules: { >> >username: { >> >required:true, >> >minlength:5, >> >maxlength:45, >> >validChars:true, >> > >> > usernameCheck:[$("#username").val(),oldusername]// remote check >> > for duplicate username >> >} >> >}, >> >messages: { >> >username: { >> >required: "username is required.", >> >minlength: jQuery.format("username must be >> > at least {0} characters >> > in length."), >> >maxlength: jQuery.format("username can not >> > exceed {0} characters >> > in length."), >> >validChars: "please supply valid characters >> > only.", >> >usernameCheck:"this username is already in >> > use." >> >} >> >} >> >, >> >submitHandler: function(form) { >> >// do other stuff for a valid form >> > >> > $("#submSave").attr("disabled","true").attr("value", "Updating, >> > please wait..."); >> >form.submit(); >> >} >> >> >}); >> >> > This approach I have seen elsewhere in the forum, but it does not work >> > for me. Validation runs fine, yet when the form is valid it once more >> > does not actually post it to the server. It does post when I double- >> > click (only when I uncomment the button-disabling code, otherwise I >> > cannot double-click). >> >> > So my question in general is: how can I have my own custom submit code >> > that does not conflict with the validation plugin and that does an >> > actual post? I thoroughly looked through the forum but I still do not >> > see the solution. >> >> > I will be very grateful for a solution, I've spent so many precious >> > hours on accomplishing such a small thing (disabling a submit button). >> > Thanks in advance!
[jQuery] Re: [validate] message containers and valid XHTML markup?
You can specify rules using plugin options. Take a look at "rules": http://docs.jquery.com/Plugins/Validation/validate#toptions Its also used in various demos, eg. second example here: http://jquery.bassistance.de/validate/demo/ Jörn On Wed, Jan 14, 2009 at 11:15 PM, martin wrote: > > Hey Jörn thanks for the reply. > > What I mean by error containers is like the examples you have provided > here -> http://jquery.bassistance.de/validate/demo/errorcontainer-demo.html > > I checked and yes they actually do validate as XHTML 1.0 Transitional, > however, I'm using XHTML 1.1 which doesnt like having the { and } in > the class attribute. > > Is there any way to use containers but not have to put this markup in > the XHTML? > > thanks, > Martin > > On Jan 9, 9:19 am, "Jörn Zaefferer" > wrote: >> I don't see how that isn't valid XHTML. Apart from that, could you clarify >> "error containers"? What do you mean? >> >> Jörn >> >> On Fri, Jan 9, 2009 at 12:40 AM, martin wrote: >> >> > From what I can make of the documentation, the only way to use >> > validation containers is to put something like... >> >> > class="{required:true,minlength:3}" >> >> > into your HTML form elements. Now this works just fine for me, >> > however, its not valid XHTML. >> >> > Is there any way to have valid XHTML and use error containers?
[jQuery] Re: Noob
Thanks I will look into that. -Original Message- From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On Behalf Of Mauricio (Maujor) Samy Silva Sent: Wednesday, January 14, 2009 5:20 PM To: jquery-en@googlegroups.com Subject: [jQuery] Re: Noob Use the new event feature .live(type, fn) [1] provided with the just launched realease: jQuery 1.3 [2] [1] - http://docs.jquery.com/Events/live [2] - http://docs.jquery.com/Release:jQuery_1.3 Maurício - > Hello, > I have a table that has some form inputs in a single row. One of the > text inputs is an autocomplete that gets its data from a PHP variable. > I have all that working. > > I have a button that clones this row and all its inputs incrementing > the IDs and then appending it to the table. That works fine. > > The problem I am having is that I dont know how to attach the > autocomplete to the input in the new row. > > I have pasted my code below. If you read it you can probably tell that > I ran into the same issue with the delete row button, but I got around > by using straight Javascript. But if I can solve how to attach to a > new element I can fix both problems. > > > Thanks in advance. > Steve
[jQuery] Re: In this code, what would $(this) in the success part refer to?
Just to be clear, I'm kinda doubting that anyone has an issue with "n00b" questions. I believe what people take exception to is the exact same person asking the exact same type of questions over and over and over and over again (for years, even), with the expectation of someone else writing all of the code for them, rather than learning from the help they've received. ;-)
[jQuery] Re: Noob
Use the new event feature .live(type, fn) [1] provided with the just launched realease: jQuery 1.3 [2] [1] - http://docs.jquery.com/Events/live [2] - http://docs.jquery.com/Release:jQuery_1.3 Maurício - Hello, I have a table that has some form inputs in a single row. One of the text inputs is an autocomplete that gets its data from a PHP variable. I have all that working. I have a button that clones this row and all its inputs incrementing the IDs and then appending it to the table. That works fine. The problem I am having is that I dont know how to attach the autocomplete to the input in the new row. I have pasted my code below. If you read it you can probably tell that I ran into the same issue with the delete row button, but I got around by using straight Javascript. But if I can solve how to attach to a new element I can fix both problems. Thanks in advance. Steve
[jQuery] Re: In this code, what would $(this) in the success part refer to?
I agree. A newbie (and I hate the term) list only further exacerbates the problem with searching because that's just another place that one has to (a) know about and (b) remember to look in. Plus it further segments the population into smarties and newbies. All that's really necessary is for everyone to be tolerant, accepting and encouraging. I think the best way to overcome newbie 'noise' is to help them quickly get beyond the newbie level with courteous, if also repetitive, answers. And always remember that what they are, you once were. On Jan 14, 3:33 pm, Ricardo Tomasi wrote: > Not sure a newbies list would help. They wouldn't help each other > much, lol :) Seriously, it would be another list for us to join, and I > bet a lot of the participants in here wouldn't care about it. Just use > the 'daily digest' option and don't read what you don't want to, > that's what I do. > > - ricardo > > On Jan 14, 3:44 pm, "Rick Faircloth" wrote: > > > You and I both know, Charlie, from this group and especially from CF-Talk > > > that there are ways to do "encouraging education" and then there are ways > > > to commit "discouraging education." It's all in the tone of the reply. > > > Personally, I think it's time for jQuery to take the route of CF-Talk > > > and begin a jQuery beginners list, as well. It's hard for one list to serve > > > the needs of such a wide range of experience and competence. > > > Experienced users get frustrated with repeated basic questions, and > > beginners > > > get frustrated with the lack of understanding and patience with their needs. > > > If there is a list for "jQuery-Newbies-en"., then anyone who signs up for > > > that list knows what kind of interaction and questions to expect. > > > For jQuery to survive and thrive in the long-run, the community must make > > > beginners feel welcome. Even using the resources of a community, such as > > the > > > docs, takes some time for beginners to figure out and understand. > > Especially > > > since the docs have been a little sketchy on explanation and helping someone > > > brand new to concepts understand the implications and what's written > > "between > > > the lines of code." > > > So, bring on the new "jQuery-Newbies-en" list! > > > Rick > > > From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On > > Behalf Of Charlie Griefer > > Sent: Wednesday, January 14, 2009 11:33 AM > > To: jquery-en@googlegroups.com > > Subject: [jQuery] Re: In this code, what would $(this) in the success part > > refer to? > > > but educating someone in how to ask a good question really -is- helping > > them :) > > >http://www.catb.org/~esr/faqs/smart-questions.html > > > On Wed, Jan 14, 2009 at 4:24 AM, donb wrote: > > > I don't know what can be more discouraging that the standard 'use > > google' or 'that question has been asked/answered too many times' > > discussion. Folks, this is a discussion forum. People range from > > novice to expert. The experts eventually get tired of answering a > > novice question and get testy about it. And it invariable degrades > > into name-calling. Besides, searching for 'this' will be a futile > > exercise because the word is just too common.. > > > Searching is only going to be successful when you can formulate a good > > search query. But as pointed out, there usually are a bunch of > > 'answers' that may be misleading, create further questions, are just > > wrong, or they may appear to be nonapplicable for some reason. Even > > when the answer is found, it may not be recognized. The documentation > > is not perfect and I find the examples are often quite trivial and > > sometimes ambiguous. And often we have people whose primary language > > is not English and they may struggle (or fail) to translate those > > answers into their own language. (Yes, I know this is the jQuery- > > English forum) > > > There's no need to lecture anyone on 'proper' use of the forum, > > particularly when the lecture/lecturer also goes contrary to decent > > and/or proper use of the forum. As has been shown above, the effort > > it takes to lecture typically far exceeds the effort it takes to > > assist. > > > Still a good motto: 'if you can't say something nice then don't say > > anything at all.' > > > -- > > 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: [validate] message containers and valid XHTML markup?
Hey Jörn thanks for the reply. What I mean by error containers is like the examples you have provided here -> http://jquery.bassistance.de/validate/demo/errorcontainer-demo.html I checked and yes they actually do validate as XHTML 1.0 Transitional, however, I'm using XHTML 1.1 which doesnt like having the { and } in the class attribute. Is there any way to use containers but not have to put this markup in the XHTML? thanks, Martin On Jan 9, 9:19 am, "Jörn Zaefferer" wrote: > I don't see how that isn't valid XHTML. Apart from that, could you clarify > "error containers"? What do you mean? > > Jörn > > On Fri, Jan 9, 2009 at 12:40 AM, martin wrote: > > > From what I can make of the documentation, the only way to use > > validation containers is to put something like... > > > class="{required:true,minlength:3}" > > > into your HTML form elements. Now this works just fine for me, > > however, its not valid XHTML. > > > Is there any way to have valid XHTML and use error containers?
[jQuery] Re: jQuery 1.3 Released
Uau... very good jQuery 1.3 :) On 14 jan, 18:12, Nikola wrote: > Well done!
[jQuery] er, off topic - HAPPY BIRTHDAY jQuery ... and cheers John, would never have learned js without you m8
Just read on Ajaxian lovely slushy piece by Ray Bango... or was that a spoof and me a prat. Oh well, I've had fun gettin ped with this lingo, anyhow. Big cheers John, jQ developers, look forward to getting my head around this lingo a lot more before the 4th. Olly. the_guv guvnr.com -- olly connelly email: g...@guvnr.com skype: ollyconnelly uri: guvnr.com - Web Development, Content Production & PC Care inc. my blog with Tips & Tutorials:- web - development, blogging & surfing content - how-to's and best of pc - hone IT, enjoy IT or just grab a feed.
[jQuery] Noob
Hello, I have a table that has some form inputs in a single row. One of the text inputs is an autocomplete that gets its data from a PHP variable. I have all that working. I have a button that clones this row and all its inputs incrementing the IDs and then appending it to the table. That works fine. The problem I am having is that I dont know how to attach the autocomplete to the input in the new row. I have pasted my code below. If you read it you can probably tell that I ran into the same issue with the delete row button, but I got around by using straight Javascript. But if I can solve how to attach to a new element I can fix both problems. Thanks in advance. Steve $(document).ready(function() { $('#add_recipe_row').click(function() { add_row('recipe_list', 'row_'); }); $('#add_ingredient_row').click(function() { add_row('ingredient_list', 'row_'); } ); }); // ends document.ready function add_row(tableID, rowIDprefix) { // Clone the last row of the table. var clonedRow = $('#'+ tableID + ' tr:last').clone(); // Generate an incremented index for the new row. -1 because there is a table header row var newIndex = (document.getElementById(tableID).rows.length -1); // Set the ID of the row with the new index clonedRow[0].id = rowIDprefix + newIndex; //console.log('ingredient_' + newIndex); // Loop through all of the inputs and select in the cloned row // Find the name and ID of the input/select element and find the number in it abd replace it with the // new index. $.each($('input, select', clonedRow), function(i, val) { //console.log(val); //console.log('Index -1: ' + (newIndex -1) + '. Index: ' + newIndex); val.name = val.name.replace((newIndex - 1), newIndex); val.id = val.id.replace((newIndex - 1), newIndex); val.value = ''; }); //alert($('td.delete_col', clonedRow).parent().get(0).id); $('td.delete_col', clonedRow).html('delete'); // put the row into the table $('#' + tableID).append(clonedRow); } function delete_row(rowID) { //alert(obj.parent().parent().get(0).id); //var rowID = obj.parent().parent().get(0).id; if(rowID == 'row_0') { alert('You cannot delete this row'); } else { $("#"+rowID).remove(); } }
[jQuery] Re: How do I use getjson to make two attribute pairs
Thx. There was a bug in the extra line you gave me which I corrected. Below is the full code you'll need for future reference: http://codedumper.com/flickr-api-using-jquery-json On Dec 12 2008, 4:58 pm, ricardobeat wrote: > According to the API the URL is in item.link, so you just need to wrap > the image in an anchor: > > function(data){ > $.each(data.items, function(i,item){ > $("").attr("src", item.media.m) > .appendTo("#images") > .wrap('"); > if ( i == 4 ) return false; > }); > }); > > On Dec 12, 9:45 am,desbest wrote: > > > > > HERES THE TASK > > > > To get the 5 newest photos from Flickr tagged with the word "light". > > > > > HERES THE CODE > > > > > > > > > > > > > $(document).ready(function(){ > > $.getJSON("http://api.flickr.com/services/feeds/photos_public.gne? > > tags=light&tagmode=any&format=json&jsoncallback=?", > > function(data){ > > $.each(data.items, function(i,item){ > > $("").attr("src", item.media.m).appendTo("#images"); > > if ( i == 4 ) return false; > > }); > > }); > > }); > > > > img{ height: 100px; float: left; } > > > > > > > > > > > > > == > > HERES THE OUTPUT > > ==http://sampleswap.uk.to/json/test.html > > > == > > The src of the image is the item.media.m > > According to the flickr api (http://www.wait-till-i.com/2007/10/22/ > > hacking-flickr-the-json-way/) > > the href of the image is item.link.m > > > How do I make the images be a hyperlink to to the actual Flickr page > > of the image?
[jQuery] Re: Performance penalty for creating dom element from a string?
With the string, jQuery has to parse it, to find the tagname and any attributes. For a dozen elements it doesn't make any real difference, but when you get to the hundreds or thousands of elements it's significant: 100 elements: String: 34ms DOMElement: 5ms 1000 elements: String: 339ms DOMElement: 40ms This in Firefox 3, Core 2 Duo 1.6ghz, using Firebug (code below). cheers, - ricardo (function(){ var i=1001, r=i; console.time('string'); while(--i){ $(''); } console.timeEnd('string'); i=r; console.time('DOMEl'); while(--i){ $(document.createElement('div')); }; console.timeEnd('DOMEl'); })(); On Jan 14, 3:04 pm, thomasvsundert wrote: > Hi, > the new documentation for jQuery 1.3 states that: > > "To create a span use $(""). As of jQuery 1.3 this syntax is > completely equivalent to $(document.createElement("span"))." > > First of all, what does this mean? What was the difference before? > > My real question is, what is the performance penalty for using $(" > >") vs $(document.createElement("div")) > > thanks, > Thomas
[jQuery] Alternating text plugin??
I was wondering if anyone knows of a plugin I could use that alternates text on page reload. I know I can do it in PHP but I can't use PHP in this case -- so was hoping this is achievable with jQuery. Would anyone know how I could accomplish this? or of any plugin I could use? Thanks, Elle http://designbyelle.com.au/
[jQuery] Re: Can I call a different domain using .ajax async=false
async only makes the call synchronous (hangs all processes until the response is received - freezes the browser), it doesn't affect in any way the security model of XHR. If you own both domains put up a JSONP service to provide the data. On Jan 14, 12:50 pm, "g...@getsharepoint.com" wrote: > Hi, > > If my code is on mydomain.com and I want to get some data from > yourdomain.com can I use .ajax with async=false or does .ajax always > do an XMLHttpRequest to get it's data? > > I know I can't use XMLHttpRequest for cross-domain requests. > > Thanks ahead of time.
[jQuery] Re: keep session alive
You could pass all information in a hash or query string: http://www.my.com/newpage.htm?sessionstuff=1&props=234 params = location.search; but there is no native way of parsing that string. better do it JSON style: http://www.my.com/newpage.htm#{ID:23, state:'buying', accNumber: 2098432, password:'coolaid'} //this is all visible to the user then on the new page: session = eval("("+location.hash.substr(1)+")"); and you get an object 'session' with all the paremeters you passed. (I assume you understand that passing a password is a joke. please don't do that :) If you don't want things to be visible you can generate a form on the fly and POST to the next page, then handle everything server-side. cheers, - ricardo On Jan 14, 11:33 am, hjorth wrote: > hi > > i got a big problem > > i need to take a session from one page and keep it alive on another > page where i have a long form. > > is this possible?
[jQuery] Re: .append() into style element causes error in IE only
What are you trying to append? You can only append textnodes to a style element. Why not use the stylesheet object directly: document.styleSheets[0].insertRule("#wrapper {display:none}", 0) // 'addRule' on IE Or, for a hassle-free alternative, create a new style element for it: $('').text(myClass).appendTo('head'); On Jan 14, 12:05 pm, Ant wrote: > Hi, > I am trying to append css into a pre existing style element. > $("style").append(myClass); > This works as expected in Firefox, but not IE. > The HTML on the page validates to HTML strict, so I'm fairly sure that > it's not the issue with IE that append() won't work on incorrectly > written elements. > If I change my code to $("p").append(myClass); it works as expected. > > Was just wondering if this is a know issue with IE or jQuery and if > anyone had a work around, I am out of ideas that don't involve > considerable effort :) > > Thanks, > Ant
[jQuery] Re: In this code, what would $(this) in the success part refer to?
BTW, for those who don't know, there is an IRC channel too: irc.freenode.net #jquery On Jan 14, 6:33 pm, Ricardo Tomasi wrote: > Not sure a newbies list would help. They wouldn't help each other > much, lol :) Seriously, it would be another list for us to join, and I > bet a lot of the participants in here wouldn't care about it. Just use > the 'daily digest' option and don't read what you don't want to, > that's what I do. > > - ricardo > > On Jan 14, 3:44 pm, "Rick Faircloth" wrote: > > > You and I both know, Charlie, from this group and especially from CF-Talk > > > that there are ways to do "encouraging education" and then there are ways > > > to commit "discouraging education." It's all in the tone of the reply. > > > Personally, I think it's time for jQuery to take the route of CF-Talk > > > and begin a jQuery beginners list, as well. It's hard for one list to serve > > > the needs of such a wide range of experience and competence. > > > Experienced users get frustrated with repeated basic questions, and > > beginners > > > get frustrated with the lack of understanding and patience with their needs. > > > If there is a list for "jQuery-Newbies-en"., then anyone who signs up for > > > that list knows what kind of interaction and questions to expect. > > > For jQuery to survive and thrive in the long-run, the community must make > > > beginners feel welcome. Even using the resources of a community, such as > > the > > > docs, takes some time for beginners to figure out and understand. > > Especially > > > since the docs have been a little sketchy on explanation and helping someone > > > brand new to concepts understand the implications and what's written > > "between > > > the lines of code." > > > So, bring on the new "jQuery-Newbies-en" list! > > > Rick > > > From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On > > Behalf Of Charlie Griefer > > Sent: Wednesday, January 14, 2009 11:33 AM > > To: jquery-en@googlegroups.com > > Subject: [jQuery] Re: In this code, what would $(this) in the success part > > refer to? > > > but educating someone in how to ask a good question really -is- helping > > them :) > > >http://www.catb.org/~esr/faqs/smart-questions.html > > > On Wed, Jan 14, 2009 at 4:24 AM, donb wrote: > > > I don't know what can be more discouraging that the standard 'use > > google' or 'that question has been asked/answered too many times' > > discussion. Folks, this is a discussion forum. People range from > > novice to expert. The experts eventually get tired of answering a > > novice question and get testy about it. And it invariable degrades > > into name-calling. Besides, searching for 'this' will be a futile > > exercise because the word is just too common.. > > > Searching is only going to be successful when you can formulate a good > > search query. But as pointed out, there usually are a bunch of > > 'answers' that may be misleading, create further questions, are just > > wrong, or they may appear to be nonapplicable for some reason. Even > > when the answer is found, it may not be recognized. The documentation > > is not perfect and I find the examples are often quite trivial and > > sometimes ambiguous. And often we have people whose primary language > > is not English and they may struggle (or fail) to translate those > > answers into their own language. (Yes, I know this is the jQuery- > > English forum) > > > There's no need to lecture anyone on 'proper' use of the forum, > > particularly when the lecture/lecturer also goes contrary to decent > > and/or proper use of the forum. As has been shown above, the effort > > it takes to lecture typically far exceeds the effort it takes to > > assist. > > > Still a good motto: 'if you can't say something nice then don't say > > anything at all.' > > > -- > > 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: jQuery selector question - Having ":" in attribute name
Just investigated it: http://dev.jquery.com/ticket/3729 The colon is valid I think, but it's true, there are some restrictions. On Jan 14, 2:27 pm, naden wrote: > That sucks. jQuery has no problem with $( 'a' ).attr( 'ajax:id' ); > Therefore it would be nice to use it in the selector too. > > thanks anyway have to change it. > > On 14 Jan., 14:05, "jQuery Lover" wrote: > > > Slightly :) > > > You can not have special character in your html ATTRIBUTES. > > > You should rename "ajax:id" to something else. Ex: ajax_id or ajaxId. > > > - > > Read jQuery HowTo Resource - http://jquery-howto.blogspot.com > > > On Wed, Jan 14, 2009 at 5:16 PM, naden wrote: > > > > Your right. The docs said: > > > > "Note: if you wish to use any of the meta-characters described above > > > as a literal part of a name, you must escape the character with two > > > backslashes (\). For example: > > > > #foo\\:bar > > > #foo\\[bar\\] > > > #foo\\.bar" > > > > and so I did. I used \\: to escape the ":" > > > > or I'm gettin you wrong?
[jQuery] Re: In this code, what would $(this) in the success part refer to?
Not sure a newbies list would help. They wouldn't help each other much, lol :) Seriously, it would be another list for us to join, and I bet a lot of the participants in here wouldn't care about it. Just use the 'daily digest' option and don't read what you don't want to, that's what I do. - ricardo On Jan 14, 3:44 pm, "Rick Faircloth" wrote: > You and I both know, Charlie, from this group and especially from CF-Talk > > that there are ways to do "encouraging education" and then there are ways > > to commit "discouraging education." It's all in the tone of the reply. > > Personally, I think it's time for jQuery to take the route of CF-Talk > > and begin a jQuery beginners list, as well. It's hard for one list to serve > > the needs of such a wide range of experience and competence. > > Experienced users get frustrated with repeated basic questions, and beginners > > get frustrated with the lack of understanding and patience with their needs. > > If there is a list for "jQuery-Newbies-en"., then anyone who signs up for > > that list knows what kind of interaction and questions to expect. > > For jQuery to survive and thrive in the long-run, the community must make > > beginners feel welcome. Even using the resources of a community, such as the > > docs, takes some time for beginners to figure out and understand. Especially > > since the docs have been a little sketchy on explanation and helping someone > > brand new to concepts understand the implications and what's written "between > > the lines of code." > > So, bring on the new "jQuery-Newbies-en" list! > > Rick > > From: jquery-en@googlegroups.com [mailto:jquery...@googlegroups.com] On > Behalf Of Charlie Griefer > Sent: Wednesday, January 14, 2009 11:33 AM > To: jquery-en@googlegroups.com > Subject: [jQuery] Re: In this code, what would $(this) in the success part > refer to? > > but educating someone in how to ask a good question really -is- helping them > :) > > http://www.catb.org/~esr/faqs/smart-questions.html > > On Wed, Jan 14, 2009 at 4:24 AM, donb wrote: > > I don't know what can be more discouraging that the standard 'use > google' or 'that question has been asked/answered too many times' > discussion. Folks, this is a discussion forum. People range from > novice to expert. The experts eventually get tired of answering a > novice question and get testy about it. And it invariable degrades > into name-calling. Besides, searching for 'this' will be a futile > exercise because the word is just too common.. > > Searching is only going to be successful when you can formulate a good > search query. But as pointed out, there usually are a bunch of > 'answers' that may be misleading, create further questions, are just > wrong, or they may appear to be nonapplicable for some reason. Even > when the answer is found, it may not be recognized. The documentation > is not perfect and I find the examples are often quite trivial and > sometimes ambiguous. And often we have people whose primary language > is not English and they may struggle (or fail) to translate those > answers into their own language. (Yes, I know this is the jQuery- > English forum) > > There's no need to lecture anyone on 'proper' use of the forum, > particularly when the lecture/lecturer also goes contrary to decent > and/or proper use of the forum. As has been shown above, the effort > it takes to lecture typically far exceeds the effort it takes to > assist. > > Still a good motto: 'if you can't say something nice then don't say > anything at all.' > > -- > 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: In this code, what would $(this) in the success part refer to?
That would be better in a separate topic :D You still have the overhead of creating a new jQuery object for each action, but it's not as much as searching the document again for it. It might make a difference if you have more than a dozen operations and it's dealing with the UI. cheers, - ricardo On Jan 14, 2:40 pm, Miloš Rašić wrote: > Since you're already discussing $(this), I'd like to ask something. > It is a good practice to assign selected nodes to variables if you are going > to need them more than once so as not to make jQuery search the document for > them again and again. What about $(this)? Do I need to assign it to a > variable or is it fast enough for repeated use?
[jQuery] Re: dynamic title set after ajax
Olaf Bosch schrieb: Thank you for reading, i have it :) replace is doing: document.title = data.replace( /([\s\S]+)/, '' ).replace(/<\/title>([\s\S]+)/, '' ); with this works in all Browsers I tested. after a ajax load of content in a DIV I try to change the title of the parent document, for better BookMarking. Works fine in FF, not in IE. In IE is result null. In Opera become in alert. here the Code: var new_title = $(data).filter("title").text(); document.title = new_title; alert (new_title); See you a way to do this in all Browsers? -- Viele Grüße, Olaf --- olaf.bo...@t-online.de http://olaf-bosch.de/ http://ohorn.info/ http://www.akitafreund.de/ ---
[jQuery] Re: Event code in different .js files
In the old-fashioned you couldn't have more than one event handler: window.onload = function(){ .. } but using jQuery's bind('load', function(){}) you're using the new standards-based event system, via addEventListener (attachEvent on IE), in which 'onload' is not a property of the window object, instead you assign "listeners" that fire with the event. You can have as many of them as you like. cheers, - ricardo On Jan 14, 10:18 am, Krommenaas wrote: > strange, but I should have checked. thanks!
[jQuery] Re: When to use LiveQuery plugin
first off all... the purpose (and advantage of) LiveQuery is that when new matching items are added, they will automatically be wired up... secondly, one thing to look at is the just-released-today version of jQuery (1.3), it now has a ".live" handler that will effectively do what the plugin does http://docs.jquery.com/Events/live#typefn On Jan 14, 3:07 pm, ocptime wrote: > Hi all, > > I had seen a new plugin called "LiveQuery" and i have some questions > that are not yet completely answered when i read its documentation. > > I am using jquery.form.plugin, My questions is when to use livequery > and what is it's advantages. > is it possible to use livequery in conjention with the form plugin. > > can u pls cite me a small sample code or some pointers on the web > where both are used. > > Thanks in advance > ocptime
[jQuery] Re: jQuery 1.3 Released
Well done!
[jQuery] When to use LiveQuery plugin
Hi all, I had seen a new plugin called "LiveQuery" and i have some questions that are not yet completely answered when i read its documentation. I am using jquery.form.plugin, My questions is when to use livequery and what is it's advantages. is it possible to use livequery in conjention with the form plugin. can u pls cite me a small sample code or some pointers on the web where both are used. Thanks in advance ocptime
[jQuery] Re: jQuery 1.3 Released
I just read the release info and changes and I must say I'm impressed and pleased in equal measure. I'm a Perl hacker who came to jQuery because I find its syntax natural and it reminds me of Perl in that you can code how you think. I am amazed that the kit/community is doing so many things so right (like opening the selector engine). I was starting to look at ExtJS for some bigger projects but the way things are going I'd rather take the time to write a plugin or two with jQuery for anything that I would have wanted from ExtJS. ...just three years. Terrific. -Ashley On Jan 14, 6:45 am, John Resig wrote: > Hey Everyone - > > jQuery 1.3 is out! Full details > here:http://blog.jquery.com/2009/01/14/jquery-13-and-the-jquery-foundation/ > > Happy 3rd Birthday, jQuery! > > --John
[jQuery] Re: Using position
dont worry, its my own doing - i had an alert in the calling function to display the position code. On Jan 14, 4:15 pm, Russ wrote: > I have this function (below) which im using to show a div (progress) > and center it over another div (diary) on my page as some ajax is > called. > > It all works, except that it always pops an alert showing the > "position" jquery function. Anyone else had this problem using > position?? > > function ShowProgress() { > var diaryTop = $("#diary").position()["top"]; > var diaryLeft = $("#diary").position()["left"]; > var diaryWidth = $("#diary").width(); > var diaryHeight = $("#diary").height(); > var progressWidth = $("#progress").width(); > var progressHeight = $("#progress").height(); > var x = (Math.round(diaryWidth / 2) - Math.round(progressWidth / > 2)) + diaryLeft; > var y = (Math.round(diaryHeight / 2) - Math.round(progressHeight / > 2)) + diaryTop; > $("#progress").css({ "position":"absolute","left": x, "top":y }); > $("#progress").toggle(); > > }
[jQuery] Re: jQuery 1.3 Released
YEAH BABY On Jan 14, 3:45 pm, John Resig wrote: > Hey Everyone - > > jQuery 1.3 is out! Full details > here:http://blog.jquery.com/2009/01/14/jquery-13-and-the-jquery-foundation/ > > Happy 3rd Birthday, jQuery! > > --John
[jQuery] stock price ticker plugin?
hi guys, i am looking for a stock price ticker plugin, that will change color of the price green or red, and also change in real time. do you guys know any plugins or any other suggestions for this? thanks
[jQuery] Re: @name deprecated?
Excellent! Thanks Dave (and all!) I really appreciate all the help. :) On Jan 13, 3:40 pm, Dave Methvin wrote: > > So, just to clarify, 1.3 is where @name becomes deprecated? > > The @attr has been deprecated (advised to be avoided) for some time; > 1.3 is where it is no longer supported. > > > Should I go ahead and make the "@name" change if I am still using > > 1.2.6... Or, should I wait until I upgrade to 1.3.x? > > Since 1.2.x works without the @, go ahead and do it now.
[jQuery] Re: Jquery 1.2.3 does not return a type for radio controls?
Karl Swedberg wrote: hmm. that doesn't sound right to me. I just put up a test page using jQuery 1.2.3, and it identified radio controls just fine: http://test.learningjquery.com/123.html Can we see the HTML? Maybe something else is going on. Text This is checkbox 1 This is checkbox 2 Second Text NY OH PA Same problem with the textarea, by the way. Here's the javascript... (note, this is from a genshi template - ${job.description} is a url string that encodes the names of the controls and their values, like so: jt_textfield=this%20is%20text&jt_checkbox1=on&jt_dist_r_lo=OH&jt_textarea=this%20is%20a%20textarea var jt_values = "${job.description}"; var els = jt_values.split('&'); $.each(els, function() { var items = this.split("="); var item = "#" + items[0]; var item_val = decodeURIComponent(items[1]); switch ( $(item).attr('type') ) { case 'radio': alert(item + " is radio"); break; case 'checkbox': $(item).attr("checked","checked"); break; case 'text': $(item).val(item_val); break; case 'textarea': $(item).val(item_val); alert(item + " is textarea = " + item_val); break; default: alert(item+'unknown type:'+$(item).attr('type')); } I'm getting undefined in the alert for unknown type on both jt_dist_r_lo and jt_textarea
[jQuery] Re: jQuery website errors
Also http://docs.jquery.com/Frequently_Asked_Questions On Jan 14, 9:40 am, brian wrote: > FYI, this page currently is throwing a "DBQueryError": > > http://docs.jquery.com/UI/Tabs
[jQuery] New VisualStudio version of 1.3 already :-)
Wow are people fast http://blogs.ipona.com/james/archive/2009/01/14/jquery-1.3-and-visual-studio-2008-intellisense.aspx hope that helps
[jQuery] new Jquery Cheat Sheet
Is there a new Jquery cheat sheet for 1.3? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "jQuery (English)" group. To post to this group, send email to jquery-en@googlegroups.com To unsubscribe from this group, send email to jquery-en+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/jquery-en?hl=en -~--~~~~--~~--~--~---
[jQuery] Performance penalty for creating dom element from a string?
Hi, the new documentation for jQuery 1.3 states that: "To create a span use $(""). As of jQuery 1.3 this syntax is completely equivalent to $(document.createElement("span"))." First of all, what does this mean? What was the difference before? My real question is, what is the performance penalty for using $("") vs $(document.createElement("div")) thanks, Thomas