[jQuery] strange behaviour with .post
Hi all, Im sure I'm off somewhere with syntax but I get strange behavior with this script. sometimes it does the .post sometimes it doesnt. On top of that it doesnt return the alert if the post is successful or not. Is it better to use .ajax? function Validate() { if($('#title').val() == ){ alert(You must enter a title for the event.); return false; }else{ CopytoCal(); } } /* function to copy an entry to another calendar */ function CopytoCal() { var cnm = 'Theatre Calendar'; var purl = 'http://10.1.3.20/theatrcalendar/webCal3_updated.asp'; $.post(purl,$(#event).serialize(),function(data,status){ if (status ==success) { alert(Record added/updated! Entry has been copied to the + cnm + . You should still check and make sure the entry has been copied.); } else { alert(There was an error! The entry was NOT copied to the + cnm + .) }; }); }
[jQuery] Re: jquery website broken?
On Mar 18, 3:56 pm, David Meiser dmei...@gmail.com wrote: When I was developing our company's website, I had a coworker who kept complaining about how terrible it looked. He complained that half the images were missing, half the text was unstyled, blah blah blah. I asked him what browser he was using: Firefox 3.0.1. I was using 3.0.1 as my primary browser. He said he had another coworker that had the same problems. It took me two weeks of off and on troubleshooting to finally locate the problem. I had placed all the images and CSS in a folder labeled with the company acronym: ADS. The real problem? He had Adblocker Plus installed, which was blocking the images and CSS... This is so true. I have had a few cases with our company site where some customer would complain things arent displying right or that they cant login. 99% of the time its due to something the user either had installed on their computer (antivirus, spyware adware blocker, virus etc) that caused the problem. I see people with multiple antivirus programs installed, mulitple ad blockers etc. I had one guy call frantically demanding that our site was not compatible with firefox 3.05. I looked into everything until I finally asked him if he was running any plugins. The guy had an insane number of plugins installed but the clincher: he had the noscript plugin. I assumed someone using noscript and that adamant about things running in Firefox understood how noscript worked. Obviously he did not. And by the way regarding the jquery site displaying correctly. I am currently using and testing IE8 RC1. The site has always displayed fine in IE7, and it displays and works fine in IE8 RC1 but only in compatability mode (like IE7). It does have issues in IE8 standards mode. Never a problem in Firefox, Chrome, Opera or Safari 4 beta.
[jQuery] Re: jquery website broken?
Actually regarding my statement about IE8 standards mode. it seems only the Documentation section is a bit broke. Rest of the site displays fine
[jQuery] Re: EZPZ Tooltip
Nice. I like the simplicity and the stayOnContent option.
[jQuery] Re: jQuery UI Question - Tool tip
I would also check out simpletip. http://craigsworks.com/projects/simpletip/# On Mar 3, 1:33 pm, webRat web...@gmail.com wrote: Thanks Karl Jörn for both your responses.
[jQuery] Re: Solution To Many Of Your CSS Nightmares!
Although I love CSS, it is interesting how it leads to some of the same spaghetti problems that people complained about by applying formatting to html. I try to keep my CSS to a minimum but over time on a large site it can get quite messy. Most CSS guru's relate their CSS to little blogs or wiki's versus a large content site.
[jQuery] Re: I wrote a YUI Multi FIle Compression Utility
This is great. I've been looking for such a utility. Thank you. On Dec 23, 8:27 am, K-BL axel...@aim.com wrote: Hey Guys, I just finished writing aYUIMulti-File Compression Utility. It's really simple, it just runs some CLI commands, but more importantly, it compiles entire directories and sub directories with a clean UI. For us IT guys, it makes quick site changes a breeze from source to compressed in just seconds. Anyway, find it here:http://jqueryplugins.weebly.com/yui-compressor-multi-file-utility.html If you like it, let me know. Also, source is available in C#. K-BL
[jQuery] Whats best for js compression, packer, jsminify, YUI?
Hi all, I know this has probably been discussed before but I with all the options available, I was wondering what method seems to work best overall for compressing js files. I want to put all my jquery plugins into one file and compress for performance but I'm worried about breaking things. I know there is packer, jsmin etc. Any recommendations.
[jQuery] Re: Whats best for js compression, packer, jsminify, YUI?
Sorry Morningz Im being a bit lazy about it. I'll search around. It looks like jsmin is used to minify jquery so I'll give that a try. On Oct 8, 12:23 pm, MorningZ [EMAIL PROTECTED] wrote: I know this has probably been discussed before it has been (including explanations and benchmarks)... all you need to do is a search in the group On Oct 8, 3:21 pm, JimD [EMAIL PROTECTED] wrote: Hi all, I know this has probably been discussed before but I with all the options available, I was wondering what method seems to work best overall for compressing js files. I want to put all my jquery plugins into one file and compress for performance but I'm worried about breaking things. I know there is packer, jsmin etc. Any recommendations.- Hide quoted text - - Show quoted text -
[jQuery] autocomplete and updating different fields from delimited string
Hi all, I'm using rhe great jquery autocomplete plugin which works great. But Im returning a pipe delimited list so I can return more data and then populate specific fields with that info. So for example my autocomplete would return pipe delimited data like so for each line. Top Gun|0001|11/22/06|10/31/06 Top Act|0002|11/22/06|10/31/06 In the display results of the autocomplete I wouldnt want to display the full line just the first value of the pipe delimited string. So it would display: Top Gun Top Act. And if I selected Top Act it would update: #title_name with the value 'Top Act' the field #item with the value '0002', the field #date1 with value '11/22/06' the field #date2 with value '10/31/06' Im a bit confused as to how to go about initiating a function to parse the pipe delimited data to update the fields the way I want. $(document).ready(function(){ $(#title_name).autocomplete(autosearch.html, { width: 350, max: 50, cacheLength: 0, scroll: true, minChars: 4, minChars: 4, autoFill: false, mustMatch: false, matchContains: false, selectFirst: false, extraParams: { d: function(){return $ ([EMAIL PROTECTED]:checked).val();}} }); $(#title_name).result(function(event, data, formatted) { if (data) $(#title_name).val(data[1]); $(#item).val(data[2]); $(#date1).val(data[3]); $(#date2).val(data[3]); }); });
[jQuery] Re: autocomplete and updating different fields from delimited string
Ok I got this figured out. maybe this can help anyone else looking for a similiar solution. bnased of the demo I can manipulate output with the findValueCallback function. $(document).ready(function() { function findValueCallback(event, data, formatted) { $(li).html( !data ? No match! : Selected: + formatted).appendTo(#results); } $(#title_name).autocomplete(intra_autosearch.html, { width: 350, max: 50, cacheLength: 0, scroll: true, minChars: 4, minChars: 4, autoFill: false, mustMatch: false, matchContains: false, selectFirst: false, extraParams: { d: function(){return $ ([EMAIL PROTECTED]:checked).val();}} }); $(:text).result(findValueCallback).next().click(function() { $(this).prev().search(); }); $(#title_name).result(function(event, data, formatted) { if (data) alert(data); $(#title_name).val(data[0]); $(#item_number).val(data[1]); $(#title_street).val(data[2]); $(#title_prebook).val(data[3]); }); });
[jQuery] getting value of a radio button
Hi all I know this is pretty basic stuff and discussed before but Im having problems simply getting the value of a radio button that is checked in a group. For example in the code below why is 's' blank? // get value for checkbox or radio button that is checked $([EMAIL PROTECTED]'radCateg']).click(function(){ var s = $([EMAIL PROTECTED]'radCateg']:checked).val(); alert(s); });
[jQuery] Re: getting value of a radio button
Thanks ricardobeat. A little bit more info here. The code I put worked in Firefox. its IE7 that was giving me the problem. I know about the @ sign being deprecated but I still find at times it wont work without the @ after input. Either way thanks for the help. I never thought about using the filter. On Sep 29, 4:34 pm, ricardobeat [EMAIL PROTECTED] wrote: The '@' at the start of an attribute name has been deprecated. Try this: $('input[name=radCateg]').click(function(){ var s = $(this).filter(':checked').val(); alert(s); }); or this: $('input[name=radCateg]').click(function(){ if $(this).is(':checked') alert(this.value); }); - Ricardo On Sep 29, 7:15 pm, JimD [EMAIL PROTECTED] wrote: Hi all I know this is pretty basic stuff and discussed before but Im having problems simply getting the value of a radio button that is checked in a group. For example in the code below why is 's' blank? // get value for checkbox or radio button that is checked $([EMAIL PROTECTED]'radCateg']).click(function(){ var s = $([EMAIL PROTECTED]'radCateg']:checked).val(); alert(s); });- Hide quoted text - - Show quoted text -
[jQuery] Assigning the value of a field to another hidden field.
Hi all, Quick question regarding retrieving a field value. I have the following code. Basically based on a select menu option I want to set a hidden field to specific value depending on what is selected. So if the user selects Urgent or Critical the hidden field would be set to the value of another field in the form. I am trying to use $ (#chkneededby).val == $('#dateSel').val; but that does not seem to work. Is this correct if say I want to get the field value of a field with the id dateSel $('#dateSel').val; $(pselectBox).change(function () { // var text = $(this).text(); $this = $(this); if ($this.val() == 'Urgent') { $(#chkneededby).val == $('#dateSel').val; } else if ($this.val() == 'Critical') { $(#chkneededby).val == $('#dateSel').val; } else { $(#chkneededby).val('01/01/2999'); } });
[jQuery] Re: broken image url check options on jquery
Thanks Ariel, I'll take a look at the preload plugin. On Apr 24, 8:14 pm, Ariel Flesler [EMAIL PROTECTED] wrote: Probably this can help you. jQuery.Preload:http://flesler.blogspot.com/2008/01/jquerypreload.html The Placeholder Mode has a notFound option to set an alternative image. Also, using the onComplete event, you can do something specific for those that failed. Cheers -- Ariel Fleslerhttp://flesler.blogspot.com On 24 abr, 20:37, JimD [EMAIL PROTECTED] wrote: Hi all, For awhile now I have used a simple onerror check to show an alternative if an img url is broken in the page. Something as shown below. Problem with this script, it will produce an error if the alternative image is actually not available as well. Can any one point me to a jquery solution if available? I was thinking I could probably use the dimensions plugin, get the width of any image on the page and if the width is 0 display the alternative missing image. html head script language=JavaScript type=text/javascript function ImgError(source) { source.src = /images/noimage.gif; source.onerror = ; return true;} /script /head body divimg src=http://jquery.com/images/bibeault_cover150A.jpg; border=1 height=100 alt=image onerror=ImgError(this)/div /body /html- Hide quoted text - - Show quoted text -
[jQuery] Re: broken image url check options on jquery
Thanks Ariel I'll check it out. On Apr 24, 8:14 pm, Ariel Flesler [EMAIL PROTECTED] wrote: Probably this can help you. jQuery.Preload:http://flesler.blogspot.com/2008/01/jquerypreload.html The Placeholder Mode has a notFound option to set an alternative image. Also, using the onComplete event, you can do something specific for those that failed. Cheers -- Ariel Fleslerhttp://flesler.blogspot.com On 24 abr, 20:37, JimD [EMAIL PROTECTED] wrote: Hi all, For awhile now I have used a simple onerror check to show an alternative if an img url is broken in the page. Something as shown below. Problem with this script, it will produce an error if the alternative image is actually not available as well. Can any one point me to a jquery solution if available? I was thinking I could probably use the dimensions plugin, get the width of any image on the page and if the width is 0 display the alternative missing image. html head script language=JavaScript type=text/javascript function ImgError(source) { source.src = /images/noimage.gif; source.onerror = ; return true;} /script /head body divimg src=http://jquery.com/images/bibeault_cover150A.jpg; border=1 height=100 alt=image onerror=ImgError(this)/div /body /html- Hide quoted text - - Show quoted text -
[jQuery] broken image url check options on jquery
Hi all, For awhile now I have used a simple onerror check to show an alternative if an img url is broken in the page. Something as shown below. Problem with this script, it will produce an error if the alternative image is actually not available as well. Can any one point me to a jquery solution if available? I was thinking I could probably use the dimensions plugin, get the width of any image on the page and if the width is 0 display the alternative missing image. html head script language=JavaScript type=text/javascript function ImgError(source) { source.src = /images/noimage.gif; source.onerror = ; return true; } /script /head body divimg src=http://jquery.com/images/bibeault_cover150A.jpg; border=1 height=100 alt=image onerror=ImgError(this)/div /body /html
[jQuery] lost process running after form submit with impromptu
Hi all, I'm using Impromptu to provide a simple confirm before submitting a form from within a greybox. Everything works great, but whenever the form is submitted (im not using ajax, ajah). Its like some lost process starts running in the parent window that spawned the greybox. Once I click any link it goes away, but it shouldnt be doing this. I am still on jquery 1.1.4 (yes I plan to update). Any ideas? simple submit $.prompt('Submit report',{ buttons: { Submit: 'yes', Cancel: 'no' }, callback: Submitform }) function Submitform() { var Choice = v; if (Choice == no) { alert(The form was not submitted.); } else { $(#ship_discr).get(0).submit(); } }
[jQuery] Re: jQuery 1.1.2 Released: Happy 2nd Birthday!
Yes I agree thanks to the Jquery team for all their efforts. Jquery is awesome. Happy Bday Jquery Donation on its way. On Jan 14, 10:05 pm, John Resig [EMAIL PROTECTED] wrote: On the 2nd birthday of jQuery we're happy to bring you a new release of jQuery! Here's the announcement:http://jquery.com/blog/2008/01/15/jquery-122-2nd-birthday-present/ and here's the release notes:http://docs.jquery.com/Release:jQuery_1.2.2 Enjoy - and here's looking forward to another year of excellent jQuery code! --John
[jQuery] Re: Space gallery
Wow Stefan that is awesome.
[jQuery] Re: help using selectors to set a hidden field value
Ahh Makes sense thanks Wizzud. On Dec 17, 4:31 pm, Wizzud [EMAIL PROTECTED] wrote: You're nearly there, but what you need to do is *append* to the #updstr field, whereas you are currently overwriting its value with each iteration of each! Personally, I would probably do it slightly differently, eg... $(document).ready(function(){ var upd = []; $( 'input[name^=rlinehval-]' ).each(function(){ upd.push( $(this).val(); }); $(#updstr).val( upd.join(';') ); }); On Dec 17, 11:35 pm, JimD [EMAIL PROTECTED] wrote: Hi all, Pretty basic but Im having some difficulty. When my form is submitted, I want to capture all the form element textfield values where the name begins with 'rlinehval-' and put them into a hidden field value with the id updstr as a semicolon delimited list for a db update. I read through the selector docs but this doesnt seem to work. Using Jquery I am trying this: $(document).ready(function(){ $('[EMAIL PROTECTED]').each(function(){ var sv = this.value + ;; $(#updstr).val(sv); }); }); So in the case of the example form below, when submitted I collect all the values for the fields where the name starts with ''rlinehval- and put them in a hidden field value as a semicolon delimited string On submission the hidden field named updstr would be: 0056543,DVD;0024543,BLU Simple demo form !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd; html xmlns=http://www.w3.org/1999/xhtml; head meta http-equiv=Content-Type content=text/html; charset=utf-8 / script type=text/javascript src=jquery-latest.js/script script type=text/javascript $(document).ready(function(){ $('[EMAIL PROTECTED]').each(function(){ var sv = this.value + ;; $(#updstr).val(sv); });}); /script /head body form id=myform class=cssform action= input type=hidden id=updstr name=updstr value= p label for=userItem1/label input name=rlinehval-1 type=text id=rlinehval-1 value=0056543,DVD / /p p label for=userItem2/label input name=rlinehval-2 type=text id=rlinehval-2 value=0024543,BLU / /p input type=submit value=Submit / input type=reset value=reset / /form /body /html- Hide quoted text - - Show quoted text -
[jQuery] IE7 smudgy text issues with Superfish/hoverintent
Hi all, I just now decided to update to the latest version of jquery which means I had to update some plugin scripts. Everything works fine but I am having an issue specifically with my menu system which is using Joel Birch's great Superfish script. The menu works but in IE7 now the text is fuzzy on the drop down menus. I know this is some issue wit the cleartext handling in IE7. If I disable hoverintent I no longer get the problem but I want hoverintent enabled =(. I'm sure similiar issues have come up before. Anyway to stop this behavior?
[jQuery] accordian plugin brings up errors in IE7
Using accordian 1.5 and jquery 1.1.2 * $Rev: 3353 $ In IE7 I keep getting the following error when clicking on one of the menu items. it works in FF2 although it stutters a bit. ERRORS: errors at: elem[name] = value; segment of code in jquery: name = name.replace(/-([a-z])/ig,function(z,b){return b.toUpperCase();}); if ( value != undefined ) elem[name] = value; return elem[name]; I am using the following div structure (span is for styling purposes): div id=menu class=lftmenu div class=titlespanDVD/span/div div a href=#New Release/a a href=#Used DVD/a /div div class=titlespanGAMES/span/div div a href=#XBOX/a a href=#PS3/a /div /div Calling it like so: === jQuery().ready(function(){ jQuery('#menu').Accordion({ header: '.title' }); });
[jQuery] getting query string val method with jquery
Hi all, Is there any new built in method to get a query string value into a var for jquery For example this same question came up awhile ago here: http://groups.google.com/group/jquery-en/browse_thread/thread/99e1bc29713bba37/09506175a651256e?lnk=gstq=query+stringrnum=2# I wasnt sure with the new versions of jquery if there is anything new built in to do such a thing or if you'd still need to create your own function to handle it. Jim
[jQuery] Re: getting query string val method with jquery
Very cool Josh thanks for letting me know. I'll check it out. On Aug 30, 3:09 pm, Josh Nathanson [EMAIL PROTECTED] wrote: Hey Jim, I have an extension jqURL you can check out. The demos aren't quite finished, but it works. Here's the link: http://www.oakcitygraphics.com/jquery/jqURL/jqURLdemo.html Basically if your query string value is myvar, you do: var x = $.jqURL.get(myvar); There are some other useful functions too. -- Josh - Original Message - From: JimD [EMAIL PROTECTED] To: jQuery (English) jquery-en@googlegroups.com Sent: Thursday, August 30, 2007 12:34 PM Subject: [jQuery] getting query string val method with jquery Hi all, Is there any new built in method to get a query string value into a var for jquery For example this same question came up awhile ago here: http://groups.google.com/group/jquery-en/browse_thread/thread/99e1bc2... I wasnt sure with the new versions of jquery if there is anything new built in to do such a thing or if you'd still need to create your own function to handle it. Jim- Hide quoted text - - Show quoted text -
[jQuery] Re: jCarouselLite - my first plugin - anxiously awaiting comments
This is excellent. I too found Jcarousel to be very cool but a bit heavy for my needs especially as a secondary app on our site. As Xavier mentioned auto scroll would be great not much more needed. On Jun 25, 3:11 am, xavier [EMAIL PROTECTED] wrote: Hi, Like it as well. Would it be possible to add an option to auto scroll (ie change image every X second, as if you press the next button) ? Thanks for sharing ! Xavier On Jun 25, 12:42 am, Ganeshji Marwaha [EMAIL PROTECTED] wrote: Hi there, I have been using jquery for a couple of weeks now. I should say this is the best library out there. I come from raw javascript, prototype, mootools background and i am damn sure, i am not going back. That said, a couple of days ago, i was looking for a carousel style widget for my app, and stumbled upon the excellent jCarousel plugin. The plugin is awesome. It has everything i needed and more. It worked like a charm out of the box, but my issue was that, my use-case used carousel as a secondary widget, and jCarousel seemed kinda like a overkill. So, i started developing my own mini carousel inspired by jCarousel and called it jCarouselLite. This is not a replacement for jCarousel by any means. It is just a light-weight alternative for those who might not need all the functionalities offered by jCarousel. The minified version is just under 1.5k in size. Yet, it is very flexible and customizable for many of our needs. Right now, the plugin is in very early stage and i thought i could get feedback from my friends here and see if there is any interest around it. I have put together a page to show-case all the things that are possible with it athttp://www.gmarwaha.com/jquerylite/jcarousellite/html/jcarousellite.h... The basic html markup expected is just a div enclosing a ul element. You can have your navigation buttons anywhere. No special classes, or css files are required. The js is the lone file needed. div class=anyClass ul liimg src=someimage alt=1/li liimg src=someimage alt=2/li liimg src=someimage alt=3/li liimg src=someimage alt=4/li /ul /div button class=prev/button button class=next/button $(function() { $(.someClass).jCarouselLite({ btnNext: .next, btnPrev: .prev }); }); Thanks in advance for all your feedback. Ganesh.
[jQuery] error using jcarousel with jquery calendar
Hi all, I have a weird problem with jquery calendar that causes an error in Internet Explorer 7. If I use the jquery calendar and jcarousel on the same page together I get the following error: Internet Explorer cannot open the web site... Operation aborted. If I remove the calendar, or remove jcarousel everything works just fine. I've tried re-arranging the order in which I call the scripts and still get the error. Has anyone else run into such a problem?
[jQuery] Re: error using jcarousel with jquery calendar
Sorry, to be more specific I am reffering to the following calendar http://marcgrabanski.com/code/jquery-calendar/
[jQuery] Re: jTip and ToolTip featured on smashing magazine
Wow Jtip was great but cluetip takes it to another level. sticky ajax tooltips cool. Great job Karl. On Jun 12, 4:14 pm, Karl Swedberg [EMAIL PROTECTED] wrote: Hey, that's cool! They feature clueTip, too, and I haven't even blogged about it yet. Not sure how they found out about it, but I feel kind of pathetic to be scooped by someone about my own plug-in. Pathetic, but also flattered. --Karl _ Karl Swedbergwww.englishrules.comwww.learningjquery.com On Jun 12, 2007, at 7:02 PM, Benjamin Sterling wrote: http://www.smashingmagazine.com/2007/06/12/tooltips-scripts-ajax- javascript-css-dhtml/ -- Benjamin Sterling http://www.KenzoMedia.com http://www.KenzoHosting.com
[jQuery] keycode javascript conversion to jquery
Hi all, I'm looking to convert an old javascript function to jquery. It simple captured the keycode event 13 (user pressing enter on the keyboard) if the user hits enter it initiates the action of clicking a button. I want to try jquery because no matter what I do with regular javascript, the keycode never get properly initiated in firefox. I was wondering if any of you could suggest the best method using jquery so it works with both firefox 2 and IE6/7 Current javascript: /* for enter key to initiate simple search clicking enter key */ function DoEnterSearch(buttonName,e) { var key; var key = (e)? e.which: event.keyCode; if (key == 13) { //Get the button the user wants to have clicked var btn = document.getElementById(buttonName); if (btn != null) { //If we find the button click it btn.click(); if (event) event.keyCode = 0 ; return false } } } Jquery implementation $(document).ready(function() { $(#searchtxt).keydown( function(e){ var key = e.charCode || e.keyCode || 0; $('buttonsmp').click(); } ); });
[jQuery] Re: keycode javascript conversion to jquery
little mistake on my jquery attempt this $('buttonsmp').click(); should be $('#buttonsmp').click(); (the id of the button to be clicked) Jquery implementation $(document).ready(function() { $(#searchtxt).keydown( function(e){ var key = e.charCode || e.keyCode || 0; $('buttonsmp').click(); } );
[jQuery] Re: .load issue with IE7
Thanks so much for the tips Wizzud. You got me on the right track. On May 31, 12:44 am, Wizzud [EMAIL PROTECTED] wrote: Just so I'm straight on this In main page: on doc ready, 1. load 'invoices' code, with callback{ 2. load 'paybox' code 3. add click() to checkboxes on 'invoices' code } Then the code for 3 is what you have below, which is roughly on click { if checked, reload 'paybox' code with 'addpay' and value else, reload 'paybox' code with 'delpay' and value } Personally, I would put a class on your checkboxes and use that to find them - and even if you don't want to do that there is no need to use the substring in the attribute check ([EMAIL PROTECTED]'checkbox']) because it's either a checkbox or it's not, so [EMAIL PROTECTED] is sufficient. However, as I said I would add a class - eg. boxIncludeInvoice - to each checkbox and use that instead. Also, you don't have to use jquery where it is simpler not to, for example, why test $(this).is(':checked') when a test on this.checked is adequate. (I have checkbox click functions working in IE7 that make make a group of checkboxes act like radio buttons, simply by testing this.checked). The main page script might look something like (using snippets provided in previous posts) $(document).ready(function(){ function loadPaybox(params){ $(div#paytotal).load(payment_total_load.html,(params || {})); // add callback if needed } function reloadPaybox(){ loadPaybox( (this.checked ? {addpay:'yes', paystr:this.value} : {delpay:'yes', paystr:this.value}) ); } $(div#payments).load('account_rec_load.html',function(){ // start of callback... loadPaybox(); $('.boxIncludeInvoice').click(reloadPaybox); // add click to checkboxes }); // ends payments load callback }); // ends document ready Lastly, be aware that all the above may be over simplified, in that you may want to consider what the user might be doing while paybox is loading - like clicking a load more checkboxes. In which case you might want shift the 'add clicks to checkboxes' into a callback when loading paybox, and precede the loading of the paybox with an unbind('click', reloadPaybox) for the checkboxes, thus preventing the user clicking more checkboxes until the previous click has done all the processing it needs to. This may or may not help! John W wrote: Weird I posted a reply about this earlier this morning and it never went through. Anyway, Wizzud thanks for the tip this worked. One other question related to this same piece. The .load works now in IE7 and FF, but for some reason I cant get IE to fire the click unclick actions on some checkboxes in the page. basically in the page that lists all the invoices that can be paid I have a checkbox next to each one. If the user clicks a check box I reload the paybox with the value to be added and the new total displayed. Again works in FF2 but not IE7. checkbox code. !-- $(document).ready(function(){ $([EMAIL PROTECTED]'checkbox']).click(function(){ if ($(this).is(:checked)){ $(div#paytotal).load(payment_total_load.html? addpay=yespaystr= + this.value); } else { $(div#paytotal).load(payment_total_load.html? delpay=yespaystr= + this.value); } }); }); Just to describe the process of whats going on, the main page loaded in the browser is account_rec.html. That page has a div #payments that loads account_rec_load.html (this is the listing of invoices that can be paid). And inside of account_rec_load.html is a div that loads payment_total_load.html (the paybox showing totals). Wizzuds tip resolved my issue with the paybox not displaying in IE7. By putting the second load in the callback of the first it resolved the problem. But now I'm stumped as to how to get IE7 to receive the click events from the checkbox. It all works great in FF. -- On May 29, 5:28 pm, Wizzud [EMAIL PROTECTED] wrote: Have you tried putting the second load into the callback of the first load? eg. $(document).ready(function(){ $(div#payments).load('account_rec_load.html',function(){ $(div#paytotal).load(payment_total_load.html); }); John W wrote: Ok so I have payment page. When the page loads I fill in a list of payments within a div using .load, and within the page being loaded in the div, I have another .load that feeds in a total box. This all works great in FF2, but for some reason in IE7 the paybox doesnt not display. So in the main page I load the list page using .load like so and it works fine in both IE7 and FF2. $(document).ready(function(){ $(div#payments).load('account_rec_load.html',function(){ return false; }); }); Then in the 'account_rec_load.html' page I have a similiar load function that just loads in a totals box using .load as well. This works in FF but
[jQuery] Re: .load issue with IE7
Weird I posted a reply about this earlier this morning and it never went through. Anyway, Wizzud thanks for the tip this worked. One other question related to this same piece. The .load works now in IE7 and FF, but for some reason I cant get IE to fire the click unclick actions on some checkboxes in the page. basically in the page that lists all the invoices that can be paid I have a checkbox next to each one. If the user clicks a check box I reload the paybox with the value to be added and the new total displayed. Again works in FF2 but not IE7. checkbox code. !-- $(document).ready(function(){ $([EMAIL PROTECTED]'checkbox']).click(function(){ if ($(this).is(:checked)){ $(div#paytotal).load(payment_total_load.html? addpay=yespaystr= + this.value); } else { $(div#paytotal).load(payment_total_load.html? delpay=yespaystr= + this.value); } }); }); Just to describe the process of whats going on, the main page loaded in the browser is account_rec.html. That page has a div #payments that loads account_rec_load.html (this is the listing of invoices that can be paid). And inside of account_rec_load.html is a div that loads payment_total_load.html (the paybox showing totals). Wizzuds tip resolved my issue with the paybox not displaying in IE7. By putting the second load in the callback of the first it resolved the problem. But now I'm stumped as to how to get IE7 to receive the click events from the checkbox. It all works great in FF. -- On May 29, 5:28 pm, Wizzud [EMAIL PROTECTED] wrote: Have you tried putting the second load into the callback of the first load? eg. $(document).ready(function(){ $(div#payments).load('account_rec_load.html',function(){ $(div#paytotal).load(payment_total_load.html); }); John W wrote: Ok so I have payment page. When the page loads I fill in a list of payments within a div using .load, and within the page being loaded in the div, I have another .load that feeds in a total box. This all works great in FF2, but for some reason in IE7 the paybox doesnt not display. So in the main page I load the list page using .load like so and it works fine in both IE7 and FF2. $(document).ready(function(){ $(div#payments).load('account_rec_load.html',function(){ return false; }); }); Then in the 'account_rec_load.html' page I have a similiar load function that just loads in a totals box using .load as well. This works in FF but not IE7. I'm assuming its because the ajax loaded page isnt actually being seen as loaded in IE7? Sorry Im not quite the javascript guru. Any ideas why IE7 is treating this differently. $(document).ready(function(){ $(div#paytotal).load(payment_total_load.html,function(){ return false; }); }); -- View this message in context:http://www.nabble.com/.load-issue-with-IE7-tf3833063s15494.html#a1086... Sent from the JQuery mailing list archive at Nabble.com.
[jQuery] .load issue with IE7
Ok so I have payment page. When the page loads I fill in a list of payments within a div using .load, and within the page being loaded in the div, I have another .load that feeds in a total box. This all works great in FF2, but for some reason in IE7 the paybox doesnt not display. So in the main page I load the list page using .load like so and it works fine in both IE7 and FF2. $(document).ready(function(){ $(div#payments).load('account_rec_load.html',function(){ return false; }); }); Then in the 'account_rec_load.html' page I have a similiar load function that just loads in a totals box using .load as well. This works in FF but not IE7. I'm assuming its because the ajax loaded page isnt actually being seen as loaded in IE7? Sorry Im not quite the javascript guru. Any ideas why IE7 is treating this differently. $(document).ready(function(){ $(div#paytotal).load(payment_total_load.html,function(){ return false; }); });
[jQuery] Re: .load issue with IE7
Hi Olive thanks for the suggestion. Usually I dont have a problem with .load in IE7, but I assume this is because Im doing a .load within another file that was requested via ajax. On May 29, 5:00 am, Olive [EMAIL PROTECTED] wrote: Jim, there is a problem using load in IE when you have to load inside a HTML table. You should use $.get instead. HTH, Olive.
[jQuery] Re: .load issue with IE7
Well no luck with .get either. Guess Ill have to output the div as the page is generated. So much for IE. On May 29, 9:09 am, JimD [EMAIL PROTECTED] wrote: Hi Olive thanks for the suggestion. Usually I dont have a problem with .load in IE7, but I assume this is because Im doing a .load within another file that was requested via ajax. On May 29, 5:00 am, Olive [EMAIL PROTECTED] wrote: Jim, there is a problem using load in IE when you have to load inside a HTML table. You should use $.get instead. HTH, Olive.- Hide quoted text - - Show quoted text -
[jQuery] ajax form loader displays on load even though loader is set to hidden
Hi all using Ajax form. Which works great, but Ive noticed lately when my page loads now the loader image displays event though Im hiding the div on load. Any ideas why this would be happening? $(document).ready(function() { $(busy).hide(); $('div id=busybr /img src=/images/loaders/ miniloader.gif /nbsp;nbsp;Requesting content.../div') .ajaxStart(function() {$(this).show();}) .ajaxStop(function() {$(this).hide();}) .appendTo('#loader'); $('#billpay').ajaxForm({ // account rec target: '#paymentpost', success: function() { $('#paymentpost').fadeIn('slow'); } }); });
[jQuery] Re: ajax form loader displays on load even though loader is set to hidden
Ok noted one mistake on my part this should be $(#busy).hide(); But even with that it doesnt work. This is in both IE7 and FF2. Stumped. It use to work. On May 24, 2:31 pm, JimD wrote: Hi all using Ajax form. Which works great, but Ive noticed lately when my page loads now the loader image displays event though Im hiding the div on load. Any ideas why this would be happening? $(document).ready(function() { $(busy).hide(); $('div id=busybr /img src=/images/loaders/ miniloader.gif / Requesting content.../div') .ajaxStart(function() {$(this).show();}) .ajaxStop(function() {$(this).hide();}) .appendTo('#loader'); $('#billpay').ajaxForm({ // account rec target: '#paymentpost', success: function() { $('#paymentpost').fadeIn('slow'); } }); });- Hide quoted text - - Show quoted text -
[jQuery] Re: ajax form loader displays on load even though loader is set to hidden
Thanks Mike. I'll mess around with it. Whats strange is that this has been working in my code. I havent changed the version of jquery or anything weird. On May 24, 3:10 pm, Mike Alsup [EMAIL PROTECTED] wrote: You're hiding the busy div before it's been added to the DOM. Try changing that code around a little: $('div id=busybr /img src=/images/loaders/ miniloader.gif /Requesting content.../div') .ajaxStart(function() {$(this).show();}) .ajaxStop(function() {$(this).hide();}) .appendTo('#loader') .hide(); Hi all using Ajax form. Which works great, but Ive noticed lately when my page loads now the loader image displays event though Im hiding the div on load. Any ideas why this would be happening? $(document).ready(function() { $(busy).hide(); $('div id=busybr /img src=/images/loaders/ miniloader.gif /Requesting content.../div') .ajaxStart(function() {$(this).show();}) .ajaxStop(function() {$(this).hide();}) .appendTo('#loader'); $('#billpay').ajaxForm({ // account rec target: '#paymentpost', success: function() { $('#paymentpost').fadeIn('slow'); } }); });- Hide quoted text - - Show quoted text -
[jQuery] Re: checkbox and .load
Hi Equand, THanks for the reply. I was testing in Firefox 2, but I created a plain example (Im reworking old legacy code) and I think the problem is with the page html. In a plain demo I dont get the refresh issue. Simple example !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http:// www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd html xmlns=http://www.w3.org/1999/xhtml; head meta http-equiv=Content-Type content=text/html; charset=iso-8859-1 / script type=text/javascript src=jquery-1.1.2.pack.js/script script type='text/javascript' !-- adds checks item values in a delimited list to field ostr $(document).ready(function(){ $([EMAIL PROTECTED]'checkbox']).click(function(){ if ($(this).is(:checked)){ $(div#test).load(total.html? action=addval= + this.value); } else { $(div#test).load(total.html? action=addval= + this.value); } }); }); -- /script /head body div id=test/div form name=get-num action= method=get table width=250 border=0 cellpadding=5 cellspacing=0 tr td1/td td5.00/td tdinput name=check1 type=checkbox value=5.00|1 - Add to pay/td /tr tr td2/td td20.00/td tdinput name=check2 type=checkbox value=20.00|2 - Add to pay/td /tr tr td3/td td6.00CR/td tdinput name=check3 type=checkbox value=-6.00|3 - Add to pay/td /tr tr td4/td td12.00/td tdinput name=check3 type=checkbox value=12.00|3 - Add to pay/td /tr tr td5/td td5.00/td tdinput name=check3 type=checkbox value=5.00|3 - Add to pay/td /tr tr td6/td td89.00/td tdinput name=check3 type=checkbox value=89.00|3 - Add to pay/td /tr /table p input type=submit name=Submit value=Submit / /p /form /body /html and the external total.html was just something like: strongCurrent Payment Total:/strong On May 7, 8:19 pm, Equand [EMAIL PROTECTED] wrote: what browser u have? did you check in the error console of firefox? On May 8, 3:09 am, John W [EMAIL PROTECTED] wrote: Hi all, Question regarding the use of .load with a checkbox. I have a list of items. Each item has a checkbox with a unique id. When the customer checks the checkbox i want to do an ajah request to an external file (like adding an item to the cart) which then updates the content in a div showing updated totals. I have that working fine, but it only works on the first check. if I check another box or uncheck an item the page reloads instead of doing the get request via ajax. Any ideas? script type='text/javascript' $(document).ready(function(){ $([EMAIL PROTECTED]'checkbox']).click(function(){ if ($(this).is(:checked)){ $(div#test).load(cartupdate.cgi?action=addval= + this.value); } else { $(div#test).load(cartupdate.cgi?action=removeval= + this.value); } });}); -- /script -- View this message in context:http://www.nabble.com/checkbox-and-.load-tf3707122s15494.html#a10368208 Sent from the JQuery mailing list archive at Nabble.com.- Hide quoted text - - Show quoted text -
[jQuery] Re: General discussion
Wow this is very cool. Nice work Diego.