Title: replace_once space error
Last modified: September 12, 2018

---

# replace_once space error

 *  [TES Proje](https://wordpress.org/support/users/tesproje/)
 * (@tesproje)
 * [7 years, 8 months ago](https://wordpress.org/support/topic/replace_once-space-error/)
 * Hi.
    I had a problem with replace_once spacing. the link was stealing 2 extra
   word if i check replace once option. I looked i solved with some changes in code:
 * linkify-text/linkify-text.php:364
    It was like this:
 * `. mb_substr( $text, $pos[0] + $pos[1]-1 );`
 * And this was stealing 2 word from my next word after the link.
    I changed it 
   like this:
 * `. mb_substr( $text, $pos[0] + $pos[1]-3 );`
 * I works well now. I hope you change that soon!

The topic ‘replace_once space error’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/linkify-text_0074a2.svg)
 * [Linkify Text](https://wordpress.org/plugins/linkify-text/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/linkify-text/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/linkify-text/)
 * [Active Topics](https://wordpress.org/support/plugin/linkify-text/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/linkify-text/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/linkify-text/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [TES Proje](https://wordpress.org/support/users/tesproje/)
 * Last activity: [7 years, 8 months ago](https://wordpress.org/support/topic/replace_once-space-error/)
 * Status: not resolved