W3C home > Mailing lists > Public > whatwg@whatwg.org > March 2006

[whatwg] Targetting different anchors after submitting the form

From: Mikko Rantalainen <mikko.rantalainen@peda.net>
Date: Mon, 06 Mar 2006 16:25:12 +0200
Message-ID: <440C4648.4060007@peda.net>
Currently it's possible to do stuff like this

<form action="url#anchor">
<input name="foo" type="submit">
<input name="bar" type="submit">
</form>

and the UA scrolls down to element with id "anchor" on the page 
returned by the server. It would be nice to be able to set target 
anchor on per-submit-button basis.

Perhaps something along the lines

<form action="url">
<input name="foo" type="submit" anchor="xfoo">
<input name="bar" type="submit" anchor="xbar">
</form>

would result to action urls "url#xfoo" and "url#xbar" respectively. 
Perhaps even if the above example had action="url#xzoo", in which 
case the new anchor attribute would override the fallback behavior.

Is it too much to add a new attribute for something like this?

Note that the server cannot see any of these anchor urls. Only the 
UA is able to scroll to correct position after receiving output from 
the server.

-- 
Mikko
Received on Monday, 6 March 2006 06:25:12 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:58:45 UTC