lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lynx-dev Lynx (2.8.2rel.1) botches input type=submit value= w/spaces


From: Klaus Weide
Subject: Re: lynx-dev Lynx (2.8.2rel.1) botches input type=submit value= w/spaces
Date: Tue, 10 Aug 1999 03:56:38 -0500 (CDT)

On Tue, 10 Aug 1999, John Hascall wrote:
> 
>    As of HTML 4.0 (from http://www.w3.org/TR/REC-html40/types.html)
>    [note that last paragraph]:
> 
> + 6.2 SGML basic types
> [most snipped] 
> +     User agents may ignore leading and trailing white space in CDATA
> +     attribute values (e.g., "   myval   " may be interpreted as "myval").
> +     Authors should not declare attribute values with leading or trailing
> +     white space.
> 
>     So, I stand corrected.  (I think)
> 
>     But, I still think this is a p*ss poor idea.
>     I know I'm forever doing CGI forms which 'remember' input
>     values from invocation to invocation -- that is:
> 
>       <form ...><input type=text name=foo value="">...</form>
> 
>     and if the user type "   myval   " in that field, the next
>     time around I send:
> 
>       <form ...><input type=text name=foo value="   myval   ">...</form>
> 
>     since if they entered "   myval   " I assume that's what they meant!

Well, it says that you "should" not, not that you must not.  Just don't
rely on a specific user agent behavior (either trimming or not).

I guess for most normal uses of text INPUT fields leading / trailing
spaces are in practice not significant.  TEXTAREA is different, and
lynx does preserve leading spaces in a TEXTAREA.

Btw. you would not get "   myval   " from user input anyway, at least not
with lynx, it trims trailing spaces *after* line editing so that you would
get "   myval".

   Klaus


reply via email to

[Prev in Thread] Current Thread [Next in Thread]