View Single Post
Old 08-21-2006, 10:55 PM  
sevent
Confirmed User
 
sevent's Avatar
 
Join Date: Jun 2006
Location: Toronto
Posts: 104
Sure.

To find out the length of a string use the strlen() function.

To pad on extra characters or remove some use substr

Info about each of these at php.net. You can also treat a string like an array of characters using []. ie. $string[23] = "d";

Quote:
Originally Posted by vanderweb
can php make it so the text that is printed on a page can all be a certain length: like 20 characters or something? what is the code?
sevent is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote