Re: [WSG] Catch 22 list problem
I know this is a fairly old topic, but it's come up several times and I don't know if this solution has ever been stated before: You can actually set the value attribute for the li elements with the number you want it to have. After that, all succeeding lis will be numbered based on that one. Check the bottom of this link for details: http://www.w3.org/TR/html401/struct/lists.html#h-10.2 (For those that don't remember, this discussion was about starting an ordered list at a number other than one.) Jason Friesen wrote: That's pretty much what we did; usually hx and p, with ul where appropriate. But I still look longingly at the counters in CSS, and grimace everytime someone says, But we have to add in another point between 2 and 3... On 2007-Oct-14, at 14:10 , [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Certainly for this example, the use of an ordered list is incorrect - there is a strong hint there in the description; this should be marked up with p tags, with the identifier as the first bit of text, ie the number is content in this example. If you think about it, the 'label' of each item MUST remain the same, regardless of how much or little of the document is quoted, and more to the point adding or removing content MUST NOT alter the numbering. This is the exact opposite of what an OL is intended to do. Mike *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *** -- Christian Snodgrass Azure Ronin Web Design http://www.arwebdesign.net/ http://www.arwebdesign.net Phone: 859.816.7955 *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
RE: [WSG] Catch 22 list problem
Certainly for this example, the use of an ordered list is incorrect - there is a strong hint there in the description; this should be marked up with p tags, with the identifier as the first bit of text, ie the number is content in this example. If you think about it, the 'label' of each item MUST remain the same, regardless of how much or little of the document is quoted, and more to the point adding or removing content MUST NOT alter the numbering. This is the exact opposite of what an OL is intended to do. Mike -Original Message- From: [EMAIL PROTECTED] on behalf of Jason Friesen Sent: Sat 10/13/2007 11:53 PM To: wsg@webstandardsgroup.org Subject: Re: [WSG] Catch 22 list problem My 2cent; At my College, we often wish to publish excerpts from official policy manuals tc where we're showing Section 2.4.7, Paragraphs B through G, points 3-16, and so on... The CSS counter mechanisms are great for showing the whole document, but fall completely apart when you want to reference just a piece of the document... *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *** winmail.dat
Re: [WSG] Catch 22 list problem
Going back to the original post: Pick your poison: 1. Invalid code 2. Use a transitional DOCTYPE 3. Set value with DOM-script I'm surprised that no one has said #2; just fall back to a transitional doctype. You can still write your markup with standards in mind, use the deprecated attribute, *and* validate without any scripting etc. This is exactly what I did a couple of years ago when redesigning a site. I created the templates in XHTML 1.0 Strict, but due to a ton of legacy data concerns just changed the doctype to HTML 4.0 Trans and all was well. Of course, you may have production issues that prevent the Transitional doctype, in which case I'd go with the invalid. ~ Tim tjameswhite.com'http://www.tjameswhite.com;tjameswhite.com Yahoo! oneSearch: Finally, mobile search that gives answers, not web links. http://mobile.yahoo.com/mobileweb/onesearch?refer=1ONXIC *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
That's pretty much what we did; usually hx and p, with ul where appropriate. But I still look longingly at the counters in CSS, and grimace everytime someone says, But we have to add in another point between 2 and 3... On 2007-Oct-14, at 14:10 , [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Certainly for this example, the use of an ordered list is incorrect - there is a strong hint there in the description; this should be marked up with p tags, with the identifier as the first bit of text, ie the number is content in this example. If you think about it, the 'label' of each item MUST remain the same, regardless of how much or little of the document is quoted, and more to the point adding or removing content MUST NOT alter the numbering. This is the exact opposite of what an OL is intended to do. Mike *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
How hard would it be to have the list start with two empty elements, removed from view in what ever way works best? Mike It would be very simple, though you'd need to use a class for it. Empty list items isn't exactly semantic, however, and anyone browsing with css turned off would see two empty list items, as would those using text-based browsers. I know that's not a high percentage of the internet population, but something to consider. I would probably go with the invalid code at this point, especially considering the fact that the css methods are not supported by IE 6 which as we all know still has it's claws dug firmly into the market. I do not, however, think that the numbers in an ordered list are content in all cases. I think there is a line between when the numbers are content and when they are presentational. Semantically speaking, I think the ordered list should only be used when the ORDER of the items is of importance to the meaning of the document. If you can take away the numbers without taking away from the meaning of the document, then in my book the numbers have crossed the line from content to presentation. At that point they are there purely as a visual means of separating pieces of the document to make it easier to read. Like bullets, asterisks and arrows they would fall in the realm of presentation. Not sure if I'm being totally clear there, but that's sort of how I see it. jm *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
[EMAIL PROTECTED] wrote: How hard would it be to have the list start with two empty elements, removed from view in what ever way works best? That would be dangerously close to using markup to achieve a certain visual effect though. P -- Patrick H. Lauke __ re·dux (adj.): brought back; returned. used postpositively [latin : re-, re- + dux, leader; see duke.] www.splintered.co.uk | www.photographia.co.uk http://redux.deviantart.com __ Co-lead, Web Standards Project (WaSP) Accessibility Task Force http://webstandards.org/ __ Take it to the streets ... join the WaSP Street Team http://streetteam.webstandards.org/ __ *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
Jens Brueckmann skrev: there do exist counters in CSS, see http://www.w3.org/TR/CSS2/generate.html#counters but, as you might have guessed, they are not supported by Internet Explorer. Yes. I was a bit too short on that one... As you already observed, list counters are rather content than presentation, so either CSS or JavaScript are somewhat questionable for achieving your aim. So personally, I would either ignore the validation problem or use a customized DTD. Next question: How would a custom DTD affect standards-compliance vz. quirks mode. That is a subject that I have no knowledge about. I totally agree that a custom DTD is *the* best solution, though - provided it will not trigger quirks mode! I prepared a short example at http://lairx.de/071011/numbering-lists.html Triggers strict mode in Firefox - what about MSIE, Opera, Safari, etc? It uses an extended DTD, where the VALUE attribute for the LI element and the START attribute for the OL element have been added. Furthermore a CSS example using automatic numbering is provided. Great stuff. Thanks! Also: Thanks to everyone else that has replied to my question! Doing some small experiments I think there might be an additional reason why one should be cautious in setting list-numbers in CSS. It makes it harder to access and/or change those numbers in JavaScript. Lars Gunther *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
Next question: How would a custom DTD affect standards-compliance vz. quirks mode. That is a subject that I have no knowledge about. I prepared a short example at http://lairx.de/071011/numbering-lists.html Triggers strict mode in Firefox - what about MSIE, Opera, Safari, etc? Opera 9.23/Win32+Linux and MSIE 6 SP1 both render in strict mode as well. I do not know about Safari though. Cheers, jens -- Jens Brueckmann http://www.yalf.de *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
On Oct 13, 2007, at 10:10 PM, Jens Brueckmann wrote: I prepared a short example at http://lairx.de/071011/numbering- lists.html Triggers strict mode in Firefox - what about MSIE, Opera, Safari, etc? Opera 9.23/Win32+Linux and MSIE 6 SP1 both render in strict mode as well. I do not know about Safari though. Safari, WebKit, Konqueror 3.5.7 : Strict mode. iCab: I'm not sure. Its error console says 'unrecognised doctype', and my bookmarklet doesn't work in iCab. But I think Strict mode (that would make sense for an unrecognised doctype). IE Mac: Quirks mode. Philippe --- Philippe Wittenbergh http://emps.l-c-n.com *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
RE: [WSG] Catch 22 list problem
I can see what you mean, however that would depend to a degree on what the list-number actually represents: perhaps the OP could give us a little more context? Anyway, no-one has spotted a good answer to this problem, so I merely offered this idea for discussion, as an alternative to other bad ideas - my preferred option would really be to work around the problem... Mike -Original Message- From: [EMAIL PROTECTED] on behalf of Patrick H. Lauke Sent: Sat 10/13/2007 12:25 PM To: wsg@webstandardsgroup.org Subject: Re: [WSG] Catch 22 list problem [EMAIL PROTECTED] wrote: How hard would it be to have the list start with two empty elements, removed from view in what ever way works best? That would be dangerously close to using markup to achieve a certain visual effect though. P -- Patrick H. Lauke *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *** winmail.dat
RE: [WSG] Catch 22 list problem
How hard would it be to have the list start with two empty elements, removed from view in what ever way works best? Mike -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Philippe Wittenbergh Sent: Friday, October 12, 2007 3:22 AM To: wsg@webstandardsgroup.org Subject: Re: [WSG] Catch 22 list problem On Oct 12, 2007, at 4:42 AM, Keryx Web wrote: A. li value=3 is not allowed in strict HTML 4/XHTML 1.0, Spec says use CSS. B. I want to start at 3. C: CSS has no means to specify a start value! Pick your poison: 1. Invalid code 2. Use a transitional DOCTYPE 3. Set value with DOM-script *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
Actually, read this page instead: http://www.arraystudio.com/as-workshop/make-ol-list-start-from-number-different-than-1-using-css.html I just realised that is not in XHTML. On 11/10/2007, Svip [EMAIL PROTECTED] wrote: Try ol start=3 instead. Regards, Svip On 11/10/2007, Keryx Web [EMAIL PROTECTED] wrote: Hi all! Short version: A. li value=3 is not allowed in strict HTML 4/XHTML 1.0, Spec says use CSS. B. I want to start at 3. C: CSS has no means to specify a start value! Pick your poison: 1. Invalid code 2. Use a transitional DOCTYPE 3. Set value with DOM-script Long version: How do we handle clear errors in the (X)HTML specs? This one seems to indicate: a. Lack of communication between (X)HTML WG and CSS WG at W3C b. Bad thinking by the (X)HTML WG (in the past - on this issue), as the starting value is content, not presentation. But regardless of whom I should blame there is a problem to solve. I would like to know which solution that you would use and why. Lars Gunther *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *** *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
Try ol start=3 instead. Regards, Svip On 11/10/2007, Keryx Web [EMAIL PROTECTED] wrote: Hi all! Short version: A. li value=3 is not allowed in strict HTML 4/XHTML 1.0, Spec says use CSS. B. I want to start at 3. C: CSS has no means to specify a start value! Pick your poison: 1. Invalid code 2. Use a transitional DOCTYPE 3. Set value with DOM-script Long version: How do we handle clear errors in the (X)HTML specs? This one seems to indicate: a. Lack of communication between (X)HTML WG and CSS WG at W3C b. Bad thinking by the (X)HTML WG (in the past - on this issue), as the starting value is content, not presentation. But regardless of whom I should blame there is a problem to solve. I would like to know which solution that you would use and why. Lars Gunther *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *** *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
Hi Lars, A. li value=3 is not allowed in strict HTML 4/XHTML 1.0, Spec says use CSS. B. I want to start at 3. C: CSS has no means to specify a start value! But regardless of whom I should blame there is a problem to solve. I would like to know which solution that you would use and why. there do exist counters in CSS, see http://www.w3.org/TR/CSS2/generate.html#counters but, as you might have guessed, they are not supported by Internet Explorer. As you already observed, list counters are rather content than presentation, so either CSS or JavaScript are somewhat questionable for achieving your aim. So personally, I would either ignore the validation problem or use a customized DTD. I prepared a short example at http://lairx.de/071011/numbering-lists.html It uses an extended DTD, where the VALUE attribute for the LI element and the START attribute for the OL element have been added. Furthermore a CSS example using automatic numbering is provided. Cheers, jens -- Jens Brueckmann http://www.yalf.de *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***
Re: [WSG] Catch 22 list problem
I'm in the 'Invalid code' camp here. Of course it matters what your target market is too, and whether it would be an issue if the numbers just didn't show up for IE users (likely the case). To my mind, the numbers in a list are inherently content and should not be passed off to the stylesheet. Cheers, Kit *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] *** smime.p7s Description: S/MIME cryptographic signature
Re: [WSG] Catch 22 list problem
On Oct 12, 2007, at 4:42 AM, Keryx Web wrote: A. li value=3 is not allowed in strict HTML 4/XHTML 1.0, Spec says use CSS. B. I want to start at 3. C: CSS has no means to specify a start value! Pick your poison: 1. Invalid code 2. Use a transitional DOCTYPE 3. Set value with DOM-script I'll choose: 1. Invalid code. No doubts. The start attribute also makes a come-back in html 5: http://www.whatwg.org/specs/web-apps/current-work/multipage/section- lists0.html#lists0 http://www.whatwg.org/specs/web-apps/current-work/multipage/section- lists0.html#start0 iirc, there was also a discussion in the html-wg to bring the start attribute back in the errata's for html 4.01, but obviously nothing came to that, and I can't find it in the archives. List numbers are 'content', after all is said and done. Browser- makers are moving towards using CSS 'counters' to generate the list numbers as an internal mechanism, but it does not take away that those numbers are content. (and CSS counters is a very attractive mechanism to control/alter the presentation of those numbers). Philippe --- Philippe Wittenbergh http://emps.l-c-n.com *** List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm Help: [EMAIL PROTECTED] ***