Suggest a feature
×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: PHP
Posted by: Gábor Papp
Added: Apr 8, 2019 3:24 AM
Views: 9
Tags: no tags
  1. if (isset($p1) and $p1) { define('P1',$p1); } else { define('P1',false); }
  2. if (isset($p2) and $p2) { define('P2',$p2); } else { define('P2',false); }
  3. if (isset($p3) and $p3) { define('P3',$p3); } else { define('P3',false); }
  4. if (isset($p4) and $p4) { define('P4',$p4); } else { define('P4',false); }
  5. if (isset($p5) and $p5) { define('P5',$p5); } else { define('P5',false); }
  6.  
  7. if (isset($p5) and $p5) { $psor='/'.$p1.'/'.$p2.'/'.$p3.'/'.$p4.'/'.$p5; }
  8. else if (isset($p4) and $p4) { $psor='/'.$p1.'/'.$p2.'/'.$p3.'/'.$p4; }
  9. else if (isset($p3) and $p3) { $psor='/'.$p1.'/'.$p2.'/'.$p3; }
  10. else if (isset($p2) and $p2) { $psor='/'.$p1.'/'.$p2; }
  11. else if (isset($p1) and $p1) { $psor='/'.$p1; }
  12. else { $psor=''; }
  13. define('PSOR',$psor);$smarty->assign("psor",PSOR);
  14.  
  15. if (isset($p5) and $p5) { $p5sor='/'.$p1.'/'.$p2.'/'.$p3.'/'.$p4.'/'.$p5; } else { $p5sor=false; } define('P5SOR',$p5sor); $smarty->assign("p5sor",P5SOR);
  16. if (isset($p4) and $p4) { $p4sor='/'.$p1.'/'.$p2.'/'.$p3.'/'.$p4; } else { $p4sor=false; } define('P4SOR',$p4sor); $smarty->assign("p4sor",P4SOR);
  17. if (isset($p3) and $p3) { $p3sor='/'.$p1.'/'.$p2.'/'.$p3; } else { $p3sor=false; } define('P3SOR',$p3sor); $smarty->assign("p3sor",P3SOR);
  18. if (isset($p2) and $p2) { $p2sor='/'.$p1.'/'.$p2; } else { $p2sor=false; } define('P2SOR',$p2sor); $smarty->assign("p2sor",P2SOR);