PHP code example of slaxweb / ci-viewloader

1. Go to this page and download the library: Download slaxweb/ci-viewloader library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

slaxweb / ci-viewloader example snippets


$viewLoader = new \SlaxWeb\ViewLoader\Load($this);

$viewLoader->loadView("view/file")

$viewLoader->setHeaderView("header/file");
$viewLoader->setFooterView("footer/file");
$viewLoader->loadView("view/file", $dataArray);

$viewLoader->loadView("view/file", $dataArray, false);

$this->lang->load("languageFile");
$viewLoader->setLanguageStrings("prefix_");
$viewLoader->loadView("view/file", $dataArray);