Framework directory

How much of the /framework/ directory is required when deploying an application?

Is the entire directory required? or only parts of it?

Thanks!

Depends on how much features you use. If you don’t create a console application, you could delete the “console” folder for example.

You may insert var_dump(get_included_files()); as the last line in your entry-script. Then you get an idea of what’s unnecessary for your application.

It’s better to include everything. Is there a reason not to do it?

Size, can’t think of anything else.

Yes, it was size… however its not that big is it? The whole application including full framework is under 10mb.

If you use yiilite.php you can leave away a lot of classfiles - but not all! Some widgets also register their own js/css files. A quick grep 'class ’ yiilite.php shows, which classes you might be able to remove. But not sure if it’s really worth the effort:


class YiiBase

class Yii extends YiiBase

class CComponent

class CEvent extends CComponent

class CEnumerable

abstract class CModule extends CComponent

abstract class CApplication extends CModule

class CWebApplication extends CApplication

class CMap extends CComponent implements IteratorAggregate,ArrayAccess,Countable

class CLogger extends CComponent

abstract class CApplicationComponent extends CComponent implements IApplicationComponent

class CHttpRequest extends CApplicationComponent

class CCookieCollection extends CMap

class CUrlManager extends CApplicationComponent

class CUrlRule extends CComponent

abstract class CBaseController extends CComponent

class CController extends CBaseController

abstract class CAction extends CComponent implements IAction

class CInlineAction extends CAction

class CWebUser extends CApplicationComponent implements IWebUser

class CHttpSession extends CApplicationComponent implements IteratorAggregate,ArrayAccess,Countable

class CHtml

class CWidget extends CBaseController

class CClientScript extends CApplicationComponent

class CList extends CComponent implements IteratorAggregate,ArrayAccess,Countable

class CFilterChain extends CList

class CFilter extends CComponent implements IFilter

class CInlineFilter extends CFilter

class CAccessControlFilter extends CFilter

class CAccessRule extends CComponent

abstract class CModel extends CComponent implements IteratorAggregate, ArrayAccess

abstract class CActiveRecord extends CModel

class CBaseActiveRelation extends CComponent

class CStatRelation extends CBaseActiveRelation

class CActiveRelation extends CBaseActiveRelation

class CBelongsToRelation extends CActiveRelation

class CHasOneRelation extends CActiveRelation

class CHasManyRelation extends CActiveRelation

class CManyManyRelation extends CHasManyRelation

class CActiveRecordMetaData

class CDbConnection extends CApplicationComponent

abstract class CDbSchema extends CComponent

class CSqliteSchema extends CDbSchema

class CDbTableSchema extends CComponent

class CDbCommand extends CComponent

class CDbColumnSchema extends CComponent

class CSqliteColumnSchema extends CDbColumnSchema