Thanks for the input I like the idea of just giving a string for
formatting purpose and then overriding the default behavior with some
other kind of include to specify decimal and grouper.  I'll come up
with something for that.

What's your take on including with the mask plugin?  They might share
some internal methods like character positioning, but that is about
it.  I'm thinking really hard about making them separate files, but
all in the $.fn.mask namespace.

Josh
digitalbush.com


On Oct 20, 9:32 am, Jörn Zaefferer <[EMAIL PROTECTED]> wrote:
> Josh Bush schrieb:> A lot of people seem to need dynamic width number 
> masking.  Where
> > currency symbols, decimal separators, and thousands separators are
> > applied automatically.  I'm thinking about taking this on, but I have
> > a few questions.
>
> > 1.Should is be a part of the masked input plugin or a separate new
> > plugin?
>
> I could imagine expressions specifiying the possible amount of
> characters, similar to regex. Or the number format as used by java,
> where you specify something like "#,###.00", and the seperators are
> replaced according to the locale. The 0 specifices a required
> placeholder, while the "#,###" can repeast (or something like 
> that:http://java.sun.com/j2se/1.4.2/docs/api/java/text/DecimalFormat.html).
>
> > {decimalSeparator:",",thousandsSeparator:"."}  This seems clunky to
> > me.  Is there any good way to read internationalization and
> > globalization stuff from the browser?    My head is swimming with
> > ideas here, I just need some direction.
>
> I'd prefer including a another file for the appropiate locale that
> overwrites the defaults. For example, these date extensions define some
> names:http://dev.jquery.com/view/trunk/plugins/methods/date.js
> If the user locale is "de", I'd also include another file on the
> serverside:http://dev.jquery.com/view/trunk/plugins/methods/date_de.js
>
> Just a few ideas. I'm looking forward to what you come up with :-)
>
> Regards
> Jörn

Reply via email to