preg_replace('/([^\s]{25})[^\s]+/', '<span title="$0">$1...</span>', $string);
Tags: php, wordwrap
Name *
Email *
Website
Comment
Add Comment