Support » Plugins » mce_thref in tinymce?

  • Resolved nathanielstern


    Have been editing a plugin where I’m trying to use a combo of lightbox and flickrphp – don’t know much about it, but the editing seems to be working… Anyhow, I’m putting links in the title attribute of a lightbox href, and it works great when I’m not using the rich editor, but as soon as I save or switch to visual vs code, all my “href”s turn to “mce_thref”s within that code. Oddly, it does this nowhere else, and stops doing it if i put spaces in my code (but then the link doesn’t work any more!). Any remedies? Or is the rich text editor just completely out if I want to do this….?

    Thanks so much!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Sounds like a TinyMCE bug. TinyMCE has weirdness sometimes with various flavors of Firefox. I’ll bet it works fine in IE.

    Anyway, no certain fix yet. Generally WordPress attempts to fix these issues by upgrading the whole of TinyMCE.

    erg. I’m on a Mac… So should I just upgrade TinyMCE from their site? Given that wordpress is only a week or so old, won’t it have the most recent version of TinyMCE? Thanks again…

    I’m on a Mac…

    Okay, then are you using Firefox or Safari? Whichever it is, try the other one and see if it still happens.

    And yes, WordPress is using one of the latest versions of TinyMCE, but that doesn’t mean that it’s bug-free. No piece of software is bug free.

    Safari works but not with TinyMCE, Firefox not all. SO, i just wrote my first plugin, and it seems to work. here goes, if anybody wants to use it. Just ignore the mce_thref – it’ll get replaced when pulling the content from the database, as long as the plugin is activated. Yay, me.

    Plugin Name: mce-firefox-fix
    Plugin URI:
    Description: Plugin to fix firefox bug in tinymce and phpflickr
    Date: 2007, October, 3
    Author: nathaniel stern
    Author URI:
    Version: 0.1
    Author: nathaniel stern
    function mce_firefox_fix($content) {
        $regex = '/\mce_thref/i';
    	preg_match_all( $regex, $content, $matches );
    	for($x=0; $x<count($matches[0]); $x++)
    			$replace = 'href';
    		$content = str_replace($matches[0][$x], $replace, $content);
    	return $content;
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘mce_thref in tinymce?’ is closed to new replies.