mirror of
https://github.com/e107inc/e107.git
synced 2025-01-16 12:18:39 +01:00
Fixes #4737 Removal of type="text/javascript" and type="text/css"
This commit is contained in:
parent
21fa07ec3b
commit
025ff07aab
@ -1171,7 +1171,7 @@ function js_location($qry)
|
||||
exit;
|
||||
}
|
||||
|
||||
echo "<script type='text/javascript'>document.location.href='{$qry}'</script>\n";
|
||||
echo "<script>document.location.href='{$qry}'</script>\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
|
10
comment.php
10
comment.php
@ -282,16 +282,16 @@ if ($redirectFlag)
|
||||
header('Location: '.e107::getUrl()->create('news/view/item', 'id='.$redirectFlag));
|
||||
exit;
|
||||
case "poll" :
|
||||
echo "<script type='text/javascript'>document.location.href='".e_HTTP."comment.php?comment.{$table}.{$redirectFlag}'</script>\n";
|
||||
echo "<script>document.location.href='".e_HTTP."comment.php?comment.{$table}.{$redirectFlag}'</script>\n";
|
||||
exit;
|
||||
case "download" :
|
||||
echo "<script type='text/javascript'>document.location.href='".e_HTTP."download.php?view.{$redirectFlag}'</script>\n";
|
||||
echo "<script>document.location.href='".e_HTTP."download.php?view.{$redirectFlag}'</script>\n";
|
||||
exit;
|
||||
case "page" :
|
||||
echo "<script type='text/javascript'>document.location.href='".e_HTTP."page.php?{$redirectFlag}'</script>\n";
|
||||
echo "<script>document.location.href='".e_HTTP."page.php?{$redirectFlag}'</script>\n";
|
||||
exit;
|
||||
case 'user' :
|
||||
echo "<script type='text/javascript'>document.location.href='".e107::getUrl()->create('user/profile/view', 'id='.$redirectFlag)."'</script>\n";
|
||||
echo "<script>document.location.href='".e107::getUrl()->create('user/profile/view', 'id='.$redirectFlag)."'</script>\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
@ -306,7 +306,7 @@ if ($redirectFlag)
|
||||
|
||||
if ($plugin_redir)
|
||||
{
|
||||
echo "<script type='text/javascript'>document.location.href='{$reply_location}'</script>\n";
|
||||
echo "<script>document.location.href='{$reply_location}'</script>\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
|
@ -200,11 +200,11 @@ function headerjs()
|
||||
/*
|
||||
require_once(e_HANDLER.'js_helper.php');
|
||||
$ret = "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
//add required core lan - delete confirm message
|
||||
('".LAN_JSCONFIRM."').addModLan('core', 'delete_confirm');
|
||||
</script>
|
||||
<script type='text/javascript' src='".e_JS."core/admin.js'></script>
|
||||
<script src='".e_JS."core/admin.js'></script>
|
||||
";
|
||||
|
||||
return $ret;*/
|
||||
|
@ -285,7 +285,7 @@ class auth
|
||||
{
|
||||
e107::lan('core', 'login');
|
||||
$text .= e107::getMessage()->render(); // see e107_handlers/login.php L622
|
||||
$text .= "<script type='text/javascript'>
|
||||
$text .= "<script>
|
||||
window.setTimeout(function() {
|
||||
$('.alert').fadeTo(500, 0).slideUp(500, function(){
|
||||
$(this).remove();
|
||||
|
@ -1184,7 +1184,6 @@ class file_inspector {
|
||||
// Core CSS - XXX awaiting for path changes
|
||||
if(!isset($no_core_css) || !$no_core_css)
|
||||
{
|
||||
//echo "<link rel='stylesheet' href='".e_FILE_ABS."e107.css' type='text/css' />\n";
|
||||
$e_js->otherCSS('{e_WEB_CSS}e107.css');
|
||||
}
|
||||
|
||||
@ -1192,19 +1191,16 @@ class file_inspector {
|
||||
if(!deftrue('e_IFRAME') && isset($pref['admincss']) && $pref['admincss'])
|
||||
{
|
||||
$css_file = file_exists(THEME.'admin_'.$pref['admincss']) ? 'admin_'.$pref['admincss'] : $pref['admincss'];
|
||||
//echo "<link rel='stylesheet' href='".$css_file."' type='text/css' />\n";
|
||||
$e_js->themeCSS($css_file);
|
||||
}
|
||||
elseif(isset($pref['themecss']) && $pref['themecss'])
|
||||
{
|
||||
$css_file = file_exists(THEME.'admin_'.$pref['themecss']) ? 'admin_'.$pref['themecss'] : $pref['themecss'];
|
||||
//echo "<link rel='stylesheet' href='".$css_file."' type='text/css' />\n";
|
||||
$e_js->themeCSS($css_file);
|
||||
}
|
||||
else
|
||||
{
|
||||
$css_file = file_exists(THEME.'admin_style.css') ? 'admin_style.css' : 'style.css';
|
||||
//echo "<link rel='stylesheet' href='".$css_file."' type='text/css' />\n";
|
||||
$e_js->themeCSS($css_file);
|
||||
}
|
||||
|
||||
@ -1230,7 +1226,7 @@ class file_inspector {
|
||||
echo "\n<!-- footer_inline_css -->\n";
|
||||
|
||||
$text = "
|
||||
<style type='text/css'>
|
||||
<style>
|
||||
<!--\n";
|
||||
if (vartrue($_POST['regex']))
|
||||
{
|
||||
@ -1358,7 +1354,7 @@ e107::js('footer', '{e_WEB}js/core/front.jquery.js', 'jquery', 1); // Load all d
|
||||
|
||||
$text = e107::getJs()->renderJs('footer', 1, true, true);
|
||||
|
||||
$text .= "<script type='text/javascript'>
|
||||
$text .= "<script>
|
||||
<!--
|
||||
c = new Image(); c = '".SITEURLBASE.e_IMAGE_ABS."fileinspector/contract.png';
|
||||
e = '".SITEURLBASE.e_IMAGE_ABS."fileinspector/expand.png';
|
||||
|
@ -289,7 +289,7 @@ if (isset($footer_js) && is_array($footer_js))
|
||||
$footer_js = array_unique($footer_js);
|
||||
foreach ($footer_js as $fname)
|
||||
{
|
||||
echo "<script type='text/javascript' src='{$fname}'></script>\n";
|
||||
echo "<script src='{$fname}'></script>\n";
|
||||
$js_included[] = $fname;
|
||||
}
|
||||
}
|
||||
|
@ -140,7 +140,6 @@ $e_js = e107::getJs();
|
||||
// Core CSS - XXX awaiting for path changes
|
||||
if(!isset($no_core_css) || !$no_core_css)
|
||||
{
|
||||
//echo "<link rel='stylesheet' href='".e_FILE_ABS."e107.css' type='text/css' />\n";
|
||||
$e_js->otherCSS('{e_WEB_CSS}e107.css');
|
||||
}
|
||||
|
||||
@ -294,7 +293,7 @@ if(!empty($eplug_js))
|
||||
|
||||
foreach($eplug_js as $vjss)
|
||||
{
|
||||
echo "<script type='text/javascript' src='{$vjss}'></script>\n";
|
||||
echo "<script src='{$vjss}'></script>\n";
|
||||
}
|
||||
|
||||
}
|
||||
@ -303,13 +302,12 @@ if(!empty($eplug_js))
|
||||
if(file_exists(THEME . 'theme.js'))
|
||||
{
|
||||
e107::js('theme', 'theme.js', null, 3);
|
||||
// echo "<script type='text/javascript' src='".THEME_ABS."theme.js'></script>\n";
|
||||
}
|
||||
|
||||
|
||||
if(is_readable(e_FILE . 'user.js') && filesize(e_FILE . 'user.js'))
|
||||
{
|
||||
echo "<script type='text/javascript' src='" . e_FILE_ABS . "user.js'></script>\n";
|
||||
echo "<script src='" . e_FILE_ABS . "user.js'></script>\n";
|
||||
}
|
||||
|
||||
|
||||
@ -356,7 +354,7 @@ if(!USER && ($pref['user_tracking'] == "session") && varset($pref['password_CHAP
|
||||
$js_body_onload[] = "expandit('loginmenuchap');";
|
||||
$js_body_onload[] = "expandit('nologinmenuchap');";
|
||||
}
|
||||
echo "<script type='text/javascript' src='" . e_JS . "chap_script.js'></script>\n";
|
||||
echo "<script src='" . e_JS . "chap_script.js'></script>\n";
|
||||
$js_body_onload[] = "getChallenge();";
|
||||
}
|
||||
|
||||
|
@ -2436,7 +2436,7 @@ function sendImmediately($id)
|
||||
//Initiate the Function in the Background.
|
||||
|
||||
$text .= "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
|
||||
//<![CDATA[
|
||||
new Ajax.Updater('mstatus', '".e_SELF."?mode=process&id=".intval($id)."', {
|
||||
@ -2448,7 +2448,7 @@ function sendImmediately($id)
|
||||
|
||||
// Update the Progress in real-time.
|
||||
$text .= "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
//<![CDATA[
|
||||
|
||||
x = new Ajax.PeriodicalUpdater('progress', '".e_SELF."?mode=progress&id=".intval($id)."',
|
||||
@ -2735,7 +2735,7 @@ if(!function_exists('headerjs'))
|
||||
{
|
||||
|
||||
$text = "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
|
||||
|
||||
function bouncedisp(type)
|
||||
|
@ -471,7 +471,7 @@ if(!function_exists('headerjs'))
|
||||
{
|
||||
|
||||
$js = "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
|
||||
function mail_field(val,id)
|
||||
{
|
||||
|
@ -128,7 +128,7 @@ require_once (e_ADMIN."footer.php");
|
||||
function headerjs()
|
||||
{
|
||||
$ret = "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
//Ajax Support
|
||||
var CoreUgflagAjaxPage = function(e_event) {
|
||||
\$('updatesettings').observe('click', function(event) {
|
||||
@ -149,7 +149,7 @@ function headerjs()
|
||||
}
|
||||
|
||||
</script>
|
||||
<script type='text/javascript' src='".e_JS."core/admin.js'></script>
|
||||
<script src='".e_JS."core/admin.js'></script>
|
||||
";
|
||||
|
||||
return $ret;
|
||||
|
@ -429,7 +429,7 @@ class bbcode_shortcodes extends e_shortcode
|
||||
<div id='{$formid}' style='width: 221px; position: absolute; left:340px; top:60px; margin-right:auto; margin-left:auto; display:none; z-index: 1000; onclick=\"expandit('{$formid}')\" >
|
||||
<div style='border:1px solid black; position: absolute; top:30px; width: 221px; '>";
|
||||
|
||||
$text .= "<script type='text/javascript'>
|
||||
$text .= "<script>
|
||||
//<![CDATA[
|
||||
var maxtd = 18;
|
||||
var maxtddiv = -1;
|
||||
|
@ -36,11 +36,11 @@ class sitelinks_alt
|
||||
|
||||
if (file_exists(THEME.$js_file))
|
||||
{
|
||||
$text = "<script type='text/javascript' src='".THEME_ABS.$js_file."'></script>";
|
||||
$text = "<script src='".THEME_ABS.$js_file."'></script>";
|
||||
}
|
||||
else
|
||||
{
|
||||
$text = "<script type='text/javascript' src='".e_JS.$js_file."'></script>";
|
||||
$text = "<script src='".e_JS.$js_file."'></script>";
|
||||
}
|
||||
$text .= "<div class='menuBar' style='width:100%; white-space: nowrap'>";
|
||||
|
||||
|
@ -306,9 +306,10 @@ global $footer_js;
|
||||
if (isset($footer_js) && is_array($footer_js))
|
||||
{
|
||||
$footer_js = array_unique($footer_js);
|
||||
|
||||
foreach ($footer_js as $fname)
|
||||
{
|
||||
echo "<script type='text/javascript' src='{$fname}'></script>\n";
|
||||
echo "<script src='{$fname}'></script>\n";
|
||||
$js_included[] = $fname;
|
||||
}
|
||||
}
|
||||
@ -384,7 +385,8 @@ if (abs($_serverTime - $lastSet) > 120)
|
||||
* Benefit: account for user time corrections and changes in internet delays
|
||||
* Drawback: each update may cause all server times to display a bit different
|
||||
*/
|
||||
echo "<script type='text/javascript'>\n";
|
||||
|
||||
echo "<script>\n";
|
||||
echo " SyncWithServerTime('', '{$_serverPath}', '{$_serverDomain}');\n";
|
||||
//tdOffset disabled as it can't live together with HTTP_IF_NONE_MATCH (page load speed)
|
||||
//echo " SyncWithServerTime('{$_serverTime}', '{$_serverPath}', '{$_serverDomain}');\n";
|
||||
|
@ -107,32 +107,7 @@ $js_body_onload = array(); // Legacy array of code to load with page.
|
||||
//if (stristr($_SERVER["HTTP_ACCEPT"], "application/xhtml+xml"))
|
||||
// header("Content-type: application/xhtml+xml; charset=utf-8", TRUE);
|
||||
//else
|
||||
if(!e107::isCli())
|
||||
{
|
||||
header("Content-type: text/html; charset=utf-8");
|
||||
}
|
||||
// NEW - HTML5 default
|
||||
// TODO - more precise controlo over page header depending on the HTML5 mode
|
||||
if(!defined("XHTML4"))
|
||||
{
|
||||
echo "<!doctype html>\n";
|
||||
$htmlTag = "<html".(defined("TEXTDIRECTION") ? " dir='".TEXTDIRECTION."'" : "").(defined("CORE_LC") ? " lang=\"".CORE_LC."\"" : "").">";
|
||||
echo (defined('HTMLTAG') ? str_replace('THEME_LAYOUT', THEME_LAYOUT, HTMLTAG) : $htmlTag)."\n";
|
||||
echo "<head>
|
||||
<title>".render_title()."</title>
|
||||
<meta charset='utf-8' />\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
echo (defined("STANDARDS_MODE") ? "" : "<?xml version='1.0' encoding='utf-8' "."?".">\n")."<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.1//EN\" \"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd\">\n";
|
||||
echo "<html xmlns='http://www.w3.org/1999/xhtml'".(defined("TEXTDIRECTION") ? " dir='".TEXTDIRECTION."'" : "").(defined("XMLNS") ? " ".XMLNS." " : "").(defined("CORE_LC") ? " xml:lang=\"".CORE_LC."\"" : "").">\n";
|
||||
echo "<head>
|
||||
<title>".render_title()."</title>
|
||||
<meta http-equiv='content-type' content='text/html; charset=utf-8' />
|
||||
<meta http-equiv='content-style-type' content='text/css' />
|
||||
";
|
||||
echo (defined("CORE_LC")) ? "<meta http-equiv='content-language' content='".CORE_LC."' />\n" : "";
|
||||
}
|
||||
|
||||
|
||||
function render_title()
|
||||
{
|
||||
@ -172,10 +147,24 @@ function render_title()
|
||||
|
||||
return implode(' | ', $arr);
|
||||
}
|
||||
//
|
||||
// C: Send start of HTML
|
||||
//
|
||||
|
||||
|
||||
|
||||
|
||||
if(!e107::isCli())
|
||||
{
|
||||
header("Content-type: text/html; charset=utf-8");
|
||||
}
|
||||
|
||||
//
|
||||
// C: Send start of HTML - HTML5 default
|
||||
|
||||
echo "<!doctype html>\n";
|
||||
$htmlTag = "<html".(defined("TEXTDIRECTION") ? " dir='".TEXTDIRECTION."'" : "").(defined("CORE_LC") ? " lang=\"".CORE_LC."\"" : "").">";
|
||||
echo (defined('HTMLTAG') ? str_replace('THEME_LAYOUT', THEME_LAYOUT, HTMLTAG) : $htmlTag)."\n";
|
||||
echo "<head>
|
||||
<title>".render_title()."</title>
|
||||
<meta charset='utf-8' />\n";
|
||||
if(!empty($pref['meta_copyright'][e_LANGUAGE])) e107::meta('dcterms.rights',$pref['meta_copyright'][e_LANGUAGE]);
|
||||
if(!empty($pref['meta_author'][e_LANGUAGE])) e107::meta('author',$pref['meta_author'][e_LANGUAGE]);
|
||||
if(!empty($pref['sitebutton']))
|
||||
@ -435,12 +424,12 @@ if (isset($eplug_js) && $eplug_js)
|
||||
$eplug_js_unique = array_unique($eplug_js);
|
||||
foreach($eplug_js_unique as $kjs)
|
||||
{
|
||||
echo ($kjs[0] == "<") ? $kjs : "<script type='text/javascript' src='{$kjs}'></script>\n";
|
||||
echo ($kjs[0] == "<") ? $kjs : "<script type='text/javascript' src='{$kjs}'></script>\n"; // could be a .php file so leave the 'type'.
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
echo "<script type='text/javascript' src='{$eplug_js}'></script>\n";
|
||||
echo "<script type='text/javascript' src='{$eplug_js}'></script>\n"; // could be a .php file so leave the 'type'.
|
||||
}
|
||||
}
|
||||
|
||||
@ -448,12 +437,12 @@ if (isset($eplug_js) && $eplug_js)
|
||||
//DEPRECATE this as well?
|
||||
if (isset($theme_js_php) && $theme_js_php)
|
||||
{
|
||||
echo "<script type='text/javascript' src='".THEME_ABS."theme-js.php'></script>\n";
|
||||
echo "<script type='text/javascript' src='".THEME_ABS."theme-js.php'></script>\n"; // .php file so leave the 'type'.
|
||||
}
|
||||
else
|
||||
{
|
||||
if (file_exists(THEME.'theme.js')) { echo "<script type='text/javascript' src='".THEME_ABS."theme.js'></script>\n"; }
|
||||
if (is_readable(e_FILE.'user.js') && filesize(e_FILE.'user.js')) { echo "<script type='text/javascript' src='".e_FILE_ABS."user.js'></script>\n"; }
|
||||
if (file_exists(THEME.'theme.js')) { echo "<script src='".THEME_ABS."theme.js'></script>\n"; }
|
||||
if (is_readable(e_FILE.'user.js') && filesize(e_FILE.'user.js')) { echo "<script src='".e_FILE_ABS."user.js'></script>\n"; }
|
||||
if (file_exists(THEME.'theme.vbs')) { echo "<script type='text/vbscript' src='".THEME_ABS."theme.vbs'></script>\n"; }
|
||||
if (is_readable(e_FILE.'user.vbs') && filesize(e_FILE.'user.vbs')) { echo "<script type='text/vbscript' src='".e_FILE_ABS."user.vbs'></script>\n"; }
|
||||
}
|
||||
@ -468,7 +457,7 @@ if (!USER && ($pref['user_tracking'] == "session") && varset($pref['password_CHA
|
||||
$js_body_onload[] = "expandit('loginmenuchap');";
|
||||
$js_body_onload[] = "expandit('nologinmenuchap');";
|
||||
}
|
||||
echo "<script type='text/javascript' src='".e_JS."chap_script.js'></script>\n";
|
||||
echo "<script src='".e_JS."chap_script.js'></script>\n";
|
||||
$js_body_onload[] = "getChallenge();";
|
||||
}
|
||||
|
||||
|
@ -34,7 +34,7 @@ if(!isset($SITEDOWN_TABLE))
|
||||
<link rel="stylesheet" href="{SITEDOWN_E107_CSS}" type="text/css" media="all" />
|
||||
<link rel="stylesheet" href="{SITEDOWN_THEME_CSS}" type="text/css" media="all" />
|
||||
<title>{SITEDOWN_TABLE_PAGENAME}</title>
|
||||
<style type="text/css">
|
||||
<style>
|
||||
.img-responsive { display: inline }
|
||||
</style>
|
||||
</head>
|
||||
|
@ -1505,7 +1505,7 @@ function check_tables($what)
|
||||
{
|
||||
//very tired and sick of this page, so quick and dirty
|
||||
$text .= "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
\$('core-db-verify-{$what}-legend').hide();
|
||||
</script>
|
||||
";
|
||||
|
@ -744,11 +744,11 @@ class e_jsmanager
|
||||
break;
|
||||
|
||||
case 'admin':
|
||||
return ($this->isInAdmin()) ? false : true;
|
||||
return !$this->isInAdmin();
|
||||
break;
|
||||
|
||||
case 'front':
|
||||
return ($this->isInAdmin()) ? true : false;
|
||||
return $this->isInAdmin();
|
||||
break;
|
||||
|
||||
case 'none':
|
||||
@ -1455,7 +1455,7 @@ class e_jsmanager
|
||||
$path = $tp->replaceConstants($path, 'abs').'?external=1'; // &'.$this->getCacheId();
|
||||
$path = $this->url($path);
|
||||
}
|
||||
|
||||
|
||||
echo $pre.'<link rel="stylesheet" media="'.$media.'" type="text/css" href="'.$path.'" />'.$post;
|
||||
echo "\n";
|
||||
// $this->cacheList['css'][] = $path;
|
||||
@ -1474,7 +1474,8 @@ class e_jsmanager
|
||||
|
||||
$path = $tp->replaceConstants($path, 'abs').'?external=1'; // &'.$this->getCacheId();
|
||||
$path = $this->url($path);
|
||||
echo $pre.'<script type="text/javascript" src="'.$path.'"></script>'.$post;
|
||||
|
||||
echo $pre.'<script src="'.$path.'"></script>'.$post;
|
||||
echo "\n";
|
||||
continue;
|
||||
}
|
||||
@ -1533,7 +1534,6 @@ class e_jsmanager
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
echo $pre.'<link '.$insertID.' rel="stylesheet" media="'.$media.'" property="stylesheet" type="text/css" href="'.$path.'" />'.$post;
|
||||
echo "\n";
|
||||
|
||||
@ -1575,7 +1575,7 @@ class e_jsmanager
|
||||
continue;
|
||||
}
|
||||
|
||||
echo $pre.'<script type="text/javascript" src="'.$path.'"'.$inline.'></script>'.$post;
|
||||
echo $pre.'<script src="'.$path.'"'.$inline.'></script>'.$post;
|
||||
echo "\n";
|
||||
continue;
|
||||
}
|
||||
@ -1750,7 +1750,7 @@ class e_jsmanager
|
||||
|
||||
if($type == 'js')
|
||||
{
|
||||
echo "<script type='text/javascript' src='".$this->url(e_WEB_ABS."cache/".$fileName,'js',false)."'></script>\n\n";
|
||||
echo "<script src='".$this->url(e_WEB_ABS."cache/".$fileName,'js',false)."'></script>\n\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -1968,7 +1968,7 @@ class e_jsmanager
|
||||
{
|
||||
echo "<!-- [JSManager] ".$label." -->\n";
|
||||
}
|
||||
echo '<script type="text/javascript">';
|
||||
echo '<script>';
|
||||
echo "\n//<![CDATA[\n";
|
||||
echo implode("\n\n", $content_array);
|
||||
echo "\n//]]>\n";
|
||||
@ -1992,7 +1992,8 @@ class e_jsmanager
|
||||
{
|
||||
$text .= "<!-- [CSSManager] ".$label." -->\n";
|
||||
}
|
||||
$text .= '<style rel="stylesheet" type="text/css" property="stylesheet">';
|
||||
|
||||
$text .= '<style rel="stylesheet" property="stylesheet">';
|
||||
$text .= implode("\n\n", $content_array);
|
||||
$text .= '</style>';
|
||||
$text .= "\n";
|
||||
|
@ -32,7 +32,7 @@ class e_jslib
|
||||
|
||||
/* DEPRECATED
|
||||
$ret .= "
|
||||
<script type=\"text/javascript\">
|
||||
<script>
|
||||
var e107Path = {
|
||||
e_IMAGE: '".e_IMAGE_ABS."',
|
||||
SITEURL: '".SITEURL."',
|
||||
@ -63,7 +63,7 @@ class e_jslib
|
||||
$hash = md5(serialize(varset($pref['e_jslib'])).e107::getPref('e_jslib_browser_cache', 0).THEME.e_LANGUAGE.ADMIN).'_'.$where;
|
||||
// TODO disable cache in debug mod
|
||||
$hash .= (e107::getPref('e_jslib_nocache')/* || deftrue('e_NOCACHE')*/ ? '_nocache' : '').(!e107::getPref('e_jslib_nobcache') || deftrue('e_NOCACHE') ? '_nobcache' : '').(e107::getPref('e_jslib_gzip') ? '' : '_nogzip');
|
||||
$ret .= "<script type='text/javascript' src='".e_JS."e_jslib.php?{$hash}'></script>\n";
|
||||
$ret .= "<script src='".e_JS."e_jslib.php?{$hash}'></script>\n";
|
||||
|
||||
// render CDN libraries asap
|
||||
$ret .= $e_jsmanager->renderJs('core', null, true, true);
|
||||
|
@ -320,12 +320,6 @@ class e_menuManager
|
||||
*/
|
||||
header("Location: ".$newurl);
|
||||
exit;
|
||||
// echo "URL = ".$newurl;
|
||||
// $newurl = $PLUGINS_DIRECTORY.$location."/{$position}{$this->menuNewLoc}.php";
|
||||
// $newurl = SITEURL.str_replace("//", "/", $newurl);
|
||||
// echo "<script type='text/javascript'>alert($newurl); top.location.href = '{$newurl}'; </script> ";
|
||||
// exit;
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
@ -1152,11 +1152,11 @@ $SYSTEM_DIRECTORY = "e107_system/";</pre>
|
||||
|
||||
case "ALERT":
|
||||
$message = isset($emessage[$message]) ? $emessage[$message] : $message;
|
||||
echo "<noscript>$message</noscript><script type='text/javascript'>alert(".$tp->toJSON($message)."); window.history.go(-1); </script>\n"; exit;
|
||||
echo "<noscript>$message</noscript><script>alert(".$tp->toJSON($message)."); window.history.go(-1); </script>\n"; exit;
|
||||
break;
|
||||
|
||||
case "P_ALERT":
|
||||
echo "<script type='text/javascript'>alert(".$tp->toJSON($message)."); </script>\n";
|
||||
echo "<script>alert(".$tp->toJSON($message)."); </script>\n";
|
||||
break;
|
||||
|
||||
case 'POPUP':
|
||||
@ -1164,7 +1164,7 @@ $SYSTEM_DIRECTORY = "e107_system/";</pre>
|
||||
$mtext = "<html><head><title>Message</title><link rel=stylesheet href=" . THEME . "style.css></head><body style=padding-left:2px;padding-right:2px;padding:2px;padding-bottom:2px;margin:0px;align;center marginheight=0 marginleft=0 topmargin=0 leftmargin=0><table width=100% align=center style=width:100%;height:99%padding-bottom:2px class=bodytable height=99% ><tr><td width=100% style='text-align:center'><b>--- Message ---</b><br /><br />".$message."<br /><br /><form><input class=button type=submit onclick=self.close() value = ok /></form></td></tr></table></body></html> ";
|
||||
|
||||
echo "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
winl=(screen.width-200)/2;
|
||||
wint = (screen.height-100)/2;
|
||||
winProp = 'width=200,height=100,left='+winl+',top='+wint+',scrollbars=no';
|
||||
|
@ -154,7 +154,7 @@ function Color_Select($formid='col_selector') {
|
||||
<div style='width: 221px; position: absolute; left:340px; top:60px; margin-right:auto; margin-left:auto; display:none; z-index: 1000; id='{$formid}' onclick=\"expandit(this)\" >
|
||||
<div style='border:1px solid black; position: absolute; top:30px; width: 221px; '>";
|
||||
|
||||
$text .= "<script type='text/javascript'>
|
||||
$text .= "<script>
|
||||
//<![CDATA[
|
||||
var maxtd = 18;
|
||||
var maxtddiv = -1;
|
||||
|
@ -3035,7 +3035,7 @@ class themeHandler
|
||||
|
||||
function themePreview()
|
||||
{
|
||||
echo "<script type='text/javascript'>document.location.href='".e_BASE."index.php?themepreview.".$this->id."'</script>\n";
|
||||
echo "<script>document.location.href='".e_BASE."index.php?themepreview.".$this->id."'</script>\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
|
@ -135,7 +135,7 @@ class user_select
|
||||
{
|
||||
global $tp;
|
||||
if ($oldClass !== FALSE) $class = $oldClass; // Handle legacy position of $class
|
||||
$text = "<script type='text/javascript'>
|
||||
$text = "<script>
|
||||
<!--
|
||||
function uc_switch(uctype) {
|
||||
document.getElementById(uctype).value = '';
|
||||
@ -229,7 +229,7 @@ class user_select
|
||||
|
||||
echo "<link rel=stylesheet href='".e_WEB_ABS."js/bootstrap/css/bootstrap.min.css'>
|
||||
<link rel=stylesheet href='".THEME_ABS."style.css'>
|
||||
<script language='JavaScript' type='text/javascript'>
|
||||
<script>
|
||||
<!--
|
||||
function SelectUser() {
|
||||
var d = window.document.results.usersel.value;
|
||||
|
@ -622,7 +622,7 @@ e107::css('inline',"
|
||||
|
||||
/*
|
||||
echo "
|
||||
<script type=\"text/javascript\">
|
||||
<script>
|
||||
function addtext1(sc){
|
||||
document.getElementById('wmform').guestrules.value += sc;
|
||||
}
|
||||
|
@ -1150,7 +1150,7 @@ class forum_post_handler
|
||||
{
|
||||
if ($fp->flood('forum_thread', 'thread_datestamp') == false && !ADMIN)
|
||||
{
|
||||
echo "<script type='text/javascript'>document.location.href='".e_BASE."index.php'</script>\n";
|
||||
echo "<script>document.location.href='".e_BASE."index.php'</script>\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
|
@ -457,7 +457,7 @@ function init()
|
||||
echo $forum_view_start . $forum_view_forum . $forum_view_end;
|
||||
}
|
||||
|
||||
echo "<script type=\"text/javascript\">
|
||||
echo "<script>
|
||||
function confirm_(thread_id)
|
||||
{
|
||||
return confirm(" . $tp->toJSON(LAN_JSCONFIRM) . ");
|
||||
|
@ -393,7 +393,7 @@ else
|
||||
|
||||
// end -------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
echo "<script type=\"text/javascript\">
|
||||
echo "<script>
|
||||
function confirm_(mode, forum_id, thread_id, thread) {
|
||||
if (mode == 'Thread') {
|
||||
return confirm(" . $tp->toJSON(LAN_FORUM_2009) . ");
|
||||
|
@ -1082,7 +1082,7 @@ class plugin_forum_view_shortcodes extends e_shortcode
|
||||
<span id='forum-track-trigger-container'>
|
||||
<a class='btn btn-default btn-sm btn-small e-ajax' data-target='forum-track-trigger' href='{$url}' id='forum-track-trigger'>{$img}</a>
|
||||
</span>
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
e107.runOnLoad(function(){
|
||||
$('forum-track-trigger').observe('click', function(e) {
|
||||
e.stop();
|
||||
|
@ -173,7 +173,7 @@ $GALLERY_TEMPLATE['prettyphoto']['social_item'] = '
|
||||
<div class="pp_social">
|
||||
<div class="twitter">
|
||||
<a href="http://twitter.com/share" class="twitter-share-button" data-count="none">' . LAN_SHARE . '</a>
|
||||
<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
|
||||
<script src="http://platform.twitter.com/widgets.js"></script>
|
||||
</div>
|
||||
<div class="facebook">
|
||||
<iframe src="http://www.facebook.com/plugins/like.php?locale=en_US&href=\'+location.href+\'&layout=button_count&show_faces=true&width=500&action=like&font&colorscheme=light&height=23" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:500px; height:23px;" allowTransparency="true"></iframe>
|
||||
|
@ -607,7 +607,7 @@ class import_main_ui extends e_admin_ui
|
||||
// $temp = '';
|
||||
// if(varset($import_source)) { $temp .= "disp('{$import_source}');"; }
|
||||
// if (varset($current_db_type)) $temp .= " flagbits('{$current_db_type}');";
|
||||
// if (varset($temp)) $text .= "<script type=\"text/javascript\"> {$temp}</script>";
|
||||
// if (varset($temp)) $text .= "<script> {$temp}</script>";
|
||||
|
||||
$this->addTitle($importType);
|
||||
echo $mes->render().$text;
|
||||
@ -1358,7 +1358,7 @@ function headerjs()
|
||||
}
|
||||
|
||||
$text = "
|
||||
<script type='text/javascript'>{$vals}{$texts}{$blocks}{$comments}
|
||||
<script>{$vals}{$texts}{$blocks}{$comments}
|
||||
function disp(type)
|
||||
{
|
||||
if(type == 'csv')
|
||||
|
@ -528,7 +528,7 @@ e107::getLanguage()->bcDefs($bcDefs);
|
||||
if($parm == "popup"){
|
||||
$srch = array("<br />","'");
|
||||
$rep = array("\\n","\'");
|
||||
return "<script type='text/javascript'>
|
||||
return "<script>
|
||||
alert(".$tp->toJSON(LOGINMESSAGE).");
|
||||
</script>";
|
||||
}
|
||||
|
@ -59,7 +59,7 @@ if(!function_exists('pm_show_popup'))
|
||||
$popuptext = str_replace("\n", '', $popuptext);
|
||||
$popuptext = str_replace("\t", '', $popuptext);
|
||||
$text = "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
winl=(screen.width-200)/2;
|
||||
wint = (screen.height-100)/2;
|
||||
winProp = 'width=200,height=100,left='+winl+',top='+wint+',scrollbars=no';
|
||||
|
@ -305,7 +305,7 @@ class poll
|
||||
$poll_ip = varset($poll_ip) . varset($userid);
|
||||
$sql->update("polls", "poll_votes = '$votep'".($pollArray['poll_storage_method'] != POLL_MODE_COOKIE ? ", poll_ip='".$poll_ip."^'" : '')." WHERE poll_id=".varset($poll_id));
|
||||
/*echo "
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
<!--
|
||||
setcook({$poll_id});
|
||||
//-->
|
||||
|
@ -813,7 +813,7 @@ class social_ui extends e_admin_ui
|
||||
private function generateAdminFormJs()
|
||||
{
|
||||
return <<<EOD
|
||||
<script type='text/javascript'>
|
||||
<script>
|
||||
var e107 = e107 || {'settings': {}, 'behaviors': {}};
|
||||
|
||||
let socialLoginSwitches = {
|
||||
|
@ -125,7 +125,7 @@ require_once(e_ADMIN."footer.php");
|
||||
/*
|
||||
function headerjs()
|
||||
{
|
||||
return "<script type='text/javascript' src='".e_FILE_ABS."jslib/core/admin.js'></script>";
|
||||
return "<script src='".e_FILE_ABS."jslib/core/admin.js'></script>";
|
||||
|
||||
|
||||
}
|
||||
|
@ -208,15 +208,15 @@
|
||||
// Test loaded files.
|
||||
|
||||
$result = $this->js->renderJs('header', 1, true, true);
|
||||
$this->assertStringContainsString('<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>', $result);
|
||||
$this->assertStringContainsString('<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>', $result);
|
||||
$this->assertStringContainsString('zone #1', $result);
|
||||
|
||||
$result = $this->js->renderJs('header', 3, true, true);
|
||||
$this->assertStringContainsString('<script type="text/javascript" src="https://somewhere/something.min.js" defer></script>', $result);
|
||||
$this->assertStringContainsString('<script src="https://somewhere/something.min.js" defer></script>', $result);
|
||||
$this->assertStringContainsString('zone #3', $result);
|
||||
|
||||
$result = $this->js->renderJs('header', 4, true, true);
|
||||
$this->assertStringContainsString('<script type="text/javascript" src="https://somewhere/async.js" defer async></script>', $result);
|
||||
$this->assertStringContainsString('<script src="https://somewhere/async.js" defer async></script>', $result);
|
||||
$this->assertStringContainsString('zone #4', $result);
|
||||
|
||||
}
|
||||
@ -263,15 +263,15 @@
|
||||
// Test loaded files.
|
||||
|
||||
$result = $this->js->renderJs('footer', 1, true, true);
|
||||
$this->assertStringContainsString('<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>', $result);
|
||||
$this->assertStringContainsString('<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>', $result);
|
||||
$this->assertStringContainsString('priority #1', $result);
|
||||
|
||||
$result = $this->js->renderJs('footer', 3, true, true);
|
||||
$this->assertStringContainsString('<script type="text/javascript" src="https://somewhere/something.min.js" defer></script>', $result);
|
||||
$this->assertStringContainsString('<script src="https://somewhere/something.min.js" defer></script>', $result);
|
||||
$this->assertStringContainsString('priority #3', $result);
|
||||
|
||||
$result = $this->js->renderJs('footer', 4, true, true);
|
||||
$this->assertStringContainsString('<script type="text/javascript" src="https://somewhere/async.js" defer async></script>', $result);
|
||||
$this->assertStringContainsString('<script src="https://somewhere/async.js" defer async></script>', $result);
|
||||
$this->assertStringContainsString('priority #4', $result);
|
||||
|
||||
}
|
||||
|
@ -173,7 +173,7 @@ $GALLERY_TEMPLATE['prettyphoto']['social_item'] = '
|
||||
<div class="pp_social">
|
||||
<div class="twitter">
|
||||
<a href="http://twitter.com/share" class="twitter-share-button" data-count="none">' . LAN_SHARE . '</a>
|
||||
<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
|
||||
<script src="http://platform.twitter.com/widgets.js"></script>
|
||||
</div>
|
||||
<div class="facebook">
|
||||
<iframe src="http://www.facebook.com/plugins/like.php?locale=en_US&href=\'+location.href+\'&layout=button_count&show_faces=true&width=500&action=like&font&colorscheme=light&height=23" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:500px; height:23px;" allowTransparency="true"></iframe>
|
||||
|
@ -2404,7 +2404,7 @@ function template_data()
|
||||
<link href="'.e_THEME.'bootstrap3/css/bootstrap-dark.min.css" rel="stylesheet">
|
||||
<link href="'.e_THEME.'bootstrap3/admin_style.css" rel="stylesheet">
|
||||
<link rel="icon" href="favicon.ico" type="image/x-icon" />
|
||||
<style type="text/css">
|
||||
<style>
|
||||
|
||||
body { padding-top: 40px; padding-bottom: 40px; background-color: #181818; }
|
||||
.container-narrow { margin: 0 auto; max-width: 800px; }
|
||||
@ -2475,10 +2475,10 @@ function template_data()
|
||||
<!-- The javascript
|
||||
================================================== -->
|
||||
<!-- Placed at the end of the document so the pages load faster -->
|
||||
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
|
||||
<script src="https://netdna.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js" type="text/javascript"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
|
||||
<script src="https://netdna.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
|
||||
|
||||
<script type="text/javascript">
|
||||
<script>
|
||||
|
||||
$(document).ready(function()
|
||||
{
|
||||
|
@ -674,7 +674,7 @@ function req($field)
|
||||
function headerjs()
|
||||
{
|
||||
return "
|
||||
<script type=\"text/javascript\">
|
||||
<script>
|
||||
function addtext3(sc){
|
||||
document.getElementById('signupform').image.value = sc;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user