Zen Follower
- Join Date:
- Sep 2010
- Posts:
- 449
- Plugin Contributions:
- 0
cookie consent script
Thanks for the pointer schoolboy, got it working a treat!
Zen Follower
Thanks for the pointer schoolboy, got it working a treat!
Totally Zenned
keneso:
Nevermind.
I think I solved it, if someone please checks at amberprecious dot com, and confirms I'll appreciate.
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
The slider was using jscript_a_jquery-1.6.2.min.js, I deleted that, and putin common/html_header.php right before
- load all site-wide jscript_*.js files from includes/templates/YOURTEMPLATE/jscript, alphabetically
Hi Keneso
Could you walk me through in detail step by step EXACTLY what you did to get this to work on your site please? I too have a slider in header which breaks whenever I load the script into html_header.php
Many thanks
Totally Zenned
schoolboy:
We have managed to embed the COOKIE CONSENT system developed by http://www.wolf-software.com, into this "DEMO" site: http://carpclobber.com
Several minor edits, but not too difficult. Though we are TESTING this for any unseen glitches.
Hi Schoolboy
Could you advise how you were able to edit the wording of the drop down 'more info' box please? I cannot find a file or any reference to the html content within the downloaded folder to edit this.
Many thanks
New Zenner
[QUOTE]> Hi Schoolboy
Could you advise how you were able to edit the wording of the drop down 'more info' box please? I cannot find a file or any reference to the html content within the downloaded folder to edit this.
Many thankspicandnix:
Hi Keneso
Could you walk me through in detail step by step EXACTLY what you did to get this to work on your site please? I too have a slider in header which breaks whenever I load the script into html_header.phpMany thanks
This would also be helpful to me, as i'm having the same problem.
Totally Zenned
Totally Zenned
Totally Zenned
Totally Zenned
No matter what I do I cannot get this to work.
Can somebody put the instructions in KISS? I am using template 'IC Atheme', zencart v1.3.9.h
I know you guys have spent a long time talking about however little old cannot 'get it' Sorry :-(
Learning Fast.
Eden Craft Supplies
Zen Follower
schoolboy:
Stage 5. Not correct...
CivicUK advises that the code is placed just BEFORE the closing </body> tag, so it goes into tpl_main_page.php (right at the bottom, just before the closing </body> tag.)
Hi,
I tried this but still cannot get anything to show up - so far I have uploaded the javascript file to a new folder under public_html called cookies and I have changed the script to show this and included it at the bottom of the tpl_main_page.php file just above the </body> tog but nothing shows up on my site - any help appreciated as I am tearing my hair out over this and civic quoted a huge amount of money to install this for me :(
I am obviously missing something as not too good with php so if someone can point me in the right direction I would appreciate it.
The code I have in my tpl_main_page.php is (this is just the bottom half of the file):
</table>
<?php
/**
* prepares and displays footer output
*
*/
if (CUSTOMERS_APPROVAL_AUTHORIZATION == 1 && CUSTOMERS_AUTHORIZATION_FOOTER_OFF == 'true' and ($_SESSION['customers_authorization'] != 0 or $_SESSION['customer_id'] == '')) {
$flag_disable_footer = true;
}
require($template->get_template_dir('tpl_footer.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_footer.php');
?>
</div>
<!--bof- parse time display -->
<?php
if (DISPLAY_PAGE_PARSE_TIME == 'true') {
?>
<div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div>
<?php
}
?>
<!--eof- parse time display -->
<!--bof- banner #6 display -->
<?php
if (SHOW_BANNERS_GROUP_SET6 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET6)) {
if ($banner->RecordCount() > 0) {
?>
<div id="bannerSix" class="banners"><?php echo zen_display_banner('static', $banner); ?></div>
<?php
}
}
?>
<!--eof- banner #6 display -->
<script src="http://www.geoplugin.net/javascript.gp" type="text/javascript"></script>
<script src="/cookies/cookieControl-4.1.min.js" type="text/javascript"></script>
<script type="text/javascript">//<![CDATA[
cookieControl({
introText:'<p>This site uses cookies to store information on your computer.</p>',
fullText:'<p>Some cookies on this site are essential, and the site won\'t work as expected without them. These cookies are set when you submit a form, login or interact with the site by doing something that goes beyond clicking on simple links.</p><p>We also use some non-essential cookies to anonymously track visitors or enhance your experience of the site. If you\'re not happy with this, we won\'t set these cookies but some nice features of the site may be unavailable.</p><p>By continuing to use this website you are agreeing to the placing of these Cookies.</p><p>By using our site you accept the terms of our <a href="http://www.beeunique.co.uk/privacy.html">Privacy Policy</a>.</p>',
position:'left', // left or right
shape:'triangle', // triangle or diamond
theme:'light', // light or dark
startOpen:true,
autoHide:10000,
subdomains:true,
onAccept:function(){ccAddAnalytics()},
onReady:function(){},
onCookiesAllowed:function(){ccAddAnalytics()},
onCookiesNotAllowed:function(){},
countries:'' // Or supply a list ['United Kingdom', 'Greece']
});
function ccAddAnalytics() {
jQuery.getScript("http://www.google-analytics.com/ga.js", function() {
var GATracker = _gat._createTracker('');
GATracker._trackPageview();
});
}
//]]>
</script>
</body>
Zen Follower
New Zenner
With all the hints here i got it working on my test site. - Thanks
Does anybody have a clue how to handle multiple languages for this?
Totally Zenned
PudzPud:
Sorry for double posting but it wont let me edit post above.
I have found that the tpl_main_page.php file shows up in 4 different places - I changed the one with the red * - should I change it somewhere else instead?
The tpl_main_page.php MUST sit inside the COMMON folder(s) of the templates you have installed. If you have tpl_main_page.php in other directories, delete these instances.
Your asterisk shows you have edited the incorrect file. The one that needs editing sits inside the COMMON folder of your custom template.
20 years a Zencart User
Totally Zenned
asekeris:
With all the hints here i got it working on my test site. - Thanks
Does anybody have a clue how to handle multiple languages for this?
If your site is LOCATED in the UK, then concern yourself only with English. IF it is LOCATED in another EU country, then translate the text to the language of that country.
If your site serves multiple countries, then just have the text in the language of your home country.
20 years a Zencart User
Totally Zenned
The tpl_main_page.php MUST sit inside the COMMON folder(s) of the templates you have installed. If you have tpl_main_page.php in other directories, delete these instances
Which script are you talking about? Zencart plugin or http://civicuk.com/cookie-law?
Learning Fast.
Eden Craft Supplies
Totally Zenned
adb34:
Which script are you talking about? Zencart plugin or http://civicuk.com/cookie-law?
civicuk
(But irrespective of the script, your tpl_main_page.php should not exist in folders outside of the COMMON folder in your templates.)
20 years a Zencart User
Totally Zenned
Forget the last post of mine. I have http://civicuk.com/cookie-law working !!!!!!!!!!! Taken me long enough.
As Schoolboy says, for http://civicuk.com/cookie-law to work you must edited the tpl_main_page.php inside the common folder under YOUR-TEMPLATE (I have put my code just before the </body> command.
Complete all questions info on the page then click on 'collect the code'.
Then you click on 'Download the Cookie Control script here' this will take you to the control script. Save this page as javascript and as cookieControl-4.1.min.js, this title may be put in for you. Now this is the bit I could not get my head around, where to put the javascript? I put mine in sub folder 'lib' in my route directory.
Then go back. On left side is some code pick that up and paste it into your /includes/templates/YOUR_DIRECTORY/common/tpl_main_page.php. Make changes to script as to where you have put your javascript. Mine says <script src="lib/cookieControl-4.1.min.js" type="text/javascript"></script> (where 'lib' directory is in the same file as my index page is).
I hope this helps you, or I might have got you completely lost. I have used this script as I cannot get the other plugin to work.
Learning Fast.
Eden Craft Supplies
Totally Zenned
OK I was to quick. This method only worked once and now has given up. :-(
Learning Fast.
Eden Craft Supplies
Totally Zenned
adb34:
Forget the last post of mine. I have http://civicuk.com/cookie-law working !!!!!!!!!!! Taken me long enough.
As Schoolboy says, for http://civicuk.com/cookie-law to work you must edited the tpl_main_page.php inside the common folder under YOUR-TEMPLATE (I have put my code just before the </body> command.
Complete all questions info on the page then click on 'collect the code'.
Then you click on 'Download the Cookie Control script here' this will take you to the control script. Save this page as javascript and as cookieControl-4.1.min.js, this title may be put in for you. Now this is the bit I could not get my head around, where to put the javascript? I put mine in sub folder 'lib' in my route directory.
Then go back. On left side is some code pick that up and paste it into your /includes/templates/YOUR_DIRECTORY/common/tpl_main_page.php. Make changes to script as to where you have put your javascript. Mine says <script src="lib/cookieControl-4.1.min.js" type="text/javascript"></script> (where 'lib' directory is in the same file as my index page is).
I hope this helps you, or I might have got you completely lost. I have used this script as I cannot get the other plugin to work.
schoolboy:
If your site is LOCATED in the UK, then concern yourself only with English. IF it is LOCATED in another EU country, then translate the text to the language of that country.
If your site serves multiple countries, then just have the text in the language of your home country.
Hi Schoolboy,
Thank you for all the hints n tips, I have got the wolf script working :-) but I would love to alter the text to something more informative and less technical for Joe Public to understand. Could you please describe how you changed the text in your example site please, please, please.
Totally Zenned
adb34:
OK I was to quick. This method only worked once and now has given up. :-(
Lol oh no :-( well once I get to my p.c later I can advise how I got the wolf script working on my site, if you would like me to? it works fine, https://www.shabbylane.co.uk
Totally Zenned
I have got the http://civicuk.com/cookie-law working. It is all down to a / in the wrong place. The line src="/PATH_TO_COOKIE_CONTROL/cookieControl-4.1.min.js" cookie control path, I have found, I should not have the / before it. With it the script does not work without it it does. IE my script says; > <script src="lib/cookieControl-4.1.min.js" type="text/javascript"></script> and not > <script src="/lib/cookieControl-4.1.min.js" type="text/javascript"></script>
Learning Fast.
Eden Craft Supplies
Tell staff why this post should be reviewed.