Hi,
How can i make sure a value sent from a form has no spaces in it?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
At 17:16 2-4-03, you wrote:
Hi,
How can i make sure a value sent from a form has no spaces in it?
Before sending: javascript that prevents this on sending or even while
typing. Check the javascript form faqs on www.irt.org for this.
After sending:
Detect spaces with
if (!(strpos(' ',
if(strpos($string, ' ') === false) {
//space found
}
if you don't want any white character:
if(ereg('\s',$string)) {
//white character found
}
shaun wrote:
Hi,
How can i make sure a value sent from a form has no spaces in it?
--
PHP General Mailing List
3 matches
Mail list logo