mirror of
https://github.com/claudehohl/Stikked.git
synced 2025-04-26 04:51:08 -05:00
initial themes branch commit
This commit is contained in:
parent
223882a7c5
commit
41420b2b01
@ -239,6 +239,9 @@ class Main extends CI_Controller
|
|||||||
$this->dbforge->add_key('hits_updated');
|
$this->dbforge->add_key('hits_updated');
|
||||||
$this->dbforge->add_column('pastes', $fields);
|
$this->dbforge->add_column('pastes', $fields);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//load theme
|
||||||
|
$this->load->theme('classic');
|
||||||
}
|
}
|
||||||
|
|
||||||
function _form_prep($lang = false, $title = '', $paste = '', $reply = false)
|
function _form_prep($lang = false, $title = '', $paste = '', $reply = false)
|
||||||
|
47
htdocs/application/core/MY_Loader.php
Normal file
47
htdocs/application/core/MY_Loader.php
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* Class and Function List:
|
||||||
|
* Function list:
|
||||||
|
* - __construct()
|
||||||
|
* - theme()
|
||||||
|
* - view()
|
||||||
|
* Classes list:
|
||||||
|
* - MY_Loader extends CI_Loader
|
||||||
|
*/
|
||||||
|
|
||||||
|
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||||
|
|
||||||
|
class MY_Loader extends CI_Loader
|
||||||
|
{
|
||||||
|
var $template = '';
|
||||||
|
var $data = array();
|
||||||
|
var $return = FALSE;
|
||||||
|
|
||||||
|
function __construct()
|
||||||
|
{
|
||||||
|
parent::__construct();
|
||||||
|
log_message('debug', 'MY_Loader Class Initialized');
|
||||||
|
}
|
||||||
|
|
||||||
|
function theme($template = '', $data = array() , $return = FALSE)
|
||||||
|
{
|
||||||
|
|
||||||
|
if ($template == '')
|
||||||
|
{
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
$this->template = $template;
|
||||||
|
$this->data = $this->_ci_object_to_array($data);
|
||||||
|
$this->return = $return;
|
||||||
|
}
|
||||||
|
|
||||||
|
function view($view, $vars = array() , $return = FALSE)
|
||||||
|
{
|
||||||
|
log_message('debug', 'Using view "themes/' . $this->template . '/views/' . $view . '.php"');
|
||||||
|
return $this->_ci_load(array(
|
||||||
|
'_ci_view' => '../themes/' . $this->template . '/views/' . $view . '.php',
|
||||||
|
'_ci_vars' => $this->_ci_object_to_array($vars) ,
|
||||||
|
'_ci_return' => $return
|
||||||
|
));
|
||||||
|
}
|
||||||
|
}
|
Before Width: | Height: | Size: 207 B After Width: | Height: | Size: 207 B |
Before Width: | Height: | Size: 282 B After Width: | Height: | Size: 282 B |
1
htdocs/application/themes/classic/theme.php
Normal file
1
htdocs/application/themes/classic/theme.php
Normal file
@ -0,0 +1 @@
|
|||||||
|
<?php echo $content;
|
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user