Vorlage:AB: Unterschied zwischen den Versionen

Aus Afterbuy-Wiki
Wechseln zu:Navigation, Suche
 
Zeile 1: Zeile 1:
 
<phptag>
 
<phptag>
 
$quotes=array('„','“',"'",'"','”');
 
$quotes=array('„','“',"'",'"','”');
 +
 +
$needles=array("(?)","(+)","(-)");
 +
$replace=array('<html>&nbsp;<span style="color:#547392;"><i class="fas fa-question-circle"></i></span>&nbsp;</html>',
 +
  '<html>&nbsp;<span style="color:#333;"><i class="fas fa-plus"></i></span>&nbsp;</html>',
 +
  '<html>&nbsp;<span style="color:#333;"><i class="fas fa-minus"></i></span>&nbsp;</html>'
 +
);
 +
 
if(is_array($argv) && !empty($argv)){
 
if(is_array($argv) && !empty($argv)){
 
array_shift($argv);
 
array_shift($argv);
Zeile 11: Zeile 18:
 
           $content=str_replace($quotes,'',trim($argv[1]));
 
           $content=str_replace($quotes,'',trim($argv[1]));
 
         }
 
         }
         $content=str_replace('(?)','<html>&nbsp;<span style="color:#547392;"><i class="fas fa-question-circle"></i></span>&nbsp;</html>',$content);
+
         $content=str_replace($needles,$replace,$content);
 
         echo '<html><span class="'.$class.'"></html>'.$content.'<html></span></html>';
 
         echo '<html><span class="'.$class.'"></html>'.$content.'<html></span></html>';
 
}
 
}
 
</phptag>
 
</phptag>

Aktuelle Version vom 12. November 2021, 09:20 Uhr

Afterbuy-Element