diff --git a/e107_admin/image.php b/e107_admin/image.php index 5caec101f..526918baa 100644 --- a/e107_admin/image.php +++ b/e107_admin/image.php @@ -963,7 +963,7 @@ class media_admin_ui extends e_admin_ui if($this->getQuery('iframe')) { - e107::js('tinymce4','plugins/compat3x/tiny_mce_popup.js'); + // e107::js('tinymce4','plugins/compat3x/tiny_mce_popup.js'); $this->getResponse()->setIframeMod(); // disable header/footer menus etc. if(!$this->getQuery('for')) diff --git a/e107_handlers/bbcode_handler.php b/e107_handlers/bbcode_handler.php index 5333c1f2e..77b1dddec 100644 --- a/e107_handlers/bbcode_handler.php +++ b/e107_handlers/bbcode_handler.php @@ -454,6 +454,10 @@ class e_bbcode { $ret[] = $tp->replaceConstants($i,'full'); } + elseif(strpos($i,'thumb.php')!==false || strpos($i,'media/img/')!==false || strpos($i,'theme/img/')!==false) // absolute path. + { + $ret[] = SITEURLBASE.$i; + } else { $ret[] = $path.$i; diff --git a/e107_handlers/e_parse_class.php b/e107_handlers/e_parse_class.php index 91cd5eb78..ab67ff4f8 100644 --- a/e107_handlers/e_parse_class.php +++ b/e107_handlers/e_parse_class.php @@ -2364,7 +2364,7 @@ class e_parse extends e_parser } - if(e_MOD_REWRITE_MEDIA == true)// Experimental SEF URL support. + if(e_MOD_REWRITE_MEDIA == true && empty($options['nosef']))// Experimental SEF URL support. { $options['full'] = $full; $options['ext'] = substr($url,-3); @@ -2465,8 +2465,15 @@ class e_parse extends e_parser */ private function thumbUrlSEF($url='', $options=array()) { - - $base = (!empty($options['full'])) ? SITEURL : e_HTTP; + if(!empty($options['full'])) + { + $base = SITEURL; + } + else + { + $base = (!empty($options['ebase'])) ? '{e_BASE}' : e_HTTP; + } + // $base = (!empty($options['full'])) ? SITEURL : e_HTTP; if(!empty($options['x']) && !empty($options['ext'])) // base64 encoded. Build URL for: RewriteRule ^media\/img\/([-A-Za-z0-9+/]*={0,3})\.(jpg|gif|png)?$ thumb.php?id=$1 { diff --git a/e107_plugins/tinymce4/e_footer.php b/e107_plugins/tinymce4/e_footer.php index 24499bafd..edc7e60e4 100644 --- a/e107_plugins/tinymce4/e_footer.php +++ b/e107_plugins/tinymce4/e_footer.php @@ -42,7 +42,7 @@ if((e107::wysiwyg() === true && check_class($pref['post_html'])) || strpos(e_SEL } else { - e107::js('tinymce4','plugins/compat3x/tiny_mce_popup.js'); + // e107::js('tinymce4','plugins/compat3x/tiny_mce_popup.js'); // e107::js('tinymce','tiny_mce_popup.js','jquery'); } @@ -150,6 +150,7 @@ if((e107::wysiwyg() === true && check_class($pref['post_html'])) || strpos(e_SEL $('.e-dialog-close').click(function(){ top.tinymce.activeEditor.windowManager.close(); + }); diff --git a/e107_plugins/tinymce4/plugins/e107/dialog.php b/e107_plugins/tinymce4/plugins/e107/dialog.php index c7aef28dd..db8ada74c 100644 --- a/e107_plugins/tinymce4/plugins/e107/dialog.php +++ b/e107_plugins/tinymce4/plugins/e107/dialog.php @@ -26,7 +26,7 @@ e107::css('inline'," "); -e107::js('tinymce4','plugins/compat3x/tiny_mce_popup.js'); +// e107::js('tinymce4','plugins/compat3x/tiny_mce_popup.js'); e107::js('inline'," diff --git a/e107_plugins/tinymce4/plugins/e107/parser.php b/e107_plugins/tinymce4/plugins/e107/parser.php index 36d608660..ec4011164 100644 --- a/e107_plugins/tinymce4/plugins/e107/parser.php +++ b/e107_plugins/tinymce4/plugins/e107/parser.php @@ -189,6 +189,9 @@ TEMPL; if(check_class($pref['post_html'])) // Plain HTML mode. { + + $content = trim($content); + $srch = array('src="'.e_HTTP.'thumb.php?','src="/{e_MEDIA_IMAGE}'); $repl = array('src="{e_BASE}thumb.php?','src="{e_BASE}thumb.php?src=e_MEDIA_IMAGE/'); $content = str_replace($srch, $repl, $content); @@ -261,6 +264,11 @@ TEMPL; ); } + elseif(defined('TINYMCE_DEBUG')) + { + print_a("thumbUrlDecode: No Matches"); + + } return $ret; @@ -280,6 +288,11 @@ TEMPL; $srch = array("?","&"); $repl = array("\?","&"); + if(defined('TINYMCE_DEBUG')) + { + print_a($arr); + } + foreach($arr['img'] as $img) { $regexp = '#(]*src="'.str_replace($srch, $repl, $img['src']).'"[^>]*>)#'; @@ -299,6 +312,7 @@ TEMPL; $qr['h'] = $img['height']; } + $qr['ebase'] = true; $src = e107::getParser()->thumbUrl($qr['src'],$qr); $replacement = ''; diff --git a/e107_plugins/tinymce4/plugins/e107/plugin.js b/e107_plugins/tinymce4/plugins/e107/plugin.js index f7a5efbfa..293675df9 100644 --- a/e107_plugins/tinymce4/plugins/e107/plugin.js +++ b/e107_plugins/tinymce4/plugins/e107/plugin.js @@ -75,8 +75,8 @@ title: 'Media Manager', url: url + '/mediamanager.php?image', width: 1050, - height: 650 - + height: 680, + id: 'media-manager' }); } }); @@ -96,8 +96,8 @@ title: 'Media Manager', url: url + '/mediamanager.php?video', width: 1050, - height: 650 - + height: 650, + id: 'media-manager' }); } }); @@ -112,8 +112,9 @@ title: 'Media Manager', url: url + '/mediamanager.php?glyph', width: 1050, - height: 650 - + height: 650, + id: 'media-manager' + }); } }); diff --git a/e107_plugins/tinymce4/templates/mainadmin.xml b/e107_plugins/tinymce4/templates/mainadmin.xml index 08ca44982..abe454072 100644 --- a/e107_plugins/tinymce4/templates/mainadmin.xml +++ b/e107_plugins/tinymce4/templates/mainadmin.xml @@ -3,8 +3,8 @@ advlist autolink autosave lists link image charmap print preview hr anchor pagebreak searchreplace wordcount visualchars code fullscreen insertdatetime media nonbreaking table contextmenu directionality emoticons template paste textcolor edit view format insert table tools - undo redo | removeformat | styleselect | bold italic underline forecolor | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image template | e107-image e107-video e107-bbcode smileys | preview | fullscreen - e107 compat3x + undo redo | removeformat | styleselect | bold italic underline forecolor | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image template | e107-image e107-video e107-glyph smileys | preview | fullscreen + e107 true i[*], object[*],embed[*],bbcode[*] [ diff --git a/e107_plugins/tinymce4/wysiwyg.php b/e107_plugins/tinymce4/wysiwyg.php index 8edf50e70..f16c2c7be 100644 --- a/e107_plugins/tinymce4/wysiwyg.php +++ b/e107_plugins/tinymce4/wysiwyg.php @@ -343,7 +343,10 @@ class wysiwyg ); - + // if(e_ADMIN_AREA) + { + // $ret['skin_url'] = e_PLUGIN_ABS.'tinymce4/skins/eskin'; + } // Loop thru XML parms. foreach($config as $k=>$xml) @@ -387,11 +390,11 @@ class wysiwyg // plugins: "visualblocks", - +/* $formats = array( 'hilitecolor' => array('inline'=> 'span', 'classes'=> 'hilitecolor', 'styles'=> array('backgroundColor'=> '%value')) // block : 'h1', attributes : {title : "Header"}, styles : {color : red} - ); + );*/ //@see http://www.tinymce.com/wiki.php/Configuration:formats diff --git a/e107_themes/bootstrap3/admin_theme.php b/e107_themes/bootstrap3/admin_theme.php index 9c4186528..8a336aa1f 100644 --- a/e107_themes/bootstrap3/admin_theme.php +++ b/e107_themes/bootstrap3/admin_theme.php @@ -34,20 +34,30 @@ e107::css('theme','admin_dark.css'); e107::css('theme','ie_all.css',null,'all',""); e107::css('inline', " -/* TinyMce */ + .mce-menubar .mce-caret { border-top-color: #C6C6C6!important } .mce-menubar:hover .mce-caret { border-top-color: #FFFFFF!important } -.mce-menubar .mce-btn button { color: #C6C6C6!important; } /* v4.1+ */ -.mce-menubar .mce-btn button span { color: #C6C6C6!important; } /* v4.0 */ +.mce-menubar .mce-btn button { color: #C6C6C6!important; } +.mce-menubar .mce-btn button span { color: #C6C6C6!important; } .mce-menubar .mce-btn button:hover { color: #FFFFFF!important; } -.mce-menubar.mce-toolbar { background-color: #373737!important; } +.mce-menubar.mce-toolbar, .mce-window-head { background-color: #373737; !important } .mce-tinymce[role=application] { border-color: #373737!important; } .mce-menubar .mce-menubtn:hover, .mce-menubtn:active, .mce-menubtn:focus { background-color:transparent!important; color: #FFFFFF!important; border-color:transparent!important; } .mce-menubar .mce-btn.mce-active { color:white!important; border-color:transparent!important; background-color: transparent!important; } + +body.forceColors { margin:0; background-color: #373737; !important} +body.forceColors a { color: white} +body.forceColors li a { color: silver} + +div#media-manager div.mce-window-head { background-color: #373737; !important } +div#media-manager div.mce-title { color:white; } +div#media-manager, html { color: silver; background-color: #373737; !important} + + "); /*