After applied the rules for cache for each block, for second option of cache expired (node, comment, user, login/logout) doesn't being save into database.

When I reconfigure the same block after Submit, the this option become empty and I need to re-set again. I don't know either the setting before have been save into the database or not.

*ps: does this module create a table in database?

Comments

swentel’s picture

The module doesn't create a table in the database, all is stored in the variable table. I'll have look this weekend to see if I can reproduce the problem.

parasolx’s picture

thanks for that effort. i'll wait for new patches.

swentel’s picture

Status: Active » Needs work

Ok, I tried to reproduce and the only time I manage to loose the settings is when I fill in the Cache lifetime option too. If this is not empty, it will save this value into the database, otherwhise the other values, see code excerpt underneath.

      // Remember block expire time or refresh actions for the future.
      if (!empty($form_state['values']['bc_life'])) {
        variable_set('bc_life_'. $form['module']['#value'] .'_'. $form['delta']['#value'], $form_state['values']['bc_life']);
      }
      else {
        variable_set('bc_refresh_'. $form['module']['#value'] .'_'. $form['delta']['#value'], $form_state['values']['bc_refresh']);
        variable_set('bc_relate_'. $form['module']['#value'] .'_'. $form['delta']['#value'], $form_state['values']['bc_relate']);
      }

So as far as I know, everything should work fine.

swentel’s picture

Status: Needs work » Needs review

Hmm, wrong status

parasolx’s picture

so thats mean if the cache lifetime is set for custom value, then the setting is not save in database.

while if let it by zero then it should save?

swentel’s picture

Yep, that's the catch, you can only choose either between cache lifetime OR on actions, not both.

parasolx’s picture

IC... then it should be update in manual guidance for other references

swentel’s picture

Status: Needs review » Fixed

I updated the documentation in the Drupal 6 branch for some more clarification about this and updated the project page too.

Status: Fixed » Closed (fixed)

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