alexville Posted April 2, 2009 Share Posted April 2, 2009 Is this possible? Thanks Freaks! Link to comment https://forums.phpfreaks.com/topic/152311-solved-cut-off-first-29-letters-of-a-php-variable/ Share on other sites More sharing options...
Maq Posted April 2, 2009 Share Posted April 2, 2009 Do you mean the variable name or value? I hope you don't have a variable name that long... Link to comment https://forums.phpfreaks.com/topic/152311-solved-cut-off-first-29-letters-of-a-php-variable/#findComment-799888 Share on other sites More sharing options...
alexville Posted April 2, 2009 Author Share Posted April 2, 2009 Do you mean the variable name or value? I hope you don't have a variable name that long... lol no the contents of it Link to comment https://forums.phpfreaks.com/topic/152311-solved-cut-off-first-29-letters-of-a-php-variable/#findComment-799892 Share on other sites More sharing options...
redarrow Posted April 2, 2009 Share Posted April 2, 2009 http://uk2.php.net/substr <?php $word="fnffjjfkjfkdlfjklsfjsdklfjklfjerltjritgjreifjeierjmglmgrktgrtYgrtglkrtgOjytrjgirtjgirtgjgt"; echo " <br>current number letters ".strlen($word).""; $test=strlen(substr($word,29)); echo " <br> number of letters now $test"; echo "<br>result: ".substr($word,29).""; ?> Link to comment https://forums.phpfreaks.com/topic/152311-solved-cut-off-first-29-letters-of-a-php-variable/#findComment-799895 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.