From f7524dfd14b58487d3d7765c0ce68788aea80796 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Wed, 25 Jun 2008 16:55:16 +0000 Subject: [PATCH] SSL touchups for tiny_mce_config. fixes #6759 git-svn-id: https://develop.svn.wordpress.org/trunk@8193 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/js/tinymce/tiny_mce_config.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/wp-includes/js/tinymce/tiny_mce_config.php b/wp-includes/js/tinymce/tiny_mce_config.php index 7b1757d691..1e758dcd25 100644 --- a/wp-includes/js/tinymce/tiny_mce_config.php +++ b/wp-includes/js/tinymce/tiny_mce_config.php @@ -51,14 +51,10 @@ function putFileContents( $path, $content ) { } // Set up init variables -$https = ( isset($_SERVER['HTTPS']) && 'on' == strtolower($_SERVER['HTTPS']) ) ? true : false; - -$baseurl = get_option('siteurl') . '/wp-includes/js/tinymce'; -if ( $https ) $baseurl = str_replace('http://', 'https://', $baseurl); +$baseurl = includes_url('js/tinymce'); $mce_css = $baseurl . '/wordpress.css'; $mce_css = apply_filters('mce_css', $mce_css); -if ( $https ) $mce_css = str_replace('http://', 'https://', $mce_css); $mce_locale = ( '' == get_locale() ) ? 'en' : strtolower( substr(get_locale(), 0, 2) ); // only ISO 639-1 @@ -109,7 +105,7 @@ if ( ! empty($mce_external_plugins) ) { foreach ( $mce_external_plugins as $name => $url ) { - if ( $https ) $url = str_replace('http://', 'https://', $url); + if ( is_ssl() ) $url = str_replace('http://', 'https://', $url); $plugins[] = '-' . $name;