Welcome Guest, Not a member yet? Register   Sign In
Phil Sturgeon's Template Library with Theme Issue
#1

[eluser]xtremer360[/eluser]
Even though PyroCMS is an excellent CMS to use and I highly recommend anybody and everybody using when the situation grants it.

However, my situation calls for a custom CMS that just has quite a bit of differences that I am instead developing mine with the use of some of the libraries I see out there that are free to use. The main one I am currently working with right now is Phil Sturgeon's Template library.

Now since obviously he uses it for PyroCMS I am trying to match up as close to a file structure as he does with that so that the template system will flow smoothly without any issues.

I am currently in a quandary right now because I have my login form is not finding a partial and I'm not quite sure why. When my dashboard calls the metadata partial it loads it up just fine but something is amidst and is not loading it when I call it in the login form.

Here is my current login controller, login form view, and the file structure to ensure it is set up properly.

Code:
<?php

if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Login extends Backend_Controller
{
    public function __construct()
    {
        parent::__construct();
    }

    public function index()
    {
        $this->template
               ->set_layout(FALSE)
               ->build('login');
    }
}

Code:
<head>

    <!-- metadata needs to load before some stuff -->
    <?php file_partial('metadata'); ?>

</head>

Code:
applications/
    themes/
        supr(my custom theme from template)/
            views/
                login.php
                partials/
                    metadata.php
#2

[eluser]xtremer360[/eluser]
Any ideas?
#3

[eluser]goFrendiAsgard[/eluser]
file_partials? do you use a library or something else?
I usually do this to show metadata

<?php echo $template['metadata'];?>




Theme © iAndrew 2016 - Forum software by © MyBB