[eluser]xwero[/eluser]
You don't need multiple CI installations but 2 applications. The way i would do it is to create a codeigniter directory above the public and secure root. put the system and 2 application directories in the codeigniter directory. Name the application directories public and secure. and in the bootstrap files the system directory links to the codigniter/system directory and the application directories are added in relation to the directory the bootstrap file is in.
From that time on you can create your applications accordingly. If you are only going to use the secure application for a few pages you will have only one controller.
I guess you are going to share quite a few things between the public and secure site because the pages should have a consistent layout and use the same data. This will require some hacks as CI doesn't supports flexible paths.
For views that you put in the added system/views directory you can temporarily switch the path using following methods put in the MY_Loader.php file in both application directories (it should be in the system directory as well but again it due to the non flexible file paths)
Code:
class MY_Loader extends CI_Loader
{
var _prev_ci_view_path = '';
function set_view_path($path)
{
if(is_dir($path))
{
$this->_prev_ci_view_path = $this->_ci_view_path;
$this->_ci_view_path = $path;
}
}
function reset_view_path()
{
if($this->_prev_ci_view_path != '')
{
$this->_ci_view_path = $this->_prev_ci_view_path;
$this->_prev_ci_view_path = '';
}
}
}
// usage
$this->load->set_view_path(BASEPATH.'views/');
$this->load->view('someview');
$this->load->reset_view_path();
If you want this to work in php4 you have to add an hack in the system/codeigniter/CodeIgniter.php file. Look for the hack on the forum; extend loader php4, will get you to the post i think.
For the data you can create a shared model in the added system/models directory where you put the methods needed by the secure and public part of your site and include it in the child models in the application directories.
I hope this will set you on your way