Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Hashtags and @Mentions
- $str = preg_replace_callback('~([#@])([^s#@]+)~',
- create_function('$m', '$dir = $m[1] == "#" ? "search/?q=%23" : "./";' .
- 'return "<a href="$dir$m[2]">$m[0]</a>";' ),
- $str );
- /* Link text */
- $str = self :: linkText( $str );
- /* Emoticons */
- $str = self :: emoticons( $str );
- $str = stripslashes( $str );
- //$str = str_replace( '<br />', '<br />', $str );
- //return wordwrap( $str, 60, "rn", TRUE );
- return $str;
- }
- // Hashtags and @Mentions
- $str = preg_replace_callback('~([#@$])([^s#@$]+)~',
- create_function('$m', '$dir = $m[1] == "#" ? "search/?q=%23,%24" : "./";' .
- 'return "<a href="$dir$m[2]">$m[0]</a>";' ),
- $str );
- /* Link text */
- $str = self :: linkText( $str );
- /* Emoticons */
- $str = self :: emoticons( $str );
- $str = stripslashes( $str );
- //$str = str_replace( '<br />', '<br />', $str );
- //return wordwrap( $str, 60, "rn", TRUE );
- return $str;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement