Commit 112c4862 authored by Pietro Albini's avatar Pietro Albini

Initial commit

parents
# Copyright (c) 2017 Pietro Albini <pietroalbini@ubuntu-it.org>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
# Files in those directories will be converted:
DIRS_JS = js themes
DIRS_CSS = fonts
DIRS_FONTS = fonts
DIR_BUILD = build
JS_MINIFIER = python3 -m rjsmin
CSS_MINIFIER = python3 -m rcssmin
FONT_CONVERTER = fontforge convert-fonts.pe
# Get all the files that needs to be converted
js = $(patsubst %.js,$(DIR_BUILD)/%.min.js,$(shell find $(DIRS_JS) -type f -name "*.js"))
css = $(patsubst %.css,$(DIR_BUILD)/%.min.css,$(shell find $(DIRS_CSS) -type f -name "*.css"))
fonts_ttf = $(patsubst %,$(DIR_BUILD)/%,$(shell find $(DIRS_FONTS) -type f -name "*.ttf"))
fonts_eot = $(patsubst %.ttf,%.eot,$(fonts_ttf))
fonts_woff = $(patsubst %.ttf,%.woff,$(fonts_ttf))
.PHONY: build clean
build: $(js) $(css) $(fonts_ttf) $(fonts_eot) $(fonts_woff)
clean:
@rm -rf $(DIR_BUILD)
$(DIR_BUILD)/%.min.js: %.js
@mkdir -p $(dir $@)
@$(JS_MINIFIER) < $< > $@
$(DIR_BUILD)/%.min.css: %.css
@mkdir -p $(dir $@)
@$(CSS_MINIFIER) < $< > $@
$(DIR_BUILD)/%.ttf: %.ttf
@mkdir -p $(dir $@)
@cp $< $@
$(DIR_BUILD)/%.eot: %.ttf
@mkdir -p $(dir $@)
@$(FONT_CONVERTER) $< $@
$(DIR_BUILD)/%.woff: %.ttf
@mkdir -p $(dir $@)
@$(FONT_CONVERTER) $< $@
# static.ubuntu-it.org
Questo repository contiene i file necessari per buildare il contenuto di
[static.ubuntu-it.org](https://static.ubuntu-it.org). Esso contiene le risorse
statiche utilizzate da buona parte dei portali di Ubuntu-it.
## Build del contenuto
Per eseguire la build, è necessario avere installati Make, rCSSmin, rJSmin e
FontForge. Su Ubuntu 16.04 e superiori è possibile farlo con:
```
apt install make python3-rcssmin python3-rjsmin fontforge
```
Dopo aver fatto ciò basta eseguire `make` per avere la build in `build/`.
#!/usr/bin/env fontforge
Open($1)
Generate($2)
-------------------------------
UBUNTU FONT LICENCE Version 1.0
-------------------------------
PREAMBLE
This licence allows the licensed fonts to be used, studied, modified and
redistributed freely. The fonts, including any derivative works, can be
bundled, embedded, and redistributed provided the terms of this licence
are met. The fonts and derivatives, however, cannot be released under
any other licence. The requirement for fonts to remain under this
licence does not require any document created using the fonts or their
derivatives to be published under this licence, as long as the primary
purpose of the document is not to be a vehicle for the distribution of
the fonts.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this licence and clearly marked as such. This may
include source files, build scripts and documentation.
"Original Version" refers to the collection of Font Software components
as received under this licence.
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to
a new environment.
"Copyright Holder(s)" refers to all individuals and companies who have a
copyright ownership of the Font Software.
"Substantially Changed" refers to Modified Versions which can be easily
identified as dissimilar to the Font Software by users of the Font
Software comparing the Original Version with the Modified Version.
To "Propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification and with or without charging
a redistribution fee), making available to the public, and in some
countries other activities as well.
PERMISSION & CONDITIONS
This licence does not grant any rights under trademark law and all such
rights are reserved.
Permission is hereby granted, free of charge, to any person obtaining a
copy of the Font Software, to propagate the Font Software, subject to
the below conditions:
1) Each copy of the Font Software must contain the above copyright
notice and this licence. These can be included either as stand-alone
text files, human-readable headers or in the appropriate machine-
readable metadata fields within text or binary files as long as those
fields can be easily viewed by the user.
2) The font name complies with the following:
(a) The Original Version must retain its name, unmodified.
(b) Modified Versions which are Substantially Changed must be renamed to
avoid use of the name of the Original Version or similar names entirely.
(c) Modified Versions which are not Substantially Changed must be
renamed to both (i) retain the name of the Original Version and (ii) add
additional naming elements to distinguish the Modified Version from the
Original Version. The name of such Modified Versions must be the name of
the Original Version, with "derivative X" where X represents the name of
the new work, appended to that name.
3) The name(s) of the Copyright Holder(s) and any contributor to the
Font Software shall not be used to promote, endorse or advertise any
Modified Version, except (i) as required by this licence, (ii) to
acknowledge the contribution(s) of the Copyright Holder(s) or (iii) with
their explicit written permission.
4) The Font Software, modified or unmodified, in part or in whole, must
be distributed entirely under this licence, and must not be distributed
under any other licence. The requirement for fonts to remain under this
licence does not affect any document created using the Font Software,
except any version of the Font Software extracted from a document
created using the Font Software may only be distributed under this
licence.
TERMINATION
This licence becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF
COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER
DEALINGS IN THE FONT SOFTWARE.
@font-face {
font-family: 'Ubuntu Condensed';
font-weight: 400;
font-style: normal;
src: url('ubuntu-condensed-400.eot');
src: url('ubuntu-condensed-400.ttf') format('truetype'),
url('ubuntu-condensed-400.woff') format('woff');
}
.font--ubuntu-condensed {
font-family: 'Ubuntu Condensed';
}
-------------------------------
UBUNTU FONT LICENCE Version 1.0
-------------------------------
PREAMBLE
This licence allows the licensed fonts to be used, studied, modified and
redistributed freely. The fonts, including any derivative works, can be
bundled, embedded, and redistributed provided the terms of this licence
are met. The fonts and derivatives, however, cannot be released under
any other licence. The requirement for fonts to remain under this
licence does not require any document created using the fonts or their
derivatives to be published under this licence, as long as the primary
purpose of the document is not to be a vehicle for the distribution of
the fonts.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this licence and clearly marked as such. This may
include source files, build scripts and documentation.
"Original Version" refers to the collection of Font Software components
as received under this licence.
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to
a new environment.
"Copyright Holder(s)" refers to all individuals and companies who have a
copyright ownership of the Font Software.
"Substantially Changed" refers to Modified Versions which can be easily
identified as dissimilar to the Font Software by users of the Font
Software comparing the Original Version with the Modified Version.
To "Propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification and with or without charging
a redistribution fee), making available to the public, and in some
countries other activities as well.
PERMISSION & CONDITIONS
This licence does not grant any rights under trademark law and all such
rights are reserved.
Permission is hereby granted, free of charge, to any person obtaining a
copy of the Font Software, to propagate the Font Software, subject to
the below conditions:
1) Each copy of the Font Software must contain the above copyright
notice and this licence. These can be included either as stand-alone
text files, human-readable headers or in the appropriate machine-
readable metadata fields within text or binary files as long as those
fields can be easily viewed by the user.
2) The font name complies with the following:
(a) The Original Version must retain its name, unmodified.
(b) Modified Versions which are Substantially Changed must be renamed to
avoid use of the name of the Original Version or similar names entirely.
(c) Modified Versions which are not Substantially Changed must be
renamed to both (i) retain the name of the Original Version and (ii) add
additional naming elements to distinguish the Modified Version from the
Original Version. The name of such Modified Versions must be the name of
the Original Version, with "derivative X" where X represents the name of
the new work, appended to that name.
3) The name(s) of the Copyright Holder(s) and any contributor to the
Font Software shall not be used to promote, endorse or advertise any
Modified Version, except (i) as required by this licence, (ii) to
acknowledge the contribution(s) of the Copyright Holder(s) or (iii) with
their explicit written permission.
4) The Font Software, modified or unmodified, in part or in whole, must
be distributed entirely under this licence, and must not be distributed
under any other licence. The requirement for fonts to remain under this
licence does not affect any document created using the Font Software,
except any version of the Font Software extracted from a document
created using the Font Software may only be distributed under this
licence.
TERMINATION
This licence becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF
COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER
DEALINGS IN THE FONT SOFTWARE.
@font-face {
font-family: 'Ubuntu Mono';
font-weight: 400;
font-style: normal;
src: url('ubuntu-mono-400.eot') format('eot');
src: url('ubuntu-mono-400.ttf') format('truetype'),
url('ubuntu-mono-400.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu Mono';
font-weight: 400;
font-style: italic;
src: url('ubuntu-mono-400-italic.eot') format('eot');
src: url('ubuntu-mono-400-italic.ttf') format('truetype'),
url('ubuntu-mono-400-italic.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu Mono';
font-weight: 700;
font-style: normal;
src: url('ubuntu-mono-700.eot') format('eot');
src: url('ubuntu-mono-700.ttf') format('truetype'),
url('ubuntu-mono-700.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu Mono';
font-weight: 700;
font-style: italic;
src: url('ubuntu-mono-700-italic.eot') format('eot');
src: url('ubuntu-mono-700-italic.ttf') format('truetype'),
url('ubuntu-mono-700-italic.woff') format('woff');
}
.font--ubuntu-mono {
font-family: 'Ubuntu Mono';
}
-------------------------------
UBUNTU FONT LICENCE Version 1.0
-------------------------------
PREAMBLE
This licence allows the licensed fonts to be used, studied, modified and
redistributed freely. The fonts, including any derivative works, can be
bundled, embedded, and redistributed provided the terms of this licence
are met. The fonts and derivatives, however, cannot be released under
any other licence. The requirement for fonts to remain under this
licence does not require any document created using the fonts or their
derivatives to be published under this licence, as long as the primary
purpose of the document is not to be a vehicle for the distribution of
the fonts.
DEFINITIONS
"Font Software" refers to the set of files released by the Copyright
Holder(s) under this licence and clearly marked as such. This may
include source files, build scripts and documentation.
"Original Version" refers to the collection of Font Software components
as received under this licence.
"Modified Version" refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to
a new environment.
"Copyright Holder(s)" refers to all individuals and companies who have a
copyright ownership of the Font Software.
"Substantially Changed" refers to Modified Versions which can be easily
identified as dissimilar to the Font Software by users of the Font
Software comparing the Original Version with the Modified Version.
To "Propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification and with or without charging
a redistribution fee), making available to the public, and in some
countries other activities as well.
PERMISSION & CONDITIONS
This licence does not grant any rights under trademark law and all such
rights are reserved.
Permission is hereby granted, free of charge, to any person obtaining a
copy of the Font Software, to propagate the Font Software, subject to
the below conditions:
1) Each copy of the Font Software must contain the above copyright
notice and this licence. These can be included either as stand-alone
text files, human-readable headers or in the appropriate machine-
readable metadata fields within text or binary files as long as those
fields can be easily viewed by the user.
2) The font name complies with the following:
(a) The Original Version must retain its name, unmodified.
(b) Modified Versions which are Substantially Changed must be renamed to
avoid use of the name of the Original Version or similar names entirely.
(c) Modified Versions which are not Substantially Changed must be
renamed to both (i) retain the name of the Original Version and (ii) add
additional naming elements to distinguish the Modified Version from the
Original Version. The name of such Modified Versions must be the name of
the Original Version, with "derivative X" where X represents the name of
the new work, appended to that name.
3) The name(s) of the Copyright Holder(s) and any contributor to the
Font Software shall not be used to promote, endorse or advertise any
Modified Version, except (i) as required by this licence, (ii) to
acknowledge the contribution(s) of the Copyright Holder(s) or (iii) with
their explicit written permission.
4) The Font Software, modified or unmodified, in part or in whole, must
be distributed entirely under this licence, and must not be distributed
under any other licence. The requirement for fonts to remain under this
licence does not affect any document created using the Font Software,
except any version of the Font Software extracted from a document
created using the Font Software may only be distributed under this
licence.
TERMINATION
This licence becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF
COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER
DEALINGS IN THE FONT SOFTWARE.
@font-face {
font-family: 'Ubuntu';
font-weight: 300;
font-style: normal;
src: url('ubuntu-300.eot');
src: url('ubuntu-300.ttf') format('truetype'),
url('ubuntu-300.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 300;
font-style: italic;
src: url('ubuntu-300-italic.eot');
src: url('ubuntu-300-italic.ttf') format('truetype'),
url('ubuntu-300-italic.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 400;
font-style: normal;
src: url('ubuntu-400.eot');
src: url('ubuntu-400.ttf') format('truetype'),
url('ubuntu-400.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 400;
font-style: italic;
src: url('ubuntu-400-italic.eot');
src: url('ubuntu-400-italic.ttf') format('truetype'),
url('ubuntu-400-italic.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 500;
font-style: normal;
src: url('ubuntu-500.eot');
src: url('ubuntu-500.ttf') format('truetype'),
url('ubuntu-500.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 500;
font-style: italic;
src: url('ubuntu-500-italic.eot');
src: url('ubuntu-500-italic.ttf') format('truetype'),
url('ubuntu-500-italic.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 700;
font-style: normal;
src: url('ubuntu-700.eot');
src: url('ubuntu-700.ttf') format('truetype'),
url('ubuntu-700.woff') format('woff');
}
@font-face {
font-family: 'Ubuntu';
font-weight: 700;
font-style: italic;
src: url('ubuntu-700-italic.eot');
src: url('ubuntu-700-italic.ttf') format('truetype'),
url('ubuntu-700-italic.woff') format('woff');
}
.font--ubuntu {
font-family: 'Ubuntu';
}
This source diff could not be displayed because it is too large. You can view the blob instead.
/*
** This file contains function to enable and
** disable Accessibility stylesheet in ubuntu-it
*/
//ACCESSIBILITY_CSS_THEME_DIR = 'light-drupal-theme/styles';
//ACCESSIBILITY_CSS_FILE_NAME = 'accessibility.css' ;
ACCESSIBILITY_CSS_ABSPATH = ['https://www.ubuntu-it.org/sites/all/themes/light-drupal-theme/styles/accessibility.css'];
ACCESSIBILITY_COOKIE_VALUE_ON = 'on';
ACCESSIBILITY_COOKIE_VALUE_OFF = 'off';
// This function adds the accessibility css into the Head section
// and set the cookie value ON
function accessibility_set_on () {
head = document.getElementsByTagName('head')[0];
for (i = 0; i < ACCESSIBILITY_CSS_ABSPATH.length ; i++) {
link = document.createElement('link');
link.setAttribute('type','text/css');
link.setAttribute('rel', 'stylesheet');
link.setAttribute('media', 'screen');
link.setAttribute('href', ACCESSIBILITY_CSS_ABSPATH[i]);
head.appendChild(link);
}
set_cookie_accessibility( ACCESSIBILITY_COOKIE_VALUE_ON );
}
// This function removes the accessibility css from the Head section
// and set the cookie value OFF
function accessibility_set_off() {
head = document.getElementsByTagName('head')[0];
links = head.getElementsByTagName('link');
links_to_remove = []
for (i = 0 ; i < links.length ; i++) {
link = links[i];
if (link.getAttribute('type') == 'text/css') {
for (j = 0 ; j < ACCESSIBILITY_CSS_ABSPATH.length ; j++) {
if (link.getAttribute('href').indexOf(ACCESSIBILITY_CSS_ABSPATH[j]) >= 0 ) {
links_to_remove.push(link);
}
}
}
}
for (i = 0; i < links_to_remove.length; i++) {
head.removeChild(links_to_remove[i]);
}
set_cookie_accessibility( ACCESSIBILITY_COOKIE_VALUE_OFF );
}
function accessibility_toggle () {
value = get_cookie_accessibility();
// If accessibility is ON, remove the css stylesheet
if (value == ACCESSIBILITY_COOKIE_VALUE_ON)
accessibility_set_off();
else
accessibility_set_on();
}
// The main function
function accessibility () {
value = get_cookie_accessibility();
// If accessibility is ON, add the css stylesheet
if (value == ACCESSIBILITY_COOKIE_VALUE_ON)
accessibility_set_on();
}
// Common variabiles
COOKIE_DOMAIN = "ubuntu-it.org";
COOKIE_PREFIX = "ubuntu-it_custom_";
COOKIE_ACCESIBILITY_NAME = "accessibility";
COOKIE_POLICY_NAME = "policy"
// Start Cookie in browser functions
function set_cookie ( name, value, expires, path, domain, secure )
{
name = COOKIE_PREFIX + name;
var cookie_string = name + "=" + escape ( value );
if ( expires ) {
cookie_string += "; expires=" + expires.toGMTString();
}
else {
var expires = new Date ( 2100, 1, 1); // never expires
cookie_string += "; expires=" + expires.toGMTString();
}
if ( path )
cookie_string += "; path=" + escape ( path );
else
cookie_string += "; path=" + escape ("/")
if ( domain )
cookie_string += "; domain=" + escape ( domain );
else
// cookie_string += "; domain=" + escape (location.host)
cookie_string += "; domain=" + escape (COOKIE_DOMAIN);
if ( secure )
cookie_string += "; secure";
document.cookie = cookie_string;
}
function delete_cookie ( cookie_name ) {
cookie_name = COOKIE_PREFIX + cookie_name;
var cookie_date = new Date ( ); // current date & time
cookie_date.setTime ( cookie_date.getTime() - 1 );
document.cookie = cookie_name += "=; expires=" + cookie_date.toGMTString();
}
function get_cookie ( cookie_name ) {
cookie_name = COOKIE_PREFIX + cookie_name;
if (document.cookie.length>0)
{
c_start=document.cookie.indexOf(cookie_name + "=");
if (c_start!=-1)
{
c_start = c_start + cookie_name.length+1;
c_end = document.cookie.indexOf(";", c_start);
if (c_end == -1) c_end = document.cookie.length;
return unescape(document.cookie.substring(c_start,c_end));
}
}
return null
}
// End Cookie in browser functions
// Cookie policy
function get_cookie_policy() {
cookie_name = COOKIE_POLICY_NAME;
return get_cookie(cookie_name);
}
function set_cookie_policy() {
cookie_name = COOKIE_POLICY_NAME;
set_cookie(cookie_name, "accepted");
var bar = document.getElementById('_ubuntu-it_cookie_policy');
if ( bar != null ) {
bar.remove();
}
}
function init_cookie_policy_bar() {
value = get_cookie_policy();
if ( value == null ) {
display_cookie_policy_bar()
}
}
function display_cookie_policy_bar() {
var content = '<div style="position: fixed; z-index: 4814; bottom: 0px;' +
' background: #ffffff; width: 100%;' +
' border-top: 2px solid rgb(221, 72, 20);"' +
' id="_ubuntu-it_cookie_policy">' +
' <div style="float: left; padding: 5px 20px;">' +
' Ubuntu-it utilizza dei cookie per fornirti una' +
' migliore esperienza di navigazione. L\'uso dei' +
' servizi offerti implica l\'accettazione di ' +
' ci&ograve;.' +
' </div>' +
' <div style="float: right;">' +
' <a style="display: inline-block; padding: 5px' +
' 10px 5px 0px;"' +
' href="http://www.ubuntu-it.org/cookies">' +
' Maggiori informazioni' +
' </a>' +
' <a style="display: inline-block; background:' +
' #dd4814; color: #ffffff; padding:' +
' 5px 20px;" href="#cookies-ok"' +
' onclick="set_cookie_policy(); return false;">' +
' Va bene' +
' </a>' +
' </div>' +
'</div>';
var wrapper = document.createElement("div");
wrapper.innerHTML = content;
document.body.appendChild(wrapper);
}
window.onload = function() {
init_cookie_policy_bar();
}
// Accessibility
function set_cookie_accessibility (cookie_value) {
cookie_name = COOKIE_ACCESIBILITY_NAME;
set_cookie (cookie_name, cookie_value);
}
function get_cookie_accessibility () {
cookie_name = COOKIE_ACCESIBILITY_NAME;
return get_cookie (cookie_name);
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment