[whatwg] Something for the end-user?? -errata

Dean Edwards wrote:

> this should read:
>
> <input type="number" name="cost" format="$%02.2d"/>
> <input type="number" name="amount" format="%d"/> // :-)
> <output type="number" name="total" format="$%02.2d"/>
>
> dah.
>
> -dean


What happens if the user's currency format has a suffixed currency 
symbol, or if the locale-aware way to represent currency values isn't 'a 
decimal point followed by two decimal places'?

If we're going to do this at all, wouldn't we want named formats, like 
'format="currency"' or 'format="short date"'?

(to briefly respond to an earlier point: I don't know what you mean when 
you say that "javascript/ecmascript only respects US/english style 
numbers". There's a Number.toLocaleString() which would seem to be 
exactly what you're talking about.

Regards,
Malcolm

Received on Saturday, 19 June 2004 02:34:39 UTC