ACC SHELL

Path : /srv/www/vhosts/unitedsolution/admin/wysiwyg/plugins/tinybrowser/
File Upload :
Current File : /srv/www/vhosts/unitedsolution/admin/wysiwyg/plugins/tinybrowser/tb_tinymce.js.php

<?php
require_once("config_tinybrowser.php");

$tbpath = pathinfo($_SERVER['SCRIPT_NAME']);
$tbmain = $tbpath['dirname'].'/tinybrowser.php';
?>

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

    /* Here goes the URL to your server-side script which manages all file browser things. */
    
    var searchString = window.location.search; // possible parameters
    if (searchString.length < 1) {
        // add "?" to the URL to include parameters (in other words: create a search string because there wasn't one before)
        searchString = "?";
    }
    
    var cmsURL = "<?php echo $tbmain; ?>";    // 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;
    }

    // newer writing style of the TinyMCE developers for tinyMCE.openWindow

    tinyMCE.openWindow({
        file : cmsURL,        
        title : "File Browser",
        width : 420,  // Your dimensions may differ - toy around with them!
        height : 400,
        resizable : "yes",
		scrollbars : "yes",
        close_previous : "no"
    }, {
        window : win,
        input : field_name,
        resizable : "yes",
        scrollbars : "yes",
        inline : "yes",  // This parameter only has an effect if you use the inlinepopups plugin!
        editor_id : tinyMCE.selectedInstance.editorId
    });
    return false;
  }
 

ACC SHELL 2018