[eluser]bjuneau[/eluser]
[quote author="pickupman" date="1355099088"]Read the [url="http://ellislab.com/codeigniter/user-guide/general/routing.html"]URI routing[/url] from the user guide. CI doesn't work necessary by static php/html files that it seems what you are trying to do.
You will need to stop thinking of pages in that way. You don't "add" pages. Controllers are what handles the logic for displaying pages. The Controller as described in the link above, is the first part of your url. You can have a Pages controller. So a url would look like example.com/index.php/pages. This link will load the Pages controller and execute the index() method when found. Taking this thinking. if you have a Pages controller with an about() method would like example.com/index.php/pages/about.[/quote]
Right, I think the AG Auth config was throwing me off. I wasn't trying to hit a static page but rather load a view into my template. I basically just created another controller to handle the other views.
Code:
<?php
class Pages extends Application
{
public function __construct()
{
parent::__construct();
}
public function about()
{
if(logged_in())
{
$this->ag_auth->view('about');
}
else
{
$this->login();
}
}
}
Now since everything in this controller will require login and I already have AG Auth working... Is there a prettier way to verify "if(logged_in()) for all functions for a particular controller?