Reply to |OT| HTML form action is URI with query part when method=GET

Your name:

Reply:


Posted by John Dunlop on 09/30/05 23:03

Marcel wrote:

> <form method="GET" action ="de.php?pageno=5">

I can't see anything in the HTML4.01 spec which forbids this. It's
valid, that's easily checkable; it also complies with at least one
reading of the prose. What's left is to see what browsers make of it.

On submission, according to the spec, a question mark is appended to the
value of the action attribute and the form data set (name/value pairs) is
then appended. Here, the action URL already has a question mark, so
appending another question mark gives a URL with two question marks, e.g.

http://host.invalid/foo?bar=1?baz=2

If arg_separator is the ampersand '&', the first and second arguments will
combine and PHP will recognise only one variable: name 'bar', value
'1?baz=2'.

As to browsers, YMMV.

--
Jock

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация