Changeset 95279 in spip-zone


Ignore:
Timestamp:
Feb 20, 2016, 8:39:35 PM (4 years ago)
Author:
fil@…
Message:

demander le reload du contenu (?var_mode=reload)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • _plugins_/ressource/inc/ressource.php

    r95278 r95279  
    236236        if (isset($meta['extension']))
    237237                $meta['type_document'] = ressource_mime($meta['extension']);
     238
     239        // demander le reload du contenu (?var_mode=reload)
     240        if (_request('var_mode') == 'reload' && autoriser('reload', 'distant')) {
     241                include_spip('inc/queue');
     242                queue_add_job('copie_locale', 'copier', array($src, 'force'), $file = 'inc/distant', $no_duplicate = true, $time=1, $priority=0);
     243        }
    238244
    239245        return $meta;
Note: See TracChangeset for help on using the changeset viewer.