Introduction
Phundament can be used as within an application skeleton or as a module within your current application. This pages describes how to install these versions.
Details
Application
- Download & extract into /htdocs
- Run
$ ./yiic install
This will create config/local.php
- Create a database, update credentials in config/local.php
- Run
$ ./yiic install
Follow instructions
- Open home URL
Check index.php?r=p2/default/install in case of errors.
Module
- Download & extract into /htdocs/app/modules
- Merge configurations in config/main.php
return CMap::mergeArray(
include(dirname(__FILE__)."/../modules/p2/config/module.php"),
array(...current config...)
);
- Open index.php?r=p2/default/install
- Update configuration
Console Config
return array(
'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',
'name'=>'My Console Application',
'commandMap'=>array(
'p2' => 'modules/p2/commands/PiiCommand.php',
'install' => 'modules/p2/commands/InstallCommand.php',
'backup' => 'modules/p2/commands/BackupCommand.php',
'api' => 'modules/p2/commands/ApiCommand.php',
),
);Params
'languages'=>array('en_us'=>'English'),- Downlod add-ons (modules/srbac, lib/zend)
- Update LoginForm model
- change UserIdentity into P2UserIdentity
class UserIdentity extends P2UserIdentity {}- Run
$ ./yiic install
- Open home URL.
If you have any problem with the module installation, make sure you also check out the application skeleton. And take a look how thing work there.
In case you access the wrong PHP interpreter, which happens sometime on systems which have more than one PHP version installed. You can also use this:
/usr/bin/php5 -e yiic.php install