[ Index ] |
|
Code source de SPIP 1.9.2c |
1 <?php 2 3 /***************************************************************************\ 4 * SPIP, Systeme de publication pour l'internet * 5 * * 6 * Copyright (c) 2001-2007 * 7 * Arnaud Martin, Antoine Pitrou, Philippe Riviere, Emmanuel Saint-James * 8 * * 9 * Ce programme est un logiciel libre distribue sous licence GNU/GPL. * 10 * Pour plus de details voir le fichier COPYING.txt ou l'aide en ligne. * 11 \***************************************************************************/ 12 13 14 if (!defined("_ECRIRE_INC_VERSION")) return; 15 16 // Controle la presence de la lib safehtml et cree la fonction 17 // de transformation du texte qui l'exploite 18 if (@is_dir(_DIR_RESTREINT.'safehtml')) { 19 // http://doc.spip.org/@inc_safehtml_dist 20 function inc_safehtml_dist($t) { 21 static $process, $test; 22 23 if (!$test) { 24 if ($f = include_spip('safehtml/classes/safehtml', false)) { 25 define('XML_HTMLSAX3', dirname($f).'/'); 26 include($f); 27 $process = new safehtml(); 28 $process->deleteTags[] = 'param'; // sinon bug Firefox 29 } else die('pas de safe'); 30 if ($process) 31 $test = 1; # ok 32 else 33 $test = -1; # se rabattre sur interdire_scripts 34 } 35 36 if ($test > 0) { 37 # reset ($process->clear() ne vide que _xhtml...), 38 # on doit pouvoir programmer ca plus propremement 39 $process->_counter = array(); 40 $process->_stack = array(); 41 $process->_dcCounter = array(); 42 $process->_dcStack = array(); 43 $process->_listScope = 0; 44 $process->_liStack = array(); 45 # $process->parse(''); # cas particulier ? 46 $process->clear(); 47 $t = $process->parse($t); 48 } 49 50 return $t; 51 } 52 } 53 54 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Wed Nov 21 10:20:27 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |