save() public method

public save ( $name, $value )
Beispiel #1
0
 /**
  * Saves a processed upgrade to a dataset.
  *
  * @param string $upgrade Filename of the processed upgrade
  *                        (not the path, just the file)
  * @return bool
  */
 protected function setProcessedUpgrade($upgrade)
 {
     $processed_upgrades = $this->getProcessedUpgrades();
     $processed_upgrades[] = $upgrade;
     $processed_upgrades = array_unique($processed_upgrades);
     return $this->config->save('processed_upgrades', $processed_upgrades);
 }
Beispiel #2
0
 /**
  * Deletes all cached views in the simplecache and sets the lastcache and
  * lastupdate time to 0 for every valid viewtype.
  *
  * @return bool
  */
 function invalidate()
 {
     _elgg_rmdir($this->getPath(), true);
     $time = time();
     $this->config->save("simplecache_lastupdate", $time);
     $this->config->set('lastcache', $time);
     return true;
 }
Beispiel #3
0
 /**
  * Disables the system disk cache.
  *
  * Uses the 'system_cache_enabled' config with a boolean value.
  * Resets the system cache.
  *
  * @return void
  */
 function disable()
 {
     $this->config->save('system_cache_enabled', 0);
     $this->reset();
 }