iFrame Features

iFrame Logo

In the previous post I introduced my new PHP framework – iFrame. It had the reasons why you should not use the framework. In these post, I will talk of the advantages you get if you use my framework. But remember – do not use my framework.

No routing – Fully file based

There are no complicated routing rules – the URL should specify which file should be used. For example…

http://www.example.com/user/create.php

Here, ‘user’ is the controller and ‘create’ is the action.

Folder Structure

Like many other frameworks, iFrame has a rigid folder structure.

/
+-common.php
+-configuration.php
+-/includes/  #System files
+-index.php
+-/user/
	+-index.php
	+-create.php
+-/templates/
	+-index.php
	+-/user/
		+-index.php
		+--create.php
+-/js/
	+-/user/
		+--create.js
+-/css/
	+-/user/
		+--create.css

Auto inclusion of CSS/JS files

The system will auto include the CSS/JS files with the same file name as the current file – the files highlighted in the above ‘Folder Structure’ will be included automatically when ever the create.php file is called.

Library for Paging/Tagging

These two classes are great time savers. Unfortunatly they have no documentation – yet.

Small/Manageable Files

The framework forces the code to be broken down into smaller parts. In this framework, one action is one file – instead of one controller per file as in other frameworks. I find this easier to manage than the other approch.

Uses OOPs only when it is required

I only use Object Oriented Programming only if there is a clear need to use it. This step made the system much simpler.

Three Layers

This framework tries to follow both MVC(server side 3 layer) and Content/Behavior/Presentation(client side 3 layer) approaches.