On Sep 6, 4:50 am, Klaus Hartl <[EMAIL PROTECTED]> wrote:
> Pops wrote:
> > Sorry if I am a dounce, but I still don't see the invalidity of it.
>
> > Do you have an example to show how this is incorrect in relationship
> > to anything (DOM? CSS?) ?
>
> ul and ol elements may only have li element
You're right. There isn't any technical problem at all, but it is a design
decision the HTML designers made, for simplicity or whatever other reason.
In the HTML specs, elements are only allowed children elements:
http://www.w3.org/TR/html401/struct/lists.html#edef-UL
As mentioned, most browsers
Exactly. It is a subtle point, but lists do not contain other lists, they
contain items which may be lists.
On 9/6/07, Karl Rudd <[EMAIL PROTECTED]> wrote:
>
>
> He's referring to how lists (UL and OL) are built up in the DOM (from
> the HTML). Lists can only have LI elements as children.
>
> So t
Karl Rudd wrote:
Thanks for finishing that off Joel. :)
Joel and Karl, well explained, let's have a beer sometime :-)
--Klaus
Pops wrote:
Sorry if I am a dounce, but I still don't see the invalidity of it.
Do you have an example to show how this is incorrect in relationship
to anything (DOM? CSS?) ?
ul and ol elements may only have li elements as children, that's written
in the DTD.
http://www.w3.org/TR/html401/st
Thanks for finishing that off Joel. :)
Karl Rudd
On 9/6/07, Joel Birch <[EMAIL PROTECTED]> wrote:
>
> ...so in browsers that do the error correction on this invalid markup,
> if you wrote this invalid HTML:
>
>
> Blah
> Blah
>
> Blah
>
>
>
> and then wrote this jQuery
...so in browsers that do the error correction on this invalid markup,
if you wrote this invalid HTML:
Blah
Blah
Blah
and then wrote this jQuery code:
$('ul>ul').doSomething();
you could not rely on it working, even though your HTML looks like it
should, because bef
Err hmmm I thought I explained it. Let me try again.
This is invalid:
This is valid:
Anything that you want to put as a "child" of a list has to be either
an LI or wrapped in an LI. That's just the way things are.
Hmmm let's see if I can't explain it another way...
The fol
Sorry if I am a dounce, but I still don't see the invalidity of it.
Do you have an example to show how this is incorrect in relationship
to anything (DOM? CSS?) ?
The technical problem I see using this wrapping method is that you get
redundant (bubbling?) events. Is that right?
Thanks
--
HLS
He's referring to how lists (UL and OL) are built up in the DOM (from
the HTML). Lists can only have LI elements as children.
So these are valid:
blah
blah
blah
But these are invalid:
blah
blah
blah
Browsers probably attempt to twist the
Klaus,
Today, this has thrown me for a loop:
> Is that reallly the HTML? If so, it is invalid and you cannot expect any
> selector to be reliable in any browsers. I'm not refering to the missing
> slashes in the closing tag - I assume you just left them out in the
> example here -, but the incor
On Sep 5, 4:11 am, Klaus Hartl <[EMAIL PROTECTED]> wrote:
> Is that reallly the HTML? If so, it is invalid and you cannot expect any
> selector to be reliable in any browsers. I'm not refering to the missing
> slashes in the closing tag - I assume you just left them out in the
> example here -,
Aaron,
The bottom line really is then, in the internet world, there no really
rules and consistent methods. You have PHP only methods, I have WCX
only methods, others have their own methods. (Incidentally the PHP
Windows developer use to work for us when it wasn't a "big thing"
then. :-))
Many
On 9/5/07, Pops <[EMAIL PROTECTED]> wrote:
>
> No, I am not describing CSS.
Perhaps "CSS classes" wasn't the right term to use. What I really meant was
that you should be using the HTML "class" attribute if you want to assign an
identifier to many elements; it can be for many more things than jus
Pops wrote:
Thanks Klaus. I'm still learning. Maybe should show the light here.
I have a 7 year old Windows HELP TOC generator that creates an UL list
of about 500 links, its about 4 levels deep.
On 9/5/07, Pops <[EMAIL PROTECTED]> wrote:
>
> In practice, element ids are meant to be unique for practical
> purposes but there is no standard restriction that it there SHOULD NOT
> be more than one defined.
Actually, but HTML 4.01[1] and XML 1.0[2] specify that IDs must be unique.
>From the
On Sep 5, 2:40 am, "Aaron Heimlich" <[EMAIL PROTECTED]> wrote:
> On 9/5/07, Pops <[EMAIL PROTECTED]> wrote:
>
>
>
> > Yes, $('#foobar') returns the 1st one, but you can have as many
> > id="foobar" your applications needs and use this to find them all:
>
> While that's technically true, IDs are
On 9/5/07, Pops <[EMAIL PROTECTED]> wrote:
>
> Yes, $('#foobar') returns the 1st one, but you can have as many
> id="foobar" your applications needs and use this to find them all:
While that's technically true, IDs are meant to be unique to a page. For
what you're describing, using CSS classes i
On Sep 4, 2:53 pm, "Andy Matthews" <[EMAIL PROTECTED]> wrote:
> One issue though...$('#foobar') would only return the first occurrence of
> foobar because it uses getElementbyID which returns the first occurrence.
> That's desired behavior as there should only ever be one ID of a certain
> name
Thanks Klaus. I'm still learning. Maybe should show the light here.
I have a 7 year old Windows HELP TOC generator that creates an UL list
of about 500 links, its about 4 levels deep.
Pops wrote:
You can so do multiple selects, like find all divs and h3
$('div h3')
but if you use the comma:
$('div,h3')
that says find the H3 tag that is within div, I think
It's vice versa. Find all div and h3 *elements*:
$('div, h3') // grouping
Find all h3 elements that are desc
On Sep 4, 2:42 pm, Pops <[EMAIL PROTECTED]> wrote:
> You can so do multiple selects, like find all divs and h3
>
> $('div h3')
>
> but if you use the comma:
>
> $('div,h3')
>
> that says find the H3 tag that is within div, I think
I knew I had that backwards!
$('div h3') finds all h3
f a certain
name per page.
-Original Message-
From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Pops
Sent: Tuesday, September 04, 2007 1:43 PM
To: jQuery (English)
Subject: [jQuery] Re: Request: Quick tutorial on jQuery filtering/limiting
methods
On Sep 4, 10:1
On Sep 4, 10:11 am, "Andy Matthews" <[EMAIL PROTECTED]> wrote:
> Hrm...
>
> But that didn't work. So I'm wanting to learn HOW I can do this sort
> of thing and a tutorial on these methods would help immensely.
Have you tried the interactive Selector tester tool?
http://www.woods.iki.fi/interac
__
>
> From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Sean Catchpole
> Sent: Tuesday, September 04, 2007 8:37 AM
> To: jquery-en@googlegroups.com
> Subject: [jQuery] Re: Request: Quick tutorial on jQuery filtering/limiting
> methods
>
> I
ilto:[EMAIL PROTECTED] On
Behalf Of Sean Catchpole
Sent: Tuesday, September 04, 2007 8:37 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Request: Quick tutorial on jQuery filtering/limiting
methods
I'll try to pull out the time later to write a more thorough response, but
for now t
A...
I wondered if there was a way to invert the contains() method. I have
to say that's not all that intuitive...especially since you've got the
contains() in quotes inside the not().
Thank you though for posting that. Hopefully that'll spur some really
good experimentation.
On Sep 4, 8:36
I'll try to pull out the time later to write a more thorough response, but
for now this is how you would code than line your pasted:
$("label").not(":contains(' ')")
~Sean
On 9/4/07, Andy Matthews <[EMAIL PROTECTED]> wrote:
>
>
> Anyone have any input on this? Surely someone has written a tute
Anyone have any input on this? Surely someone has written a tute on
these semi-confusing methods.
--
I've seen some of you jQuery masters bust out with these amazing
chains, but I can't quite grasp how some of them are crafted. I
29 matches
Mail list logo