chupokabr / CConsent

Cookie consent law - it's easy! (The website with docs and demo will be available soon)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CConsent

Cookie consent law - it's easy!

Getting Started

You need to include the CSS file in the <head> section of your HTML and you need to include the js before the </body> tag in your HTML.

<html>
	<head>
		...
		<link rel="stylesheet" href="/path/to/css/cconsent.min.css">
		...
	</head>
	<body>
		...
		<script src="/path/to/js/jquery.min.js"></script>
		<script src="/path/to/js/cconsent.min.js"></script>
	</body>
</html>

And next you need to initialize the CConsent (paste this lines after including cconsent.min.js!)

<script>
$(function () {
	$.cconsent({
		text: "We're using HTTP cookie for your comfort",
		link: 'https://en.wikipedia.org/wiki/HTTP_cookie',
		link_text: 'Details',
		btn_text: 'Accept'
	});
});
</script>

Of course you can initialize CConsent without any parameters, like this:

<script>
$(function () {$.cconsent()});
</script>

but we don't recommend this, because it's very-very boring :)

About

Cookie consent law - it's easy! (The website with docs and demo will be available soon)

License:GNU General Public License v3.0


Languages

Language:JavaScript 51.1%Language:CSS 48.9%