Download & Extend

Splash turning off doesn't turn off

Project:Splash
Version:6.x-2.7
Component:User interface
Category:support request
Priority:normal
Assigned:Unassigned
Status:needs review

Issue Summary

I set the module to turn off but the splash window continues to open

Comments

#1

Do you have caching turned on? Try flushing the cache and testing again.

#2

Status:active» fixed

Going to assume that was it. If not, please reopen with more info.

#3

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

#4

Status:closed (fixed)» active

In my opinion, this is an existing and valid bug with Splash 6.x-2.5. I've witnessed this behavior on two sites. Steps are essentially:

-- enable splash module
-- set the "what"/"how" to display a static chunk of HTML (pasted into the config field)
-- set the "when" to once a week or once a session
-- splash page starts appearing for new visitors (redirected to domainname.com/splash)
-- set the "when" to "never" (in my cases a couple weeks later)
-- splash page continues to appear for new visitors (again, redirected to domainname.com/splash)

On the most recent site, Drupal caching is turned on ("normal"), with page compression and block cache enabled, css optimization disabled and javascript optimization enabled.

I have not investigated to try to figure out the mechanism. I did try flushing caches with the button on the Performance settings page: that did not seem to have any effect. Workaround in my case is to disable the module.

#5

Version:6.x-2.3» 6.x-2.5

It looks like the culprit might the frequency logic of the splash.module.

starting at 102:

// Frequency
if ($splash) {

// No cookie
if (!$cookie_data['time']) {
$splash = TRUE;

} else {
 
  // Once
  if ($splash_when['frequency'] == 'once') {
  $splash = FALSE;

  // Every day
  } else if ($cookie_data['time'] && $splash_when['frequency'] == 'daily' && (time() - $cookie_data['time'] < 86400)) {
  $splash = FALSE;
 
  // Every week
  } else if ($cookie_data['time'] && $splash_when['frequency'] == 'weekly' && (time() - $cookie_data['time'] < 604800)) {
  $splash = FALSE;
 
  // Never
  } else if ($splash_when['frequency'] != 'always') {
  $splash = FALSE;
  }
  }
  }

Before it does any checking for the frequency, it checks to see if there is a cookie, and if not sets splash to display and ignores the rest of the frequency logic.

Not sure yet what the best logic for this section of code would be...

#6

This patch should fix it. Can you give it a try?

AttachmentSize
splash.module.patch 734 bytes

#7

Status:active» needs review

Same issue, but the patch isn't working for me. IMHO 'never' should be all inclusive, whether there is a cookie or not.

AttachmentSize
splash_never-means-never_320067.patch 3.1 KB

#8

Same problem in 2.6 and 2.7. Never means off.

#9

Version:6.x-2.5» 6.x-2.7

Ah, right - sorry - i missed changing the version number. Should have done against -dev too, but looks like this applies.