Vorlage:Target: Unterschied zwischen den Versionen

Aus Afterbuy-Wiki
Wechseln zu:Navigation, Suche
Zeile 5: Zeile 5:
 
   unset($parts[0],$parts[1]);
 
   unset($parts[0],$parts[1]);
 
   $stepnumber=1;
 
   $stepnumber=1;
   $steps="";
+
   $steps=[];
 
   foreach($parts as $steptext){
 
   foreach($parts as $steptext){
 
       if(trim($steptext)!=""){
 
       if(trim($steptext)!=""){
         $steps.='>>'.$stepnumber.'::'.trim($steptext).chr(10);         
+
         $steps[$stepnumber]=trim($steptext);         
 
         $stepnumber++;
 
         $stepnumber++;
 
       }
 
       }
Zeile 14: Zeile 14:
 
   if($headline!='' && $steps!=''){
 
   if($headline!='' && $steps!=''){
 
       echo '<div class="h6">'.$headline.'</div>';
 
       echo '<div class="h6">'.$headline.'</div>';
       echo '{{Steps|'.$steps.'}}';
+
       foreach($steps as $number=>$step){
      echo $steps;
+
        if(trim($step)!=""){
 +
  $out='<tr class="border-bottom mb-2 pb-2"><td width="1%" class="p-3 m-3" valign="top"><span class="fa-stack fa-lg" style="color:#edb800"><span class="fa fa-circle fa-stack-2x" style="color:#edb800"></span><strong class="fa-stack-1x" style="color:white;font-size:20px;">'.intval($number).'</strong></span></td><td>';
 +
  $out.=trim($step).'</td></tr>';
 +
  echo $out;
 +
  }
 +
}
 
   }
 
   }
 
}
 
}
 
</phptag>
 
</phptag>

Version vom 19. November 2021, 08:58 Uhr