Re: [jQuery] Beginner questions

2006-10-13 Thread Erin Doak
Title: Re: [jQuery] Beginner
questions


Thanks for your help Blair. I followed your advice for the search
routine and it worked fine.

Erin

$() vs $.():
$() is the 'public' scope, and those functions work with the element
arrays that get selected. $.() is 'private' scope, and is used by code
that works 'inside' jquery. Generally plugins can use $.(), but other
code shouldn't.

As long as the file that has the $(document).ready() is included after
jquery is included, you shouldn't have a problem.

If the element you're trying to find can be identified using a
selector, then you can simply use filter and grab the first element in
the jQuery array. Otherwise, it would be just as easy to simply search
through the jQuery element array:

var jO=$();
var index=-1;
for (var i=0; i
  if (check if jO[i] is what you want) index=i;

If anyone else is reading this, what do
you think about the idea of changing filter so that it can take a
function as well? (f(element) { return true or false })

Blair

On 10/12/06, Erin Doak <[EMAIL PROTECTED]>
wrote:
Why do some functions begin with '$.' such as $.each() but
most don't?

If the call to $(document).ready() is from another included js
file,
what's the best way make sure jQuery is loaded before calling it?

Is there a way to use each() and have it stop part way through?
(I'm
using each() to search for something and I'd like jQuery to stop
when
it's been found.) Is there a better function to use? How about
each()
accepting a Boolean from the called function that let's it know
whether to continue through the collection?

Could someone please fix the Table of Contents at the top of the
API
page to work with Safari?

Is there any common reason why some plugins don't work in Safari?
Such as panView, Tablesorter, Clipregion, some  of the
Interface
demos, TweenBox, 3d Universe (mostly works with some visual
problems)?

Thanks,

Erin

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/




___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] Beginner questions

2006-10-11 Thread Blair McKenzie
$() vs $.():$() is the 'public' scope, and those functions work with the element arrays that get selected. $.() is 'private' scope, and is used by code that works 'inside' jquery. Generally plugins can use $.(), but other code shouldn't.
As long as the file that has the $(document).ready() is included after jquery is included, you shouldn't have a problem.If the element you're trying to find can be identified using a selector, then you can simply use filter and grab the first element in the jQuery array. Otherwise, it would be just as easy to simply search through the jQuery element array:
var jO=$();var index=-1;for (var i=0; i  if (check if jO[i] is what you want) index=i;If anyone else is reading this, what do you think about the idea of changing filter so that it can take a function as well? (f(element) { return true or false })
BlairOn 10/12/06, Erin Doak <[EMAIL PROTECTED]> wrote:
Why do some functions begin with '$.' such as $.each() but most don't?If the call to $(document).ready() is from another included js file,what's the best way make sure jQuery is loaded before calling it?
Is there a way to use each() and have it stop part way through? (I'musing each() to search for something and I'd like jQuery to stop whenit's been found.) Is there a better function to use? How about each()accepting a Boolean from the called function that let's it know
whether to continue through the collection?Could someone please fix the Table of Contents at the top of the APIpage to work with Safari?Is there any common reason why some plugins don't work in Safari?
Such as panView, Tablesorter, Clipregion, some  of the Interfacedemos, TweenBox, 3d Universe (mostly works with some visual problems)?Thanks,Erin___
jQuery mailing listdiscuss@jquery.comhttp://jquery.com/discuss/
___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] Beginner questions

2006-10-11 Thread Erin Doak
Why do some functions begin with '$.' such as $.each() but most don't?

If the call to $(document).ready() is from another included js file, 
what's the best way make sure jQuery is loaded before calling it?

Is there a way to use each() and have it stop part way through? (I'm 
using each() to search for something and I'd like jQuery to stop when 
it's been found.) Is there a better function to use? How about each() 
accepting a Boolean from the called function that let's it know 
whether to continue through the collection?

Could someone please fix the Table of Contents at the top of the API 
page to work with Safari?

Is there any common reason why some plugins don't work in Safari? 
Such as panView, Tablesorter, Clipregion, some  of the Interface 
demos, TweenBox, 3d Universe (mostly works with some visual problems)?

Thanks,

Erin

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/