Created
May 23, 2016 18:38
-
-
Save lukasfarina/afe7ed8721156ee23679f0e321f6c6e0 to your computer and use it in GitHub Desktop.
Substring de caractéres não deixando as palavras no meio.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if(preg_match('/^.{1,109}\b/s', $this->content, $match)) | |
return strip_tags($match[0]); | |
else | |
return false; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment