[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: 1-to-many HTML links, prototyped


html link hover style
Bob DuCharme wrote:

> Changing the XHTML content model for the 'a' element to allow nesting of 
> them is an awfully small change to make to its DTD. (What would you with 
> with deeper nesting levels? Turn them into submenus.)

Some time ago, on www-style[1] I was also experimenting with nested 
links, only to find out they are illegal. What I wanted to do was to 
present a URI as a link, where clicking on any section of it would load 
that URL (up to the level you clicked on):


<a href="http://somDomain.org/" xml:space="default">
    http://somDomain.org/
    <a href="http://somDomain.org/level1/">
       level1/
       <a href="http://somDomain.org/level1/level2/">
          level2/
       </a>
    </a>
</a>


Supposing that the xml:space would trigger the renderer to strip all 
whitespace, that would render a link:

http://somDomain.org/level1/level2/

...leading to multiple levels of the same URI. Your location would 
depend on where exactly you clicked on that link.

Invalid markup was not my only problem. I also had a CSS conflict since 
the nesting needed to be the other way around. To clarify, I wanted to 
apply the following:

<style type="text/css">
a:link{text-decoration:none;}
a:hover{color:red;text-decoration:underline;}
</style>

To make the link text effect work from the start till the level the 
hover was on. For that to (buggy and coincidentally) work, the link 
would have to be as

<a href="http://somDomain.org/level1/level2/" xml:space="default">
    <a href="http://somDomain.org/level1/">
       <a href="http://somDomain.org/">
          http://somDomain.org/
       </a>
       level1/
    </a>
    level2/
</a>


Of course, I know of no browser that will render that as I intended and 
keep the link interactivity intact.

It's a shame that links that share the same base have no awareness of 
that. Actually, (X)HTML links are not aware of other links in any way, 
nor anyone has come up with "complex" or related links and their 
presentation.

[1] http://lists.w3.org/Archives/Public/www-style/2002Jan/0115.html

Just my thoughts.

Manos





PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.