![]() |
PHP newby has quick and easy question!
I need to know how to verify the amount of characters in an input field.
For example, if an input field value were to be $bbuserinfo[homepage], thus putting the users homepage url in that field, by what code can I find the amount of characters used in the homepage url? I need this for an if-then comparison I am using where a user can insert a URL into a input field or a hexadecimal color. Obviously no URL is going to be smaller than 8 characters, so by easily comparing if the value in the field is greater than 7, I can decipher whether or not that user is inputting a URL or a hexidecimal color (this is needed for a hack of mine). So any idea how I can find out the amount of characters this input field contains, after submition that is? I thought about.. Code:
if($inputfield) > 7) Any help would be nice, Thnx ;) |
You are looking for strlen(). :)
|
All times are GMT. The time now is 11:10 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|