|
|
 |
RE: FN-FORUM: iframes, was: site check please
date posted 14th May 2007 14:24
> -----Original Message-----
> From: [EMAIL REMOVED] [EMAIL REMOVED] On Behalf Of Richard
> Fletcher
> Sent: 14 May 2007 14:20
> To: FN-FORUM / [EMAIL REMOVED]
> Subject: Re: FN-FORUM: iframes, was: site check please
>
>
> Ben Johnson (Neogic) F wrote:
> > Phil wrote:
> >> Nice. Just a couple of points though, is $() defined somewhere else as
> >> something doing getElementById()? And are the three equals signs
> together
> >
> >> a typo (on the line "if(sTmp==='')") ?
> >
> >
> > $ is a commonly defined (but not built-in) Javascript function that acts
> as
> > a shortcut to getElementById().
>
> It actually does more. Elements returned by getElementByID are not
> extended in the way those elements returned by $() are.
>
> Using the prototype js this would not work:
>
> e=document.getElementByID('somediv');
> e.hide();
>
> This would:
>
> e=$('somediv');
> e.hide();
>
> But this last example can be done better if e is not to be used again:
>
> $('somediv').hide();
If this is a non-standard function, where is it usually defined? Is there a
standard implementation of it that everybody uses?
Phil
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.5.467 / Virus Database: 269.7.0/803 - Release Date: 13/05/2007
12:17
|
 |
|