![]() |
php question
How do you trim a variable's value to allways display a certain amount of characters, no matter how long the original varialbe may be?
Example: $var1 = "123456789"; I need to only display the first 6 characters "123456"; basically hidding 789 |
echo substr($var1,0,6);
?? |
Thanks! I owe you a beer!
|
next time try google, seriously you can find anything you want to know regarding php on there. I must use it a million times a day :)
|
| All times are GMT -7. The time now is 02:24 PM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2026, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123