W3C home > Mailing lists > Public > whatwg@whatwg.org > October 2009

[whatwg] <a onlyreplace>

From: Chris Taylor <Chris.Taylor@figureout.com>
Date: Thu, 22 Oct 2009 10:22:41 +0100
Message-ID: <7805560CD71B3B4793F5FDBCDE22E52B1994491BAB@tpexmb01>
Looking at this (simplified) example from Markus:

<html>
   <head>
     <title id="title">My title</title>
     <base onlyreplace="title">
   </head>
   <body>
     <ul id="navigation">
       <li><a href="otherpage.html" onlyreplace></li>
     </ul>
     <div id="contents">
       <p>Text</p>
     <div>
   </body>
</head>

Would it be better to be able to specify multiple onlyload base elements? Like so:

<html>
   <head>
     <title id="title">My title</title>
     <base id="onlyreplace1" onlyreplace="title">
     <base id="onlyreplace2" onlyreplace="contents">
   </head>
   <body>
     <ul id="navigation">
       <li><a href="otherpage1.html" onlyreplace="onlyreplace1">Replace the title</a></li>
         <li><a href="otherpage2.html" onlyreplace="onlyreplace2">Replace the content</a></li>
     </ul>
     <div id="contents">
       <p>Text</p>
         <p><a href="otherpage2.html" onlyreplace="onlyreplace2">Replace me</a></p>
     <div>
   </body>
</head>

That way it gives authors much more control over that they choose to be replaced. This does mean that the "onlyreplace" attribute on links (and forms) should perhaps be renamed "onlyreplaceref" or similar. Has this idea already been put forward by someone else? (I may have missed it).

Chris


This message has been scanned for malware by SurfControl plc. www.surfcontrol.com
Received on Thursday, 22 October 2009 02:22:41 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:18 UTC