Question

I'm refurbishing a simple web-app that our field techs use. One of my goals is to make it Blackberry-friendly, as all of the techs are now using those. This app accepts basic information about a job and stores it. Among that info are times, telephone numbers, and a street address.

I have the time fields and telephone fields figured out with the following CSS:

     input.time  { -wap-input-format: "NN\\:NN"; }
     input.phone { -wap-input-format: "\\(nnn\\)\\ nnn\\-nnnn" }

What I'm trying to do is determine how I can have the phone default to numeric input on an address field, then go alpha once a space has been inserted. I'm assuming that this can't be done with the -wap-input-format property above.

Is there another way--even if it's only for the Blackberry Browser--to do this without resorting to JavaScript? (Not that there's anything wrong with that :-) )

Thanks.

Was it helpful?

Solution

Have you considered a "Street Number" field followed by a separate "Street Name" field? There is no way to have a variable number of digits at the start of this sort WAP input field without using JavaScript.

OTHER TIPS

I've found that javascript alone is the only way to do a decent job of subtle user input validation. Markup creates more challenges than it solves. With js you can let whatever keystrokes mean whatever you want, customized to any context.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top