~yoboy-leguesh/ubuntu-fr-doc/maj20150810a

« back to all changes in this revision

Viewing changes to inc/cache.php

  • Committer: YoBoY
  • Date: 2012-10-24 19:05:18 UTC
  • mfrom: (114.1.3 maj-AdoraBelle)
  • Revision ID: yoboy.leguesh@gmail.com-20121024190518-bgtic5m3dt8gnzfn
Mise à jour de Dokuwiki 2012-10-13 "Adora Belle"
Application des patch ubuntu-fr d'optimisation
Ajout des thèmes ubuntu-fr
Ajout des plugins
Mise à jour des plugins box, orphanswanted, pageredirect, tag, cloud, forcepreview, pagelist
Désactivation de la nouvelle option d'envoie de notifications mail en html
Application des derniers patchs correctifs de Dokuwiki.

Show diffs side-by-side

added added

removed removed

Lines of Context:
69
69
 
70
70
        if (!empty($this->depends['files'])) {
71
71
            foreach ($this->depends['files'] as $file) {
72
 
                if ($this->_time < @filemtime($file)) return false;         // cache older than files it depends on?
 
72
                if ($this->_time <= @filemtime($file)) return false;         // cache older than files it depends on?
73
73
            }
74
74
        }
75
75
 
84
84
     * it should only overwrite a dependency when the new value is more stringent than the old
85
85
     */
86
86
    function _addDependencies() {
87
 
        if (isset($_REQUEST['purge'])) $this->depends['purge'] = true;   // purge requested
 
87
        global $INPUT;
 
88
        if ($INPUT->has('purge')) $this->depends['purge'] = true;   // purge requested
88
89
    }
89
90
 
90
91
    /**
206
207
            return true;
207
208
        }
208
209
 
 
210
        if ($this->_time < @filemtime(metaFN($this->page,'.meta'))) return false;         // meta cache older than file it depends on?
 
211
 
209
212
        // check current link existence is consistent with cache version
210
213
        // first check the purgefile
211
214
        // - if the cache is more recent than the purgefile we know no links can have been updated
238
241
        // page implies metadata and possibly some other dependencies
239
242
        if (isset($this->page)) {
240
243
 
241
 
            $metafile = metaFN($this->page,'.meta');
242
 
            $files[] = $metafile;                                       // ... the page's own metadata
243
 
 
244
244
            $valid = p_get_metadata($this->page, 'date valid');         // for xhtml this will render the metadata if needed
245
245
            if (!empty($valid['age'])) {
246
246
                $this->depends['age'] = isset($this->depends['age']) ?