Pomoc - Szukaj - Użytkownicy - Kalendarz
Pełna wersja: TinyMce problem z browserem
Forum PHP.pl > Forum > Po stronie przeglądarki
Wilu88
Witam

Od jakiegoś czasu używam Tinymce dziś postanowiłem doinstalować plugin TinyBrowser, zrobiłem wszystko według instrukcji, ale po kliknięciu na przycisk w oknie dodawania zdjęcia, który powinien wyświetlić menager nic się nie dzieje.

Konsola błędów w FF wywala oto taki komunikat:

tinyMCE.activeEditor is undefinded


Oto fragment kodu, który odpowiada za ładowanie Tiny

Kod
<script language="javascript" type="text/javascript" src="jscripts/tiny_mce/tiny_mce.js"></script>
        <script language="javascript" type="text/javascript" src="jscripts/tiny_mce/plugins/tinybrowser/tb_tinymce.js.php"></script>
    <script language="javascript" type="text/javascript">
    tinyMCE.init({
        theme : "advanced",
    mode : "exact",
    elements : "pole1,pole2",
        plugins : "table,save,advhr,advimage,advlink,emotions,iespell,insertdatetime,preview,zo
om,flash,searchreplace,print,contextmenu,tinyBrowser,advimage",
        theme_advanced_buttons1_add_before : "save,separator",
        theme_advanced_buttons1_add : "fontselect,fontsizeselect",
        theme_advanced_buttons2_add : "separator,insertdate,inserttime,preview,zoom,separator,forecolor,backcolor",
        theme_advanced_buttons2_add_before: "cut,copy,paste,separator,search,replace,separator",
        theme_advanced_buttons3_add_before : "tablecontrols,separator",
        theme_advanced_buttons3_add : "emotions,iespell,flash,advhr,separator,print",
        theme_advanced_toolbar_location : "top",
        theme_advanced_toolbar_align : "left",
        theme_advanced_path_location : "bottom",
        plugin_insertdate_dateFormat : "%Y-%m-%d",
        plugin_insertdate_timeFormat : "%H:%M:%S",
        extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|on
mouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
        external_link_list_url : "example_data/example_link_list.js",
        external_image_list_url : "example_data/example_image_list.js",
        flash_external_list_url : "example_data/example_flash_list.js",
        file_browser_callback : "tinyBrowser"
    });
    </script>


Wiecie może w czym tkwi problem?
erix
A nie używasz przypadkiem jakiejś starej wersji TinyBrowser?
Wilu88
Wersja to 1.41 także raczej nie jest jakaś stara.

Błąd tyczy się niby tego fragmentu:

Kod
function tinyBrowser (field_name, url, type, win) {

    /* If you work with sessions in PHP and your client doesn't accept cookies you might need to carry
       the session name and session ID in the request string (can look like this: "?PHPSESSID=88p0n70s9dsknra96qhuk6etm5").
       These lines of code extract the necessary parameters and add them back to the filebrowser URL again. */

    var cmsURL = "/cms_linuxmag_pro/jscripts/tiny_mce/plugins/tinybrowser/tinybrowser.php";    // script URL - use an absolute path!
    if (cmsURL.indexOf("?") < 0) {
        //add the type as the only query parameter
        cmsURL = cmsURL + "?type=" + type;
    }
    else {
        //add the type as an additional query parameter
        // (PHP session ID is now included if there is one at all)
        cmsURL = cmsURL + "&type=" + type;
    }
  tinyMCE.activeEditor.windowManager.open({
        file : cmsURL,
        title : 'Tiny Browser',
        width : 770,
        height : 480,
        resizable : "yes",
          scrollbars : "yes",
        inline : "yes",  // This parameter only has an effect if you use the inlinepopups plugin!
        close_previous : "no"
    }, {
        window : win,
        input : field_name
    });
    return false;
  }
To jest wersja lo-fi głównej zawartości. Aby zobaczyć pełną wersję z większą zawartością, obrazkami i formatowaniem proszę kliknij tutaj.
Invision Power Board © 2001-2025 Invision Power Services, Inc.