';
+
+ return $jsource;
+ /*}*/
}
/**
@@ -146,14 +161,7 @@ function cookiecontrol_onacceptance() {
$cookiecontrol_acceptancecallback = "function cookiecontrol_accepted(cc) {\n" . implode("\n", $callbacks) . "\n}";
- drupal_add_js($cookiecontrol_acceptancecallback, array(
- 'type' => 'inline',
- 'preprocess' => TRUE,
- 'scope' => 'footer',
- 'group' => JS_DEFAULT,
- 'every_page' => TRUE,
- 'cache' => TRUE,
- ));
+ drupal_add_js($cookiecontrol_acceptancecallback, 'inline', 'footer', FALSE, TRUE, TRUE);
}
/**
@@ -167,14 +175,7 @@ function cookiecontrol_cookiesallowed() {
$cookiecontrol_cookiesallowedcallback = "function cookiecontrol_cookiesallowed(cc) {\n" . implode("\n", $callbacks) . "\n}";
- drupal_add_js($cookiecontrol_cookiesallowedcallback, array(
- 'type' => 'inline',
- 'preprocess' => TRUE,
- 'scope' => 'footer',
- 'group' => JS_DEFAULT,
- 'every_page' => TRUE,
- 'cache' => TRUE,
- ));
+ drupal_add_js($cookiecontrol_cookiesallowedcallback, 'inline', 'footer', FALSE, TRUE, TRUE);
}
/**
@@ -188,27 +189,32 @@ function cookiecontrol_cookiesnotallowed() {
$cookiecontrol_cookiesnotallowedcallback = "function cookiecontrol_cookiesnotallowed(cc) {\n" . implode("\n", $callbacks) . "\n}";
- drupal_add_js($cookiecontrol_cookiesnotallowedcallback, array(
- 'type' => 'inline',
- 'preprocess' => TRUE,
- 'scope' => 'footer',
- 'group' => JS_DEFAULT,
- 'every_page' => TRUE,
- 'cache' => TRUE,
- ));
+ drupal_add_js($cookiecontrol_cookiesnotallowedcallback, 'inline', 'footer', FALSE, TRUE, TRUE);
+}
+
+/**
+ * Implements hook_init().
+ */
+function cookiecontrol_init() {
+ $path = drupal_get_path('module', 'cookiecontrol');
+ drupal_add_css($path . '/css/eu_cookie_compliance.css');
+ drupal_add_js($path . '/js/cookieControl-4.1.min.js', 'module', 'footer');
}
/**
* If cookie consent has not yet been given add a validation callback to tell the user and disable any submission callbacks
*/
-function cookiecontrol_form_user_login_block_alter(&$form, &$form_state, $form_id) {
- if ($s = cookiecontrol_userinrestrictedcountry()) {
- if (!isset($_COOKIE[cookiecontrol_generatesitecookie()]) || $_COOKIE[cookiecontrol_generatesitecookie()] != 'yes') {
- // Repalce all validation callbacks with just one telling the visitor they cannot log in yet
- $form['#validate'] = array('cookiecontrol_user_login_ban');
+//function cookiecontrol_form_user_login_block_alter(&$form, &$form_state, $form_id) {
+function cookiecontrol_form_alter($form_id, &$form) {
+ if ($form_id == 'user_login_block' || $form_id == 'user_login') {
+ if ($s = cookiecontrol_userinrestrictedcountry()) {
+ if (!isset($_COOKIE[cookiecontrol_generatesitecookie()]) || $_COOKIE[cookiecontrol_generatesitecookie()] != 'yes') {
+ // Repalce all validation callbacks with just one telling the visitor they cannot log in yet
+ $form['#validate'] = array('cookiecontrol_user_login_ban');
- // Remove any existing submit handlers to prevent any authentication taking place
- unset($form['#submit']);
+ // Remove any existing submit handlers to prevent any authentication taking place
+ unset($form['#submit']);
+ }
}
}
}
@@ -237,8 +243,29 @@ function cookiecontrol_userinrestrictedcountry() {
if ($request->code == 200) {
$geo_info = unserialize($request->data);
return stripos($cookiecontrol_countries, $geo_info['geoplugin_countryName']) !== FALSE ? TRUE : FALSE;
- } else {
+ }
+ else {
watchdog('Cookie Control', 'A visitors IP address could not be matched to a location so they were not blocked from logging in. Geoplugin returned the error [@code] @message', array('@code' => $request->code, '@message' => $request->status_message), WATCHDOG_ERROR);
return TRUE;
}
+}
+
+/**
+ * Drupal 7 Backported functions
+ */
+ function cookiecontrol_clean_css_identifier($identifier, $filter = array(' ' => '-', '_' => '-', '/' => '-', '[' => '-', ']' => '')) {
+ // By default, we filter using Drupal's coding standards.
+ $identifier = strtr($identifier, $filter);
+
+ // Valid characters in a CSS identifier are:
+ // - the hyphen (U+002D)
+ // - a-z (U+0030 - U+0039)
+ // - A-Z (U+0041 - U+005A)
+ // - the underscore (U+005F)
+ // - 0-9 (U+0061 - U+007A)
+ // - ISO 10646 characters U+00A1 and higher
+ // We strip out any character not in the above list.
+ $identifier = preg_replace('/[^\x{002D}\x{0030}-\x{0039}\x{0041}-\x{005A}\x{005F}\x{0061}-\x{007A}\x{00A1}-\x{FFFF}]/u', '', $identifier);
+
+ return $identifier;
}
\ No newline at end of file
diff --git a/js/cookieControl-4.1.min.js b/js/cookieControl-4.1.min.js
old mode 100644
new mode 100755
diff --git a/modules/cookie_googleanalytics/cookie_googleanalytics.info b/modules/cookie_googleanalytics/cookie_googleanalytics.info
deleted file mode 100644
index 859389f..0000000
--- a/modules/cookie_googleanalytics/cookie_googleanalytics.info
+++ /dev/null
@@ -1,6 +0,0 @@
-; $Id$
-name = "Cookie Control for Google Analytics"
-description = "Disabled Google Analytics form tracking until visitor consents"
-dependencies[] = "cookiecontrol"
-dependencies[] = "googleanalytics"
-core = 7.x
diff --git a/modules/cookie_googleanalytics/cookie_googleanalytics.module b/modules/cookie_googleanalytics/cookie_googleanalytics.module
deleted file mode 100644
index 44aee30..0000000
--- a/modules/cookie_googleanalytics/cookie_googleanalytics.module
+++ /dev/null
@@ -1,40 +0,0 @@
-
- */
-
-/**
- * Add the analytics javascript callback to the list for on acceptance
- */
-function cookie_googleanalytics_cookieaccept_alter(&$callbacks) {
- $callbacks[] = 'ccAddAnalytics();';
-}
-
-/**
- * Add the analytics javascript callback to the list for already consenting visitors
- */
-function cookie_googleanalytics_cookiesallowed_alter(&$callbacks) {
- $callbacks[] = 'ccAddAnalytics();';
-}
-
-/**
- * Remove the standard Google Analytics code from the header and place in
- * a function which can be called manually when appropriate
- */
-function cookie_googleanalytics_js_alter(&$javascript) {
- // Find the Google Analytics code. Wish there was a better keyed way to find the code :-(
- foreach($javascript as $key => $script) {
- if (is_string($script['data']) && strpos($script['data'], '/ga.js') > 0) {
-
- // Wrap code in a callback function
- $script = "function ccAddAnalytics() {\n" . $script['data'] . "\n}";
-
- // Substitue the original script snippet with our function wrapped version
- $javascript[$key]['data'] = $script;
- }
- }
-}
cc.setCookie('ccShowCookieIcon', 'no');jQuery('#ccc-icon').hide();
ccAddHtmlClass();
}
//-->
Commenti
Ser P - Alessan...
Sab, 01/13/2018 - 13:06
Collegamento permanente
I miei voti sono:
***La famiglia
**Siebenburger (o qualcosa del genere)
*Superantieroi
Sa_Jana
Sab, 01/13/2018 - 14:48
Collegamento permanente
voti
Superantieroi***
Siebenbürgen**
Lafamiglia*
Gana Mala
Sab, 01/13/2018 - 15:39
Collegamento permanente
Voti
Questa volta è molto difficile, ci sono diversi parimerito, ma:
*** Evilly ever after: e vissero sempre malvagi e cruenti
** Siebenburger
* la famiglia
Ne ho apprezzato altri, mi dispiace non potervi dare le mie stelline, questo gioco ha partorito molte cose belle. Bravi tutti.
quatipua
Sab, 01/13/2018 - 16:15
Collegamento permanente
Voti
La famiglia (MasMas) ***
Siebenbürgen (Grilloz) **
Nella vecchia fattoria (EntulaPili) *
Menzione speciale per Superantieroi (Pilgrimax) e Anche a te e famiglia (Sa Jana): posso dar loro i miei ### ?
asterischi *** per i voti
cancelletti ### per le menzioni speciali
capitani, posso?
poi avrei una proposta:
lo farete un giorno un gioco per quelli che non ci arrivano a scrivere un racconto a forma di racconto, ma hanno idee molte?
un gioco in cui si gioca tutto il "prima di"?
Ser P - Alessan...
Sab, 01/13/2018 - 17:48
Collegamento permanente
Mica ho capito cosa intendi.
Mica ho capito cosa intendi.
quatipua
Sab, 01/13/2018 - 18:08
Collegamento permanente
ah ah ah
vediamo se i Capitani mi hanno capita
loro malgrado mi conoscono da qualche annetto e magari riusciranno a cogliere il nocciolo della mia proposta e tradurla
:)
LaPiccolaVolante
Dom, 01/14/2018 - 14:31
Collegamento permanente
heheh... capito. Ma no, non
heheh... capito. Ma no, non credo. hihi non potremmo allontanarci ulteriormente dal fine per cui è nato il laboratorio. Cercare storie nuove e formare nuovi autori. Serve per tirare fuori prodotti concreti da sviluppare, a cercar le idee delle idee della cosa che potrà essere sviluppata non tiriamo su il calzino! hihi
Sa_Jana
Sab, 01/13/2018 - 18:21
Collegamento permanente
Facciamo i romanzi a puntate?
Facciamo i romanzi a puntate? I feulletons di LPV?
LaPiccolaVolante
Dom, 01/14/2018 - 14:41
Collegamento permanente
L'utilizzo del laboratorio e
L'utilizzo del laboratorio e dei giochi per lo studio di personaggi o contesti, utilizzati e riutilizzati per numerosi giochi, o ripescati da giochi cronologicamente lontani, è già in uso, qui sul laboratorio.
man mano che giocherete vi accorgerete che alcuni personaggi ricompaiono da giochi passati nelle arene in atto. Molti sfruttano i giochi per aggiustare un personaggio, testarlo, provare una traccia, un bivio, spesso anche durante al stesura di testi che sono destinati al catalogo.
Questo costringe il cantastorie a rispettare il precedente background del personaggio conferendo al racconto l'aspetto di un "secondo episodio".
Alla lunga questo aspetto del Lab.LPV vi sarà chiaro. :)
Poi ci sono anche i giochi a tappe. Ricompariranno anche quelli.
Pilgrimax
Sab, 01/13/2018 - 16:35
Collegamento permanente
Voti
Siebenbürgen***
La famiglia**
Evilly ever after: e vissero sempre malvagi e cruenti*
Come già sottolineato da altri, questa volta è stato proprio difficile votare. Menzione speciale per “Anche a te e famiglia” e a seguire “Nella vecchia fattoria”
Sa_Jana
Sab, 01/13/2018 - 18:20
Collegamento permanente
Se si possono fare le
Se si possono fare le menzioni io lo faccio con La vecchia fattoria e La città dei valvassini. Confesso che per me quelli votati sono a pari merito, ho assegnato in base a personalissimi impatti emotivi.
Edera82
Dom, 01/14/2018 - 01:04
Collegamento permanente
Voti
Siebenbürgen ***
Evilly ever after **
Anche a te e famiglia *
masmas
Ven, 01/19/2018 - 11:05
Collegamento permanente
Rivoto meglio
Superantieroi ***
Evilly ever after **
Anche a te e famiglia *
Seme Nero
Ven, 01/19/2018 - 18:03
Collegamento permanente
Voto
Siebenbürgen ***
Superantieroi **
La famiglia *
Bellissima prova, questa, ho letto tanti personaggi interessanti :)