Remove type= from script tags
This commit is contained in:
parent
fadadc992f
commit
c407a19563
@ -40,7 +40,7 @@ $langs->load("modulebuilder");
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<!-- BEGIN PHP TEMPLATE admin_extrafields_add.tpl.php -->
|
<!-- BEGIN PHP TEMPLATE admin_extrafields_add.tpl.php -->
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
jQuery(document).ready(function() {
|
jQuery(document).ready(function() {
|
||||||
function init_typeoffields(type)
|
function init_typeoffields(type)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -39,7 +39,7 @@ $langs->load("modulebuilder");
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<!-- BEGIN PHP TEMPLATE admin_extrafields_edit.tpl.php -->
|
<!-- BEGIN PHP TEMPLATE admin_extrafields_edit.tpl.php -->
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
jQuery(document).ready(function() {
|
jQuery(document).ready(function() {
|
||||||
function init_typeoffields(type)
|
function init_typeoffields(type)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -19,7 +19,7 @@ if (!empty($conf->categorie->enabled) && $user->rights->categorie->lire) {
|
|||||||
require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php';
|
||||||
}
|
}
|
||||||
|
|
||||||
print '<script type="text/javascript" language="javascript">
|
print '<script>
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
|
||||||
// Click Function
|
// Click Function
|
||||||
|
|||||||
@ -25,7 +25,7 @@ if (empty($conf) || !is_object($conf))
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<!-- START TEMPLATE FILE UPLOAD MAIN -->
|
<!-- START TEMPLATE FILE UPLOAD MAIN -->
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
window.locale = {
|
window.locale = {
|
||||||
"fileupload": {
|
"fileupload": {
|
||||||
"errors": {
|
"errors": {
|
||||||
|
|||||||
@ -31,7 +31,7 @@ if ($object->element == 'propal')
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<!-- START TEMPLATE IMPORT OBJECT LINKED LINES -->
|
<!-- START TEMPLATE IMPORT OBJECT LINKED LINES -->
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
|
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
$('.objectlinked_importbtn').click(function (e) {
|
$('.objectlinked_importbtn').click(function (e) {
|
||||||
|
|||||||
@ -32,7 +32,7 @@ if (isset($object->extraparams[$blocname]['showhide'])) $hide = (empty($object->
|
|||||||
<!-- BEGIN PHP TEMPLATE bloc_showhide.tpl.php -->
|
<!-- BEGIN PHP TEMPLATE bloc_showhide.tpl.php -->
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
print '<script type="text/javascript">'."\n";
|
print '<script>'."\n";
|
||||||
print '$(document).ready(function() {'."\n";
|
print '$(document).ready(function() {'."\n";
|
||||||
print '$("#hide-'.$blocname.'").click(function(){'."\n";
|
print '$("#hide-'.$blocname.'").click(function(){'."\n";
|
||||||
print ' setShowHide(0);'."\n";
|
print ' setShowHide(0);'."\n";
|
||||||
|
|||||||
@ -207,7 +207,7 @@ if (empty($reshook) && is_array($extrafields->attributes[$object->table_element]
|
|||||||
{
|
{
|
||||||
print "\n";
|
print "\n";
|
||||||
print '
|
print '
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
jQuery(document).ready(function() {
|
jQuery(document).ready(function() {
|
||||||
function showOptions(child_list, parent_list)
|
function showOptions(child_list, parent_list)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -101,7 +101,7 @@ if ((!empty($conf->use_javascript_ajax) && empty($conf->global->MAIN_ECM_DISABLE
|
|||||||
if ((empty($section) || $section == -1) && ($module != 'medias'))
|
if ((empty($section) || $section == -1) && ($module != 'medias'))
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
jQuery(document).ready(function() {
|
jQuery(document).ready(function() {
|
||||||
jQuery('#<?php echo $nameforformuserfile ?>').hide();
|
jQuery('#<?php echo $nameforformuserfile ?>').hide();
|
||||||
});
|
});
|
||||||
|
|||||||
@ -79,7 +79,7 @@ if (!empty($conf->global->ADD_UNSPLASH_LOGIN_BACKGROUND)) {
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<?php if (empty($conf->dol_use_jmobile)) { ?>
|
<?php if (empty($conf->dol_use_jmobile)) { ?>
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
/* Set focus on correct field */
|
/* Set focus on correct field */
|
||||||
<?php if ($focus_element) { ?>$('#<?php echo $focus_element; ?>').focus(); <?php } ?> // Warning to use this only on visible element
|
<?php if ($focus_element) { ?>$('#<?php echo $focus_element; ?>').focus(); <?php } ?> // Warning to use this only on visible element
|
||||||
@ -356,23 +356,22 @@ if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AN_ID))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Google Adsense
|
// TODO Replace this with a hook
|
||||||
|
// Google Adsense (need Google module)
|
||||||
if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AD_CLIENT) && !empty($conf->global->MAIN_GOOGLE_AD_SLOT))
|
if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AD_CLIENT) && !empty($conf->global->MAIN_GOOGLE_AD_SLOT))
|
||||||
{
|
{
|
||||||
if (empty($conf->dol_use_jmobile))
|
if (empty($conf->dol_use_jmobile))
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<div class="center"><br>
|
<div class="center"><br>
|
||||||
<script type="text/javascript"><!--
|
<script><!--
|
||||||
google_ad_client = "<?php echo $conf->global->MAIN_GOOGLE_AD_CLIENT ?>";
|
google_ad_client = "<?php echo $conf->global->MAIN_GOOGLE_AD_CLIENT ?>";
|
||||||
google_ad_slot = "<?php echo $conf->global->MAIN_GOOGLE_AD_SLOT ?>";
|
google_ad_slot = "<?php echo $conf->global->MAIN_GOOGLE_AD_SLOT ?>";
|
||||||
google_ad_width = <?php echo $conf->global->MAIN_GOOGLE_AD_WIDTH ?>;
|
google_ad_width = <?php echo $conf->global->MAIN_GOOGLE_AD_WIDTH ?>;
|
||||||
google_ad_height = <?php echo $conf->global->MAIN_GOOGLE_AD_HEIGHT ?>;
|
google_ad_height = <?php echo $conf->global->MAIN_GOOGLE_AD_HEIGHT ?>;
|
||||||
//-->
|
//-->
|
||||||
</script>
|
</script>
|
||||||
<script type="text/javascript"
|
<script src="//pagead2.googlesyndication.com/pagead/show_ads.js"></script>
|
||||||
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
|
|
||||||
</script>
|
|
||||||
</div>
|
</div>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
|||||||
@ -224,7 +224,7 @@ if ($nolinesbefore) {
|
|||||||
if (!empty($conf->global->MAIN_AUTO_OPEN_SELECT2_ON_FOCUS_FOR_CUSTOMER_PRODUCTS))
|
if (!empty($conf->global->MAIN_AUTO_OPEN_SELECT2_ON_FOCUS_FOR_CUSTOMER_PRODUCTS))
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
// On first focus on a select2 combo, auto open the menu (this allow to use the keyboard only)
|
// On first focus on a select2 combo, auto open the menu (this allow to use the keyboard only)
|
||||||
$(document).on('focus', '.select2-selection.select2-selection--single', function (e) {
|
$(document).on('focus', '.select2-selection.select2-selection--single', function (e) {
|
||||||
@ -259,7 +259,7 @@ if ($nolinesbefore) {
|
|||||||
if (!empty($conf->global->MAIN_AUTO_OPEN_SELECT2_ON_FOCUS_FOR_SUPPLIER_PRODUCTS))
|
if (!empty($conf->global->MAIN_AUTO_OPEN_SELECT2_ON_FOCUS_FOR_SUPPLIER_PRODUCTS))
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
// On first focus on a select2 combo, auto open the menu (this allow to use the keyboard only)
|
// On first focus on a select2 combo, auto open the menu (this allow to use the keyboard only)
|
||||||
$(document).on('focus', '.select2-selection.select2-selection--single', function (e) {
|
$(document).on('focus', '.select2-selection.select2-selection--single', function (e) {
|
||||||
|
|||||||
@ -272,7 +272,7 @@ if (!empty($extrafields))
|
|||||||
print $form->selectDate($line->date_start, 'date_start', $hourmin, $hourmin, $line->date_start ? 0 : 1, "updateline", 1, 0);
|
print $form->selectDate($line->date_start, 'date_start', $hourmin, $hourmin, $line->date_start ? 0 : 1, "updateline", 1, 0);
|
||||||
print ' '.$langs->trans('to').' ';
|
print ' '.$langs->trans('to').' ';
|
||||||
print $form->selectDate($line->date_end, 'date_end', $hourmin, $hourmin, $line->date_end ? 0 : 1, "updateline", 1, 0);
|
print $form->selectDate($line->date_end, 'date_end', $hourmin, $hourmin, $line->date_end ? 0 : 1, "updateline", 1, 0);
|
||||||
print '<script type="text/javascript">';
|
print '<script>';
|
||||||
if (!$line->date_start) {
|
if (!$line->date_start) {
|
||||||
if (isset($conf->global->MAIN_DEFAULT_DATE_START_HOUR)) {
|
if (isset($conf->global->MAIN_DEFAULT_DATE_START_HOUR)) {
|
||||||
print 'jQuery("#date_starthour").val("'.$conf->global->MAIN_DEFAULT_DATE_START_HOUR.'");';
|
print 'jQuery("#date_starthour").val("'.$conf->global->MAIN_DEFAULT_DATE_START_HOUR.'");';
|
||||||
@ -297,7 +297,7 @@ if (!empty($extrafields))
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
|
|
||||||
jQuery(document).ready(function()
|
jQuery(document).ready(function()
|
||||||
{
|
{
|
||||||
|
|||||||
@ -148,7 +148,7 @@ if (!empty($conf->don->enabled))
|
|||||||
|
|
||||||
if (!empty($conf->use_javascript_ajax))
|
if (!empty($conf->use_javascript_ajax))
|
||||||
{
|
{
|
||||||
print "\n".'<script type="text/javascript">';
|
print "\n".'<script>';
|
||||||
print '$(document).ready(function () {
|
print '$(document).ready(function () {
|
||||||
$("#generate_token").click(function() {
|
$("#generate_token").click(function() {
|
||||||
$.get( "'.DOL_URL_ROOT.'/core/ajax/security.php", {
|
$.get( "'.DOL_URL_ROOT.'/core/ajax/security.php", {
|
||||||
|
|||||||
@ -58,7 +58,7 @@ $colorbackhmenu1 = join(',', colorStringToArray($colorbackhmenu1)); // Normalize
|
|||||||
<body class="body bodylogin"<?php print empty($conf->global->MAIN_LOGIN_BACKGROUND) ? '' : ' style="background-size: cover; background-position: center center; background-attachment: fixed; background-repeat: no-repeat; background-image: url(\''.DOL_URL_ROOT.'/viewimage.php?cache=1&noalt=1&modulepart=mycompany&file='.urlencode('logos/'.$conf->global->MAIN_LOGIN_BACKGROUND).'\')"'; ?>>
|
<body class="body bodylogin"<?php print empty($conf->global->MAIN_LOGIN_BACKGROUND) ? '' : ' style="background-size: cover; background-position: center center; background-attachment: fixed; background-repeat: no-repeat; background-image: url(\''.DOL_URL_ROOT.'/viewimage.php?cache=1&noalt=1&modulepart=mycompany&file='.urlencode('logos/'.$conf->global->MAIN_LOGIN_BACKGROUND).'\')"'; ?>>
|
||||||
|
|
||||||
<?php if (empty($conf->dol_use_jmobile)) { ?>
|
<?php if (empty($conf->dol_use_jmobile)) { ?>
|
||||||
<script type="text/javascript">
|
<script>
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
// Set focus on correct field
|
// Set focus on correct field
|
||||||
<?php if ($focus_element) { ?>$('#<?php echo $focus_element; ?>').focus(); <?php } ?> // Warning to use this only on visible element
|
<?php if ($focus_element) { ?>$('#<?php echo $focus_element; ?>').focus(); <?php } ?> // Warning to use this only on visible element
|
||||||
@ -246,23 +246,22 @@ if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AN_ID))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Google Adsense
|
// TODO Replace this with a hook
|
||||||
|
// Google Adsense (need Google module)
|
||||||
if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AD_CLIENT) && !empty($conf->global->MAIN_GOOGLE_AD_SLOT))
|
if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AD_CLIENT) && !empty($conf->global->MAIN_GOOGLE_AD_SLOT))
|
||||||
{
|
{
|
||||||
if (empty($conf->dol_use_jmobile))
|
if (empty($conf->dol_use_jmobile))
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<div class="center"><br>
|
<div class="center"><br>
|
||||||
<script type="text/javascript"><!--
|
<script><!--
|
||||||
google_ad_client = "<?php echo $conf->global->MAIN_GOOGLE_AD_CLIENT ?>";
|
google_ad_client = "<?php echo $conf->global->MAIN_GOOGLE_AD_CLIENT ?>";
|
||||||
google_ad_slot = "<?php echo $conf->global->MAIN_GOOGLE_AD_SLOT ?>";
|
google_ad_slot = "<?php echo $conf->global->MAIN_GOOGLE_AD_SLOT ?>";
|
||||||
google_ad_width = <?php echo $conf->global->MAIN_GOOGLE_AD_WIDTH ?>;
|
google_ad_width = <?php echo $conf->global->MAIN_GOOGLE_AD_WIDTH ?>;
|
||||||
google_ad_height = <?php echo $conf->global->MAIN_GOOGLE_AD_HEIGHT ?>;
|
google_ad_height = <?php echo $conf->global->MAIN_GOOGLE_AD_HEIGHT ?>;
|
||||||
//-->
|
//-->
|
||||||
</script>
|
</script>
|
||||||
<script type="text/javascript"
|
<script src="//pagead2.googlesyndication.com/pagead/show_ads.js"></script>
|
||||||
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
|
|
||||||
</script>
|
|
||||||
</div>
|
</div>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
|||||||
@ -417,16 +417,14 @@ if (!empty($conf->google->enabled) && !empty($conf->global->MAIN_GOOGLE_AD_CLIEN
|
|||||||
if (empty($conf->dol_use_jmobile))
|
if (empty($conf->dol_use_jmobile))
|
||||||
{
|
{
|
||||||
print '<div align="center">'."\n";
|
print '<div align="center">'."\n";
|
||||||
print '<script type="text/javascript"><!--'."\n";
|
print '<script><!--'."\n";
|
||||||
print 'google_ad_client = "'.$conf->global->MAIN_GOOGLE_AD_CLIENT.'";'."\n";
|
print 'google_ad_client = "'.$conf->global->MAIN_GOOGLE_AD_CLIENT.'";'."\n";
|
||||||
print 'google_ad_slot = "'.$conf->global->MAIN_GOOGLE_AD_SLOT.'";'."\n";
|
print 'google_ad_slot = "'.$conf->global->MAIN_GOOGLE_AD_SLOT.'";'."\n";
|
||||||
print 'google_ad_width = '.$conf->global->MAIN_GOOGLE_AD_WIDTH.';'."\n";
|
print 'google_ad_width = '.$conf->global->MAIN_GOOGLE_AD_WIDTH.';'."\n";
|
||||||
print 'google_ad_height = '.$conf->global->MAIN_GOOGLE_AD_HEIGHT.';'."\n";
|
print 'google_ad_height = '.$conf->global->MAIN_GOOGLE_AD_HEIGHT.';'."\n";
|
||||||
print '//-->'."\n";
|
print '//-->'."\n";
|
||||||
print '</script>'."\n";
|
print '</script>'."\n";
|
||||||
print '<script type="text/javascript"'."\n";
|
print '<script src="//pagead2.googlesyndication.com/pagead/show_ads.js"></script>'."\n";
|
||||||
print 'src="http://pagead2.googlesyndication.com/pagead/show_ads.js">'."\n";
|
|
||||||
print '</script>'."\n";
|
|
||||||
print '</div>'."\n";
|
print '</div>'."\n";
|
||||||
} else {
|
} else {
|
||||||
print '<!-- google js advert tag disabled with jmobile -->'."\n";
|
print '<!-- google js advert tag disabled with jmobile -->'."\n";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user