Skip to content

Instantly share code, notes, and snippets.

@ronalfy
Created December 13, 2013 18:13
Show Gist options
  • Save ronalfy/7948618 to your computer and use it in GitHub Desktop.
Save ronalfy/7948618 to your computer and use it in GitHub Desktop.
Tango Smilies Fix for WordPress 3.8
function tango_smilies_fixurl($text) {
$siteurl = get_option('siteurl');
$plugurl = plugin_dir_url(__FILE__);
$search = sprintf( '#<img src="%s/wp-includes/images/smilies/#', $siteurl );
$replace = sprintf( '<img src="%stango/', $plugurl );
return preg_replace( $search, $replace, $text );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment