• Please change line 175 of n9m-font-awesome-4.php in the replace_item function from:

    preg_match( '/(<a.+>)(.+)(<\/a>)/i', $item_output, $matches );

    to:

    preg_match( '/(<a[^>]*>)(.+)(<\/a>)/i', $item_output, $matches );

    It’s causing mistakes in when there are other tags inside the <a>.

    • This topic was modified 8 years, 4 months ago by jpsantos.
Viewing 1 replies (of 1 total)
  • I would like to second @jpsantos ‘s request please.

    ( although alternatively, you can just make the regex sub-pattern ‘ungreedy’ like so:

    preg_match( ‘/(<a.+?>)(.+)(<\/a>)/i’, $item_output, $matches );

    – same effect, same reason )

    Many thanks.

Viewing 1 replies (of 1 total)
  • The topic ‘Please update the REGEX for text substitution to this…’ is closed to new replies.