Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 Programming Discussions
  #1  
Old 05-26-2012, 01:55 PM
Simon Lloyd's Avatar
Simon Lloyd Simon Lloyd is offline
 
Join Date: Aug 2008
Location: Manchester
Posts: 3,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Allowing cookie choice

Hi all, a new law has just come to pass in the UK which means you must tell the user of your site that you use cookies and what is stored with the cookies, you must also give them the choice NOT to have cookies stored and explain to them what happens if they decline.

With the above in mind i have tried many things to detect if the user has cookies enabled and then show a message box with a "Yes or No" button, choosing "No" (not wanting cookies stored) should redirect them to either another webpage like google or a custom page yet again informing them that they declined to use cookies and therefore cannot use your site (i say this because i tried setting my IE privacy to maximum (not accept cookies) and couldn't view my site)

Checking if cookies are enabled means having to redirect them after they visit your site to another page so you can check if isset($Cookies but thats not ideal, so i guess all guests should get the pop up regardless of cookies set or not and asked the question and all members should be forced to select the "Yes" option in a custom profile field ($field25 in my case) if they choose "No" they are logged out, when logging ion again if "Yes" isn't set they should be redirected to their usercp>edit options or maybe a box with two selections "Yes or No" and the answer is stored in the database.

I'd appreciate all the help i can get creating the above.
Reply With Quote
  #2  
Old 05-26-2012, 02:01 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't have any help on that, but I know there's a thread on that subject on vbulletin.com

I really don't understand the law. It seems like it would make much more sense to require browser software to give users greater control.
Reply With Quote
  #3  
Old 05-26-2012, 02:23 PM
Simon Lloyd's Avatar
Simon Lloyd Simon Lloyd is offline
 
Join Date: Aug 2008
Location: Manchester
Posts: 3,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by kh99 View Post
I don't have any help on that, but I know there's a thread on that subject on vbulletin.com

I really don't understand the law. It seems like it would make much more sense to require browser software to give users greater control.
I agree!!, anyway as i DO have to do it, being in the uk i've made a start, right now i'm concentrating on getting the members to select yes in their options, this echo's the message but shows the "Cannot Modify header....headers already sent"
PHP Code:
if (is_member_of($vbulletin->userinfo, array( 5,6,7))){
if (
$vbulletin->userinfo['field25']!=='Yes') {
echo 
"You are now being redirected to your <b>usercp>edit options</b>, change your cookie setting found in <b>Login & Privacy</b>";
header("Location: profile.php?do=editoptions");
}

i also need to work out capturing their selection in editoptions, if they select "No" they should be logged out but then the field should be cleared so they can log back in and get redirected again?
Reply With Quote
  #4  
Old 05-26-2012, 04:02 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't follow exactly what you're trying to do. But I can tell you that you're getting "headers already sent" because your echo is before the header() call. But even if you reverse them, I'm not sure that the user will ever see your message.

Seems like someone needs to create some kind of generic web site "front end" that checks for a "I'm allowing cookies" cookie and if it's not found, send the user to a page that lets them choose.
Reply With Quote
  #5  
Old 05-26-2012, 04:08 PM
Simon Lloyd's Avatar
Simon Lloyd Simon Lloyd is offline
 
Join Date: Aug 2008
Location: Manchester
Posts: 3,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No doubt i'll post in this thread lots as i build this, i'll then release it for everyone else
Reply With Quote
  #6  
Old 05-26-2012, 04:21 PM
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Location: Germany
Posts: 6,863
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Germany has the same law (at least it should have it by now, as any other EU country as well)

The best advice I could give you is to ignore it or to close your board as it is pretty much impossible to comply without ailienating your guest visitors.
Sooner or later even the EU commission will understand that this is not going to work.
Reply With Quote
  #7  
Old 05-26-2012, 04:35 PM
Simon Lloyd's Avatar
Simon Lloyd Simon Lloyd is offline
 
Join Date: Aug 2008
Location: Manchester
Posts: 3,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Lol, well im not going to close my baby down, and i'd like to try and comply in a way that won't alienate potential visitors, so really it woulr be nice to detect cookies or via session and then give them the option.

I hear what you are saying though
Reply With Quote
  #8  
Old 05-27-2012, 12:37 PM
Big-Pete Big-Pete is offline
 
Join Date: May 2009
Posts: 187
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

On one of my sites (non vbulletin) i've just added a footer link to a static page that has info on how and why we use cookies (as per the example from JohnLewis's site in link), which accoriding to info from a now ex hosting company and this from affiliate future is all I need to do..

I would be interested in a mod for vBulletin though similar to the example of the ICO site..
Reply With Quote
  #9  
Old 05-27-2012, 02:27 PM
Simon Lloyd's Avatar
Simon Lloyd Simon Lloyd is offline
 
Join Date: Aug 2008
Location: Manchester
Posts: 3,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The trouble with forums is that the cookies are tracking cookies which falls well within the eu scope of whats wrong, so you cannot just provide a note, you have to provide them a way of opting out even if that means redirecting them away from your site, however, if you're clever you can use a target="_blank" link and send them here for google opt out Google Opt Out and here for more info on how to deal with it themselves All About Cookies, i'm currently working on something and hope to release it in a few days when i iron out the bugs n stuff and have it working for all versions of vb
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:27 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04306 seconds
  • Memory Usage 2,244KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_php
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (9)postbit
  • (9)postbit_onlinestatus
  • (9)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete