WebSite X5Help Center

 
Elvis L.
Elvis L.
User

Project analysis error  en

Autor: Elvis L.
Visitado 1268, Seguidores 1, Compartilhado 0  

Hi ,

after downloading cookies script from this page https://helpcenter.websitex5.com/post/106713 i went to section statistic ,seo and code under expert tab i added next code:

After oppening the head

<html>

<head>

<!-- Include jQuery -->

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>

<!-- Include you know cookiesDirective.js plugin -->

<script type="text/javascript" src="jquery.cookiesdirective.js"></script>

</head>


</html>

After opening the Body tag

<body>

<div id="eantics"></div>

<script type="text/javascript">

// Using $(document).ready never hurts

$(document).ready(function(){

// Cookie setting script wrapper

var cookieScripts = function () {

// Internal javascript called

console.log("Running");

// Loading external javascript file

$.cookiesDirective.loadScript({

uri:'external.js',

appendTo: 'eantics'

});

}

/* Call cookiesDirective, overriding any default params

*** These are the defaults ***

explicitConsent: true,

position: 'top',

duration: 15,

limit: 0,

message: null,

cookieScripts: null,

privacyPolicyUri: 'Pravno-obvestilo.html',

scriptWrapper: function(){},

fontFamily: 'helvetica',

fontColor: '#FFFFFF',

fontSize: '13px',

backgroundColor: '#000000',

backgroundOpacity: '75',

linkColor: '#CA0000'

*/

$.cookiesDirective({

privacyPolicyUri: 'Piskotki.html',

explicitConsent: true,

position : 'top',

scriptWrapper: cookieScripts,

cookieScripts: 'Google Analytics, My Stats Ultimate ',

backgroundColor: '#0B3B0B',

linkColor: '#ffffff'

});

});

</script>

</body>

the script works fine but after i went through, analysis error poped up

"there are errors in the custom code entered in the page properties"

Publicado em
1 RESPOSTAS - 1 ÚTIL - 1 CORRIGIR
Anthony A.
Anthony A.
User

remove these from your script/code and test it again

from head section remove:

<html>

<head>

</head>


</html>

from the secound part remove:

<body>

</body>

if this post is the correct answer, please mark this answer as correct answer.

------------------------------------------------------------

Good Luck

Ler mais
Publicado em de Anthony A.