jeff5656 Posted July 26, 2009 Share Posted July 26, 2009 I have this: <?php echo nl2br ($row['comments']);?> Let's say I only want to display the first 50 characters and replace the rest with [...] Is there a way to do this? Then if the user wants to read the whole thing they click and the entire thing could be displayed. Thanks! Link to comment https://forums.phpfreaks.com/topic/167494-solved-only-display-certain-amount-of-a-text-variable/ Share on other sites More sharing options...
Coreye Posted July 26, 2009 Share Posted July 26, 2009 I would check out this thread: http://www.phpfreaks.com/forums/index.php?topic=162428. Link to comment https://forums.phpfreaks.com/topic/167494-solved-only-display-certain-amount-of-a-text-variable/#findComment-883209 Share on other sites More sharing options...
jeff5656 Posted July 26, 2009 Author Share Posted July 26, 2009 Thanks. Sorry I guess I should have searched. Link to comment https://forums.phpfreaks.com/topic/167494-solved-only-display-certain-amount-of-a-text-variable/#findComment-883211 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.