Cookie Consent by FriendsOfFlarum

MIT license Latest Stable Version Total Downloads OpenCollective

Extiverse

This extension adds a customizable Cookie Consent pop-up to your Flarum installation.
Are you from a country where Cookie Consent laws are in place? Have no fear! We've got you covered!

Installation

composer require fof/cookie-consent

Updating

composer update fof/cookie-consent
php flarum cache:clear

Configuration

Once enabled, a new modal to configure/customize your desired settings will appear.

Usage

To get to the settings modal, click the triple dots that appear when hovering your mouse
cursor over the "Cookie Consent" extension text as shown below:

Cookie Consent Extension Settings

Once the settings modal pop-ups, configure/customize the settings like so:

Cookie Consent Extension Configuration

Once completed, click "Save Changes" and make your way to your forum index.

You should now be presented with a one-time cookie consent notification!

Cookie Consent Notification

Pretty simple right? Now begone heathen!

Testing

In order to get the Cookie Consent bar to pop-up again, you will have to delete the cookie
data related to your site which is named "cookieconsent_status" or, you can delete ALL of the
cookie data related your site (NOT THE ENTIRE BROWSER!!) (See your respected browser manuals
for more information about managing cookies). Once removed, refresh your forum index page
and it shall appear once more. Repeat the process anytime you wish to change any of the setting
and want to see those settings live as you edit them.

Or you can just enter your forum in Incognito Mode (if supported).

Links

    Nice job.

    By the way, the option to set the text description for the link to a cookie consent policy is Please enter the text to be displayed on the close buttonwhich seems like an error.

      jordanjay29 It appears that somewhere, while I was writing the code, I completely muddled where I put the variables. I am going to re-create the consent code, and see if I can get it sorted out ?

      The extension is still functional, but still has the flaw that @jordanjay29 pointed out. Also, it isn't recommended to run dev-master as it is currently completely out to lunch! ?

      0.1.0-beta2 Released!

      In this release, I fix a mistake pointed out by @jordanjay29 , where the actual settings modal fields don't line up with what they actually do. In this release:

      • Completely Redsigned Cookie Consent Code
      • New Variable to replace malfunctioning one
      • Bug fixes

      Stay tuned for beta3!

      a month later

      0.1.0-beta3 Released

      In this release, the code is completely refactored by @Ralkage, thanks man! I encourage all users to update as this will be a major change, and will make the extension a lot more stable.

      4 months later

      Just in case you were wondering, this extension has been updated for beta8, and has been completely rewritten by @datitisev.

      This includes utilizing webpack (thanks core devs!) and using npm to import the cookieconsent library.

      This extension has also been transferred over to reflar, and I will update the packagist links once beta8 is released. Thanks for all your support!

      4 months later

      Any updates on this? (Coming from a european forum that's currently in production).

        user1993 No updates, sorry.

        Just kidding

        0.1.0

        • Beta 8 compatibility
        • Refactored for speed by @datitisev

        Updating ⬆️

        Make sure you are running Flarum beta 8, this update will not work on any other version

        This extension was migrated to ReFlar, make sure you have the ReFlar version by running the following commands (in this order) in your Flarum root directory:

        • composer remove zaptech/cookie-consent
        • composer require reflar/cookie-consent
        • php flarum cache:clear
        4 months later

        0.2.0

        Changelog 🛠️

        • Added No CSS theme option which doesn't load any of the Cookie Consent CSS, allowing you to completely customize it without any troubles
        • Added text color configuration to the settings
        • Made some strings in the settings modal translatable
        • Organized the settings modal a bit more
          • Text & Background color inputs are now side-by-side in a single row

        Updating ⬆️

        composer update reflar/cookie-consent

        Please allow Bazaar up to 60 minutes to pull the update.

        5 months later

        The cookie consent is incomplete for european laws like in France where you must have a decline option for each cookies like google analytics, google adwords etc...

          • [deleted]

          brian85 do we have a better solution for Flarum?

          brian85 Flarum doesn't work without cookies, it redirects you to the no-JavaScript page. It doesn't need cookies to function, but right now, you can only view a few images without cookies or JS.

          Apart from that, the decline option would need to be integrated by Flarum and extensions, not just this one, as they add custom code that we can't track (eg Google Analytics with analytics extension).

            datitisev Yes I've understand that, that's why I said it, actually this cookie consent does not comply with french laws for data privacy protection. Thank you.