How to truncate a PHP variable?

Brian

New member
Hi, I can't seem to find it its possible but can I truncate a variable in PHP to a specific character length. I have a menu system that is set up to read the URL then alter the link for the current page to be the rollover color, not underlined and no link. This works for well for everthing except the blog which I would like any part of the blog the user is on for it to have truncate the URL down to just domain.com/blog/ instead of domain.com/blog/bipitybooo-page
 
Back
Top