Benvenuto,
Ospite
|
|
Try this ...
static function filterText($text) { if ( strpos( $text, '{lang' ) === false ) return $text; //<Des>// Correction mangled closing tags $sh_this = array("{/lang ...", "{/lan ...", "{/la ...", "{/l ...", "{/ ...", "{ ..."); $text = str_replace($sh_this, "{/lang} ...", $text); //<Des>//Correction crumpled opening tag $sh_this = array("{lang ...", "{lang ...", "{lan ...", "{la ...", "{l ..."); $text = str_replace($sh_this, " ...", $text); //<Des>// Adding redundant closing tags for all the lost $text = str_replace(" ...", "{/lang} ...", $text); $lang_code = plgSystemEasyLanguage::getLagnCode(); $regex = "#{lang ".$lang_code."}(.*?){\/lang}#is"; $text = preg_replace($regex,'$1', $text); $regex = "#{lang [^}]+}.*?({\/lang}|\s\.\.\.)#is"; $text = preg_replace($regex,'', $text); //<Des>// Removal of the remaining redundant tags $sh_this = array("{lang ...","{/lang} ..."); $text = str_replace($sh_this, " ...", $text); return $text; } ![]() |
L\'Amministratore ha disattivato l\'accesso in scrittura al pubblico.
I seguenti utenti ringraziano:: Antonio
|
|
Thanks Des for your contribution, now we verify and will add it in the next release of Easy Language
|
If you like, if it was useful, consider a donation, Thanks
Se vuoi, se ti siamo stati utili, considera una donazione, Grazie Help us by voting our extensions on Joomla.org: JiFile JoomPhoto Mobile Easy Language
L\'Amministratore ha disattivato l\'accesso in scrittura al pubblico.
|
Facendo click su qualunque link della pagina si accetta il loro utilizzo. Per saperne di piu'