Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted as PHP by Jost1 ( 14 years ago )
<?php

 class XSimpleTPL {
 
  private $outputData;
  private $params = Array();
  private $includeFiles = Array();
  
  public function Init(){
    
  }
  
  public function AddGeneric($key) {
  if (file_exists('./inc/tpl/'.$key.'.tpl')) {
  $this->params[$key] = file_get_contents&#40;'./inc/tpl/'.$key.'.tpl'&#41;;
  } else {
  $this->params[$key] = False;
  }
  }
  
  public function Output() {
   foreach ($this->params as $file) {
    if ($file !== False) {
     echo $file;
    } else {
     echo '<!-- No Existe el Archivo TPL --!>';
    }
   }
  }
    
 }
?>

 

Revise this Paste

Your Name: Code Language: