[PLUGINS] ~maj globale
[lhc/web/www.git] / www / plugins / formidable / action / exporter_formulaire.php
1 <?php
2
3 // Sécurité
4 if (!defined('_ECRIRE_INC_VERSION')) {
5 return;
6 }
7
8 function action_exporter_formulaire_dist($arg = null) {
9 include_spip('inc/formidable');
10 if (is_null($arg)) {
11 $securiser_action = charger_fonction('securiser_action', 'inc');
12 $arg = $securiser_action();
13 }
14
15 list($id_formulaire, $type_export) = preg_split('/[\W]/', $arg);
16
17 if ($id_formulaire > 0
18 and $type_export
19 and $types_echange = echanges_formulaire_lister_disponibles()
20 and $exporter = $types_echange['exporter'][$type_export]
21 ) {
22 $exporter($id_formulaire);
23 }
24 }