Changeset 31640 in spip-zone
- Timestamp:
- Sep 18, 2009, 12:28:25 PM (12 years ago)
- Location:
- _plugins_/yaml
- Files:
-
- 2 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
_plugins_/yaml/inc/yaml.php
r31565 r31640 8 8 # Regle de dev: ne pas se rendre dependant de la lib sous-jacente 9 9 10 // temporaire le temps de tester spyc 11 define('_LIB_YAML','sfyaml'); 12 #define('_LIB_YAML','spyc'); 10 13 11 14 /* … … 15 18 */ 16 19 function yaml_encode($struct, $opt = array()) { 20 // test temporaire 21 if (_LIB_YAML == 'spyc') { 22 require_once _DIR_PLUGIN_YAML.'spyc/spyc.php'; 23 return Spyc::YAMLDump($struct); 24 } 17 25 require_once _DIR_PLUGIN_YAML.'sfyaml/sfYaml.php'; 18 26 require_once _DIR_PLUGIN_YAML.'sfyaml/sfYamlDumper.php'; … … 30 38 */ 31 39 function yaml_decode($input) { 40 // test temporaire 41 if (_LIB_YAML == 'spyc') { 42 require_once _DIR_PLUGIN_YAML.'spyc/spyc.php'; 43 return Spyc::YAMLLoad($input); 44 } 32 45 require_once _DIR_PLUGIN_YAML.'sfyaml/sfYaml.php'; 33 46 require_once _DIR_PLUGIN_YAML.'sfyaml/sfYamlParser.php';
Note: See TracChangeset
for help on using the changeset viewer.