[jQuery] JQuery calendar

2008-12-30 Thread Praveen
Hi All can any one send me a demo of Jquery calendar i wrote this code in html $(document).ready(function(){ $(".menu a").hover(function() { $(this).next("em").animate({opacity: "show", top: "-75"}, "slow"); }, function() { $(this).next

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Kean
Alexandre, Another word of caution. Do choose your labels carefully. Avoid keywords. Adding quotes to keyword labels ensure compatibility with YUI compressor. var a = { // new without quotes produce error in ie "new": function() { alert("new"); },

[jQuery] Re: Autocomplete plugin rare behaviour

2008-12-30 Thread brian
On Wed, Dec 31, 2008 at 2:14 AM, R0bb13 wrote: > > Hi > > I'm using the autocomplete plugin to edit the name of a product in a > CMS. When the name field (with autocomplete) is empty the autocomplete > works perfectly. However when the field is not empty and you remove > the content the suggestio

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Michael Geary
> > > > Why do I really need so much on ready? > > > Yes! That's what we're all wondering! Don't keep us > > > in suspense. :-) > > When you work with a bunch of morons in a company > > that uses them throughout the site and when the js are > > packaged will lead to unnecessary performance loss.

[jQuery] Autocomplete plugin rare behaviour

2008-12-30 Thread R0bb13
Hi I'm using the autocomplete plugin to edit the name of a product in a CMS. When the name field (with autocomplete) is empty the autocomplete works perfectly. However when the field is not empty and you remove the content the suggestions don't appear but the ajax request retrieve the correct dat

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Michael Geary
They create exactly the same result. The object or array literal is likely to be a tiny bit faster than the new Object/Array, because it avoids a name lookup (or several name lookups if you're inside a nested function). But of course even if it is faster, it would make a difference only if you're

[jQuery] Re: Posting multiple values from a checkbox

2008-12-30 Thread brian
On Wed, Dec 31, 2008 at 1:16 AM, Michael Geary wrote: > >> There is nothing wrong with doing both -- nesting the inside the >> and using the "for" attribute. Or is there? I'm in the habit of doing so because I sometimes change my mind about nesting inputs inside their labels. Because ... > No

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Kean
5000 is just an exaggeration, it's probably in the realm of 20 On Dec 30, 10:42 pm, Kean wrote: > > >Why do I really need so much on ready? > > Yes! That's what we're all wondering! Don't keep us in suspense. :-) > > When you work with a bunch of morons in a company that uses them > throughout t

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Kean
As for JS, saving bytes is totally a good thing. On Dec 30, 10:53 pm, "Alexandre Plennevaux" wrote: > why? It's just a shorthand, isn't it ? does it affect the computer > resources in any manner ? > > On Wed, Dec 31, 2008 at 3:12 AM, Kean wrote: > > > Just a nitpick. > > > Don't do this > > var

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Alexandre Plennevaux
why? It's just a shorthand, isn't it ? does it affect the computer resources in any manner ? On Wed, Dec 31, 2008 at 3:12 AM, Kean wrote: > > Just a nitpick. > > Don't do this > var datascape = new Object(); > var datascape2 = new Array(); > > Instead > var datascape = {}; > var datascape2 = [];

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Kean
> >Why do I really need so much on ready? > Yes! That's what we're all wondering! Don't keep us in suspense. :-) When you work with a bunch of morons in a company that uses them throughout the site and when the js are packaged will lead to unnecessary performance loss.

[jQuery] Superfish menu questions/problem

2008-12-30 Thread Deaven Butler
I have just started using superfish on our site http://christianmotorsports.comI am not a programmer so getting beyond the basic selection options and pasting in custom css code etc. is not clear to me. I have gone through and edited some existing css code for the general template on the site.Thi

[jQuery] Re: Posting multiple values from a checkbox

2008-12-30 Thread Michael Geary
_ From: Karl Swedberg Sent: Tuesday, December 30, 2008 7:42 PM To: jquery-en@googlegroups.com Subject: [jQuery] Re: Posting multiple values from a checkbox On Dec 30, 2008, at 8:11 PM, Michael Geary wrote: Your checkboxes all have the same ID attribute, and they have no NAME attr

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Michael Geary
> From: Kean > > No, I don't take that as an insult. I was worried needlessly, then. :-) > I was just wondering how document ready was coded so it > really was just a hypothetical question. Well, there is the source code. :-) http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.js Just

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Karl Swedberg
On Dec 31, 2008, at 12:47 AM, Michael Geary wrote: They use in context like this: "You need to achieve Function Closure." Not the way I would word it, but at least I can understand what they mean. :-) That's pretty funny. Sounds like something you might find in a self- help book. :-) -

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Michael Geary
You got it, that's exactly what I was getting at, Ricardo. I assumed that they actually meant "closures", but who knows, they could have even been referring to something else. Actually I've been getting a kick out of (or getting annoyed by, I'm not sure which) the terminology that's come into use

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Michael Geary
Excellent analysis, Ricardo. BTW, which browser did you run your timing test in? Here's another tip. If you really do need to have thousands of ready functions, you can speed things up a bit by rolling your own. For example: window.ready = []; jQuery(function() { for( var fn, i =

[jQuery] Re: Please help me on a .lt method

2008-12-30 Thread Samuel
Thanks all the same。 I've got it solved. Actually the problem is that .lt and .gt were removed from the newly released jquery. Thanks. On Wed, Dec 31, 2008 at 1:10 PM, Kean wrote: > > Make a demo page or a html page. > > Some common mistakes > > 1. Did you include jQuery? > 2. Did you write som

[jQuery] Re: Please help me on a .lt method

2008-12-30 Thread Samuel
Hi Karl, Thanks very much for your quick helps. Feel very nice to hear from you. You write a very nice book. I can write some simple codes after reading your books for only a week. I'm reading the seventh chapter now. Actually I'm going to release a website for our Chinese learning English Vocab

[jQuery] Re: Please help me on a .lt method

2008-12-30 Thread Karl Swedberg
Hi Samuel, Sorry about the problems you're having with the code. The .lt() and .gt() methods were removed from jQuery shortly after the book was published. In their place, you can use the :lt() and :gt() selectors or the .slice() method. The .slice() method is quite versatile, and takes e

[jQuery] Re: Please help me on a .lt method

2008-12-30 Thread Kean
Make a demo page or a html page. Some common mistakes 1. Did you include jQuery? 2. Did you write something like var $table =$('table') before using $table.find() ? On Dec 30, 7:30 pm, Samuel Wu wrote: > Hi, everyone > > I started writing jquery from last week with the help from a very good

[jQuery] Re: .html() only works on original source?

2008-12-30 Thread Ricardo Tomasi
Two issues at play here: 1. the HTML in most browsers doesn't reflect all recent changes done via Javascript 2. the browser only saves form values after a submit What you can do is save the values at the time of removal, and then re- fill it when you put it back. Use the data() function: // rem

[jQuery] jquery autocomplete plugin

2008-12-30 Thread Relez
Hi list, I need some help with autocomplete plugin. I have two text field (name and surname) and I need to add to the name field the autocomplete like this: When the user start writing on it, it shows the coincidences and when he select the correct item the surname field most be filled too. For e

[jQuery] Please help me on a .lt method

2008-12-30 Thread Samuel Wu
Hi, everyone I started writing jquery from last week with the help from a very good book Learning Jquery. I met a problem when reading the book, which has the script: $table.find('tbody tr').show() .lt(2) .hide() .end() .gt(5) .end(); Where 2 and 5 are different from the book, but I think it

[jQuery] Re: Fastest way to clear child elements from a div

2008-12-30 Thread Kean
If I read the jQuery source code right, it seems that .html() does not use this replaceHTML method even in 1.3b1 On Dec 30, 8:21 pm, Ricardo Tomasi wrote: > There is a long discussion about better 'innerHTML' methods, see here > (check the comments also): > > http://blog.stevenlevithan.com/arch

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Kean
Hi Ricardo, Sweet, that's what I was expecting for an answer.

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Ricardo Tomasi
Hi Kean, AFAIK, ready() puts the function you passed into an array of functions. Another function is bound to the DOMContentLoaded event, which is fired when the DOM is ready on compliant browsers. For the others, several methods are in place to detect when DOM is loaded. When the event fires/DOM

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Angel Marquez
See, that is the kind of feedback I was interested in. I sell my self short and thought I saw some inconsistencies and discrepancies; but, was unsure. I appreciate everyones feedback. Thank you, Angel

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Ricardo Tomasi
I think Michael wanted to point out that they're called 'closures' and not 'enclosures'. For a hiring questionnary that's not very bright. Another one: there's no such thing as a "Javascript class". You can have "class-like instantiation", but strictly we're speaking about objects, constructors a

[jQuery] Re: Fastest way to clear child elements from a div

2008-12-30 Thread Ricardo Tomasi
There is a long discussion about better 'innerHTML' methods, see here (check the comments also): http://blog.stevenlevithan.com/archives/faster-than-innerhtml http://ajaxian.com/archives/replacehtml-for-when-innerhtml-dogs-you-down On Dec 30, 7:00 pm, Adam Guichard wrote: > It ran in 5ms, but i

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread Ricardo Tomasi
The children() in your loop is not counting the textnode either. index() can't help you in this case, as it ignores nodes that are not elements even using contents(). But you can use $.each to simplify your code a bit: var $items = $('Helloworld!!Goodnight moon!'); $.each($items.contents(), func

[jQuery] Re: Fastest way to clear child elements from a div

2008-12-30 Thread Kean
Oops I mean event. On Dec 30, 8:11 pm, Kean wrote: > Sounds like your nodes have to much element binded to them. > > On Dec 30, 1:00 pm, Adam Guichard wrote: > > > It ran in 5ms, but its my understanding if I use the method your > > suggesting I'll be leaking memory.  If I just set the innerhtm

[jQuery] Re: Fastest way to clear child elements from a div

2008-12-30 Thread Kean
Sounds like your nodes have to much element binded to them. On Dec 30, 1:00 pm, Adam Guichard wrote: > It ran in 5ms, but its my understanding if I use the method your > suggesting I'll be leaking memory.  If I just set the innerhtml = "", > I think the dom element's children aren't disposed.  

[jQuery] Re: Ajax lists makes the page jump

2008-12-30 Thread Karl Swedberg
Rather than set the height, you could set min-height. IE6 doesn't recognize min-height, but it treats height as min-height, so you can set height within a conditional comment for IE6 only. --Karl Karl Swedberg www.englishrules.com www.learningjquery.com On Dec 30, 2008, at 4

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Kean
No, I don't take that as an insult. I was just wondering how document ready was coded so it really was just a hypothetical question. Why do I really need so much on ready? Also, MorningZ, I will be very active in the jQuery mailing list in future to learn more js. Perhaps this is not the best s

[jQuery] Re: Posting multiple values from a checkbox

2008-12-30 Thread Karl Swedberg
On Dec 30, 2008, at 8:11 PM, Michael Geary wrote: Your checkboxes all have the same ID attribute, and they have no NAME attribute. Give each one a unique ID and NAME. You can use same value for those two attributes in a single checkbox, or they can be different. But each ID and each NAME s

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread MorningZ
"There probably is a better way to do it. " Which is what i was getting at.. i hope "honest" isn't/wasn't taken as "insulting" On Dec 30, 10:16 pm, "Michael Geary" wrote: > Come on, MorningZ, there's no need for insults. > > But yes, 5000 of those will be pretty slow - and that's before

[jQuery] Re: $(document).ready fires before CSS is rendered?

2008-12-30 Thread Richard D. Worth
http://www.learningjquery.com/2008/10/1-awesome-way-to-avoid-the-not-so-excellent-flash-of-amazing-unstyled-content - Richard On Tue, Dec 30, 2008 at 9:15 PM, Kean wrote: > > I thought I saw an article covering this topic in learningjquery.com > or somewhere else. > > Anyone care to show me whe

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread Michael Geary
There's nothing wrong with running that for loop yourself. In fact, it will be faster than any other solution - because all the other solutions will just boil down to a loop with a bunch of extra code. -Mike > From: nachocab > > Allright, so I guess manually going through the contents() > arra

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread Michael Geary
Come on, MorningZ, there's no need for insults. But yes, 5000 of those will be pretty slow - and that's before you even execute the code inside those functions. How slow? It's easy to test. The ready functions are run in the order that the $() functions are called. So simply do this in a test pag

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread nachocab
Allright, so I guess manually going through the contents() array is the only solution. The only function that comes close to giving me the index is jQuery.inArray() (it's really just the for loop that I'm doing with a different condition), but it doesn't let me specify the id or the className, so

[jQuery] Re: Drag and Drop Sortable List and ASP.Net

2008-12-30 Thread MorningZ
Viewstate is the probable enemy in your case as that "remembers" the current state of the form and is does not reflect changes on the client side Time to ditch the postback model and use AJAX calls to handlers (ashx) and such On Dec 30, 6:50 pm, cantelopehead wrote: > I have a drag and dr

[jQuery] Re: $(document).ready fires before CSS is rendered?

2008-12-30 Thread donb
Are your CSS directives declared in the header, or did you put them within the body of the page (where they may be applied later than you wish, or may not be at all). Are they in a CSS file that isn't being loaded? (Use Firefox and Firebug to see is the CSS file is showing a 404 Not found error)

[jQuery] Re: Interesting on document ready question

2008-12-30 Thread MorningZ
If you've got 5000 of those, it's *seriously* time to reconsider your coding techniques. depending on that much JavaScript is just plain old stupid.. On Dec 30, 8:59 pm, Kean wrote: > Is document ready "actually" an event handler? > > Let's say I have > > $(function(){ > > }); > > $(f

[jQuery] Re: $(document).ready fires before CSS is rendered?

2008-12-30 Thread Kean
I thought I saw an article covering this topic in learningjquery.com or somewhere else. Anyone care to show me where the article is?

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Kean
Just a nitpick. Don't do this var datascape = new Object(); var datascape2 = new Array(); Instead var datascape = {}; var datascape2 = []; On Dec 30, 1:27 pm, "Alexandre Plennevaux" wrote: > wair, you're all scarrying me: > > i often do things like this: > > var datascape = new Object(); > >

[jQuery] Interesting on document ready question

2008-12-30 Thread Kean
Is document ready "actually" an event handler? Let's say I have $(function(){ }); $(function(){ }); $(function(){ }); $(function(){ }); $(function(){ }); etc . around 5000 of those. Will it actually degrade performance like 5000 bind()? My guess is not much performance penalty, but ag

[jQuery] Ajax lists makes the page jump

2008-12-30 Thread Loa
Yo! Just found this mail group, if I'm in the wrong place just flame on ;) To the business. So I got a page with this structure: Im just fetching a list of items with xml and inserting them as rows in the table. And the reason I use ajax is that I want some smooth paging t

[jQuery] Ajax lists makes the page jump

2008-12-30 Thread Loa
Yo! Just found this mail group, if I'm in the wrong place just flame on ;) Hm.. tried to post but it never showed up... hope it doesn't end up in "double post" To the business. So I got a page with this structure: Im just fetching a list of items with xml and inserting the

[jQuery] Drag and Drop Sortable List and ASP.Net

2008-12-30 Thread cantelopehead
I have a drag and drop sortable list that uses jQuery and the UI finally works great. The problem I'm having is that the ASP button I'm using POSTs back to the server the items in the original order. How do I get the modified sequence back to the server? Just looking for some general guidance or

[jQuery] Re: Posting multiple values from a checkbox

2008-12-30 Thread Michael Geary
Your checkboxes all have the same ID attribute, and they have no NAME attribute. Give each one a unique ID and NAME. You can use same value for those two attributes in a single checkbox, or they can be different. But each ID and each NAME should be unique. Also, quote all of your attribute values

[jQuery] Re: Posting multiple values from a checkbox

2008-12-30 Thread Karl Rudd
Correct, the syntax is wrong. You want: wrote: > > I've got checkboxes on my page. When I use the $.post method, it's > only transmitting the first value out of my list. Here's my code: > > $.post("http://localhost/search_engine.php",{ >food_type: $("#food

[jQuery] Posting multiple values from a checkbox

2008-12-30 Thread tradeallday
I've got checkboxes on my page. When I use the $.post method, it's only transmitting the first value out of my list. Here's my code: $.post("http://localhost/search_engine.php",{ food_type: $("#food_type").val(), food

[jQuery] Re: Beginner question about toogeling a status

2008-12-30 Thread brian
On Mon, Dec 22, 2008 at 7:20 AM, heohni wrote: > > > This: status.addClass(the_new_status); > prints the new status, but the browser does not show the image which > is connected with the new status class? > Can I somehow refresh the div only? Is that possible? > Sorry for the delay; I've been a

[jQuery] Re: how to relocate elements without losing data?

2008-12-30 Thread Dave Methvin
> I have to remove() them first before inserting them elsewhere because > otherwise the browser (Firefox in my case) complains about trying to > insert an element that's already a part of the DOM. Can you post a bit of code? It should be possible to select some elements in jQuery and use an inser

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread Dave Methvin
> var $items = $('Helloworld... jQuery will try to parse that with the browser's HTML parser, but it's not HTML. I don't know if that will cause you sorrow or not. http://groups.google.com/group/jquery-en/browse_thread/thread/95718c9aab2c7483/af37adcb54b816c3 As for getting the index, maybe som

[jQuery] Re: $(document).ready fires before CSS is rendered?

2008-12-30 Thread Mauricio (Maujor) Samy Silva
I've tested your code in IE6, IE7, FFox3, Opera 9.5 and Safari on Windows and it works fine as expected. Regards Maurício -Mensagem Original- De: "Matt Wilson" Para: "jQuery (English)" Enviada em: terça-feira, 30 de dezembro de 2008 20:03 Assunto: [jQuery] $(document).ready fire

[jQuery] Submit not propagating.

2008-12-30 Thread TimW66
Hi all, I have a submit button, and a function tied to it via $('form').submit (function() { ... }); When the button is clicked, this function gets executed, and the data gets sent to the server. However, I also call this function via a context menu option (i.e., $('form').submit()). Again, the

[jQuery] Re: closures and for loop question, NS_ERROR_XPC_BAD_CONVERT_JS

2008-12-30 Thread Balazs Endresz
In the closure you have to set the arguments at the start too: return function(parentDiv,image) { ... }(parentDiv,image); but I think it won't work this way because your closure won't be executed right away (as it is inside an event handler) so it doesn't make much sense to put it there. Start

[jQuery] $(document).ready fires before CSS is rendered?

2008-12-30 Thread Matt Wilson
I've got some links that only serve as anchors for javascript, so I use CSS to hide them like this: .requiresjavascript { display:none; } and here's the HTML: Clear all Check all The idea is that for a browser without javascript, those links don't appear. I want to show these links when

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Balazs Endresz
"According to Microsoft, closures are the cause of memory leaks. This is of course deeply wrong, but it leads to Microsoft giving very bad advice to programmers on how to cope with Microsoft's bugs." http://javascript.crockford.com/memory/leak.html This article seems to be a lot more reasonable,

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Alexandre Plennevaux
wair, you're all scarrying me: i often do things like this: var datascape = new Object(); datascape.el = $('#datascape'); datascape.ini = function(){ datascape.el.click(function(){ dothis(); dothat(); }); } is this pattern causing a potential memory leak pr

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread Kean
I believe jQuery does not count/iterate textnode. Maybe there's a function in jQuery but I have no idea. On Dec 30, 12:52 pm, nachocab wrote: > Thank you both, > The only problem is that the right answer isn't 2, it's 3. I'm > actually looking for the index of item#my_item inside the contents >

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Kean
A good reason why closure is used http://yuiblog.com/blog/2006/06/01/global-domination/ On Dec 30, 1:04 pm, Kean wrote: > Klaus is right, > > Here's an article about closure causing > leakshttp://www.javascriptkit.com/javatutors/closuresleak/index.shtml > > On Dec 30, 4:38 am, "Alexandre Ple

[jQuery] Re: HELP: Screening questions for JavaScript developer candidates:

2008-12-30 Thread Kean
Klaus is right, Here's an article about closure causing leaks http://www.javascriptkit.com/javatutors/closuresleak/index.shtml On Dec 30, 4:38 am, "Alexandre Plennevaux" wrote: > Klaus, you got me: frankly i have no "real" idea what is the purpose > of enclosure. > That's abstract art to me. i

[jQuery] Re: Fastest way to clear child elements from a div

2008-12-30 Thread Adam Guichard
It ran in 5ms, but its my understanding if I use the method your suggesting I'll be leaking memory. If I just set the innerhtml = "", I think the dom element's children aren't disposed. They just sit around chewing up memory, so I don't think I can use the method your suggesting. On Dec 30, 2:4

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread nachocab
Thank you both, The only problem is that the right answer isn't 2, it's 3. I'm actually looking for the index of item#my_item inside the contents array. children() doesn't take into consideration the "!!" textnode. On Dec 30, 9:43 pm, Ricardo Tomasi wrote: > var $items = $('Helloworld id="my_ite

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread Ricardo Tomasi
var $items = $('HelloworldGoodnight moon!'); var $my = $items.find('#my_item'); console.info( $items.children().index($my) ); or var $items = $('HelloworldGoodnight moon!'); $items.children().each(function(i){ if ( this.id == 'my_item' ) console.info(i); }); indexOf is a method of the String

[jQuery] Re: Fastest way to clear child elements from a div

2008-12-30 Thread MorningZ
just for laughs...see of document.getElementById("ID of Div Tag").innerHTML = ""; is anything of an improvement On Dec 30, 3:02 pm, Adam Guichard wrote: > I'm using jTemplates to create a client grid, but I'm having trouble > with load times.  When I'm paging through the grid jTemplates is

[jQuery] [ListNav] Solution to a severe performance problems with jQuery/ListNav and the Blueprint CSS framework

2008-12-30 Thread Bob Hutchison
Hi, I've encountered, and worked around, a rendering performance problem in WebKit based browsers. I'm working on a webapp and a particular uncontrived page is rendered by FireFox in about 0.5s while Safari takes about 12s -- that's about 20 times slower. And 12s is way too long from any

[jQuery] [ListNav] Solution to a severe performance problems with jQuery/ListNav and the Blueprint CSS framework

2008-12-30 Thread Bob Hutchison
Hi, [reposted, didn't appear in archives... sorry for the noise] I've encountered, and worked around, a rendering performance problem in WebKit based browsers. I'm working on a webapp and a particular uncontrived page is rendered by FireFox in about 0.5s while Safari takes about 12s -- that

[jQuery] how to relocate elements without losing data?

2008-12-30 Thread Nathan Ridley
I've had to write a big workaround to a problem I'm having. I've been creating an application which involves me extracting DOM elements and inserting them back elsewhere in the page. I have to remove() them first before inserting them elsewhere because otherwise the browser (Firefox in my case) c

[jQuery] Fastest way to clear child elements from a div

2008-12-30 Thread Adam Guichard
I'm using jTemplates to create a client grid, but I'm having trouble with load times. When I'm paging through the grid jTemplates is taking 4+ seconds to clear the grid and 2+ seconds to load it. I've got some work to do to make the loading time go down, but I'm worried about the clearing time.

[jQuery] Re: pausing jquery

2008-12-30 Thread Joe
Nice plugin Mike... On Dec 30, 1:49 pm, "Michael Geary" wrote: > You can call setTimeout again and keep track of your loop counter, or you > can use setInterval. > > To make that easy, I posted a slowEach() plugin to this group a while back. > It may be just what you need. Here's the original po

[jQuery] Re: Generated id seems not to trigger click event

2008-12-30 Thread Ricardo Tomasi
$('#pageLeft').click(... looks for the element with that ID at the time its run. If there's no match, it won't do anything. You need to either add the event listeners after you change the element's ID, or use event delegation. See the LiveQuery plug-in: http://brandonaaron.net/docs/livequery/ -

[jQuery] Re: getting the id of a clicked object

2008-12-30 Thread Ricardo Tomasi
Yeah I know, that was stupid, it would be rendered as text. Sleep is a good thing. On Dec 30, 2:57 am, Kean wrote: > Richardo, > > LOL

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread Kean
$('Helloworld!!Goodnight moon!').find("#my_item").each (function(){ alert(this.innerHTML); }); Hmm I'd be interested to see how this can be done without using each On Dec 30, 12:07 pm, nachocab wrote: > Actually that gives an error. It should be: > var $items = $('Helloworld!! id="m

[jQuery] Re: REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread nachocab
Actually that gives an error. It should be: var $items = $('Helloworld!!Goodnight moon!'); for(var i=0; i <= $items.children().length; i++){ if ( $items.contents()[i].id == 'my_item' ) console.info(i) } It also needs to work with $items.contents()[i].className On Dec 30, 8:30 pm, nach

[jQuery] Re: pausing jquery

2008-12-30 Thread Michael Geary
You can call setTimeout again and keep track of your loop counter, or you can use setInterval. To make that easy, I posted a slowEach() plugin to this group a while back. It may be just what you need. Here's the original post: http://groups.google.com/groups/search?q=sloweach+jquery+plugin Here

[jQuery] Re: Coda Slider

2008-12-30 Thread Simon Teufel
thank you sir Am 30.12.2008 um 20:31 schrieb Kean: Yes, just add the class jFlowPrev to your previous button and class jFlowNext to your next button. View the demo source to get the rest.

[jQuery] Re: Coda Slider

2008-12-30 Thread Kean
Yes, just add the class jFlowPrev to your previous button and class jFlowNext to your next button. View the demo source to get the rest. On Dec 30, 11:02 am, "simonteu...@googlemail.com" wrote: > Hello Kean > > Is jFlow also offering the usage of arrows at the left and right > sides? > > Nice t

[jQuery] REFACTOR: contents() with index() or indexOf()

2008-12-30 Thread nachocab
Hi everyone, I'd like to know if there's a way to do this without using a for loop. You can just paste this in Firebug: var $items = $('Helloworld!!Goodnight moon!'); for(var i=0; i <= $items.children().length; i++){ if ( $items.contents()[i].id == 'my_item' ) console.info(i) } Keep

[jQuery] Re: TableSorter Pagination -- Breaks when wrapped in table [example]

2008-12-30 Thread MorningZ
Perhaps after 6 weeks it's time to move to a different solution? (ditch the and use floating 's or the like) the tablesorter plugin hasn't been working on in a long time by the person who wrote it, the chances of you getting your answer of "why did it break?" is super slim to none On Dec 30,

[jQuery] Re: Coda Slider

2008-12-30 Thread simonteu...@googlemail.com
Hello Kean Is jFlow also offering the usage of arrows at the left and right sides? Nice that you answered so fast. I also want to have a ajax live search. I already tried liveSearch by andreaslagerkvist.com. But it didnt work under windows ie7. Is there also an other option with jquery. You c

[jQuery] Re: pausing jquery

2008-12-30 Thread MorningZ
Pause on the server side then. On Dec 30, 1:18 pm, bwdev wrote: > Yes but the set TImeout seems to happen once.  I need it to pause on > each interation of the loop. > > On Dec 30, 1:05 pm, "Michael Geary" wrote: > > > Not only will that lock up the current browser, in many browsers it wil

[jQuery] Re: TableSorter Pagination -- Breaks when wrapped in table [example]

2008-12-30 Thread ripcurlksm
Why would my script break when I wrap a table around it? ripcurlksm wrote: > > still looking for a solution... > > > > ripcurlksm wrote: >> >> I have a working version of the jQuery TableSorter but when I wrap the >> div in a table, the pagination stops working. This appears to be a CSS >>

[jQuery] Re: Masked Input Plugin 1.2.1 Released

2008-12-30 Thread SeanthePaddy
hi josh thanks for all your work its looking good. a) any chance of getting this to work with the meta data plugin ? b) any idea when the above (blank input) could be addressed - just wondering as i need to make a call on wether i use it on a current project. many thanks! sean

[jQuery] Re: Masked Input Plugin 1.2.1 Released

2008-12-30 Thread SeanthePaddy
hi josh thanks for all your work its looking good. a) any chance of getting this to work with the meta data plugin ? b) any idea when the above (blank input) could be addressed - just wondering as i need to make a call on wether i use it on a current project. many thanks! sean

[jQuery] Re: .load quircky

2008-12-30 Thread jjshell
Perfect! Thank you very much! :) -jj. On 30 déc, 17:20, Joe wrote: > Hey JJ, > > After the delete.php?id="X" is loaded and completed, do you then want > the display.php to be loaded?  If so, place it in a callback function > so it will be completed after delete.php has completed/sent a > respo

[jQuery] Re: pausing jquery

2008-12-30 Thread bwdev
Yes but the set TImeout seems to happen once. I need it to pause on each interation of the loop. On Dec 30, 1:05 pm, "Michael Geary" wrote: > Not only will that lock up the current browser, in many browsers it will > lock up *every* browser window or tab. Plus, if someone is running on > batter

[jQuery] Jquery Tabs issue, linking to another tab from within the same document...

2008-12-30 Thread Ted
I'm having a problem with Jquery's tab plugin. Specifically, I've got a page with a couple of tabs. On that page, in one of the tabs, is a link to another tab. However, the link doesn't work. Additionally, I've noticed that on my main navigation, if I'm on the page with multiple tabs, and I click

[jQuery] Re: pausing jquery

2008-12-30 Thread Michael Geary
Not only will that lock up the current browser, in many browsers it will lock up *every* browser window or tab. Plus, if someone is running on battery power it will drain the battery needlessly. As Richard said, setTimeout is the right solution: doSomething(); setTimeout( function() {

[jQuery] plugin jquery.validate added function tooltips sample

2008-12-30 Thread Paulo Eugênio
sample http://www.aemundo.com.br/jquer/validate/demo.html

[jQuery] Re: Coda Slider

2008-12-30 Thread Kean
Maybe try jFlow? http://www.gimiti.com/kltan/wordpress/?p=46 On Dec 30, 6:51 am, "simonteu...@googlemail.com" wrote: > Hello jQuery Community > > I have a question about the Coda Slider. > > How can I create more than one Slider on one Webpage? > > The first works. But the second is just "loadin

[jQuery] Re: pausing jquery

2008-12-30 Thread Richard D. Worth
If you don't want to lock the browser, use setTimeout https://developer.mozilla.org/En/DOM/Window.setTimeout - Richard On Tue, Dec 30, 2008 at 12:17 PM, Joe wrote: > > // Similar to PHP's sleep function. > function pause(numOfSeconds) { > >numOfSeconds *= 1000; >var startTime = new Dat

[jQuery] Re: pausing jquery

2008-12-30 Thread Joe
// Similar to PHP's sleep function. function pause(numOfSeconds) { numOfSeconds *= 1000; var startTime = new Date().getTime(); while (new Date().getTime() < startTime + numOfSeconds); return false; } // Let's pause for 5 seconds... pause(5); console.log('Awake Now'); A simple wa

[jQuery] Re: Cycle plugin messing with hidden list

2008-12-30 Thread Mike Alsup
> I am using the cycle plugin to swap entire pages for my navigation.  On one > page, I have a unordered list that is supposed to be "display:none" by > default.  Then when a link on the page is click, it shows slowly.  However, > for some reason the cycle plugin seems to be showing it by default

[jQuery] Coda Slider

2008-12-30 Thread simonteu...@googlemail.com
Hello jQuery Community I have a question about the Coda Slider. How can I create more than one Slider on one Webpage? The first works. But the second is just "loading". Does someone have an idea. I would thank you for an answer. Simon

[jQuery] pausing jquery

2008-12-30 Thread bwdev
I have the following code and want to basically write something out, let it sit for a while, and then write something else out...how do I do the pause/wait? Thanks! myURL="getSearchResults.php"; $.getJSON(myURL, function(data) { for

[jQuery] Generated id seems not to trigger click event

2008-12-30 Thread Chuk
Hi. I'm using CGIDEV2 with AJAX, JQuery, and JSON to page through search results (showing 100 at a time). For the paging, I have a beginning arrow, page left arrow, page right arrow, and an end arrow. When I am on the first page of results, the beginning and page left arrows have an id of "begin

  1   2   >