PHP Tarsier

Thursday, October 05, 2006

Thoughts on phptarsier

I will be working more on phptarsier to offer more functionalities that mimics some of rails functionality. I have been fascinated with rails features.


One of the greatest advantages of Rails framework is because it it built using Ruby. It is, for me, a great work of art in software.


Why not use Ruby then?


Most of the legacy projects were PHP-based and it might not be a good idea for all of them to be re-written in Rails. There would always be a market for PHP, i think. PHP has its place in Web Development.


My idea is to develop a PHP framework that would give me some functionalities that Rails could offer. Just a thought though.

Tuesday, January 31, 2006

How ActiveRecord works in phptarsier

This article simply tells the common and differences of the implementation for ActiveRecord in phptarsier and other frameworks.

http://community.devpinoy.org/blogs/jbeduya/archive/2006/01/30/1182.aspx

Sunday, January 29, 2006

phptarsier
A Development Framework

phptarsier.about

Welcome to phptarsier!

This is a quick overview on how phptarsier framework works. You will be guided through the features as well as the structure for the framework. The information presented within this guide might not be enough for you to get started. You may want to look at Ruby on Rails as a reference. I really tried to make this framework to look like Ruby on Rails.


As a developer, I really appreciate Ruby as a language and Rails as a framework. It gives you an idea that you can improve what you do everyday and I think that is what it give to its developers. As a PHP Developer for quite sometime, I could see how easy it is to develop an application within the Ruby on Rails environment compared to the old-style development under PHP.

But there must be a reason or reasons behind why not everybody would just jump into something great. For me, one of the factors that I have considered and is really an impact for me is its speed. As a web developer, I really want my application to be fast so users won't have wait for sometime while clicking just a single link. And PHP does best with speed, although the symantics for PHP might not be a very well suited to produce such kind of library but I try to make the simplest possible way for it to work.

I tried to look at Rails and I created something that looks like it and I named it "phptarsier". A small framework that gives the basic functionality of a Model View Controller (MVC). Right now I have implemented the basic functionalities for the framework and created a blog sample along with its 0.1.0 release. You can check it out at SourceForge.

phptarsier.structure

The framework has the following structure:

- app
- controllers
- helpers
- models
- views
- default
- layouts
- docs
- config
- lib
- eyes
- actionpack
- activerecord
- tarsier
- public
- css
- img
- js
- scripts
For some developers who are not yet familiar with the structure, I am afraid that I may not be able to discuss this in detail as of now. You can still look for more reference at the Rails site.


phptarsier.structure.app


The app folder contains several folders, namely: controllers, helpers, models, and views. This folder is the heart of your application.
You will be coding within this folder.

  • controllers - contains all of the application controllers. Controller will handle most of your application operations.

  • helpers - are classes/functions that can help with the controller. Maybe that is why it's called helper. :) As of 0.1.0, this is not yet implemented.

  • models - are representation of your database connection. Every table in your database will require a model if you wanted to do something with it.

  • views - contains the rendering for your application. Contains html codes, usually.


phptarsier.structure.config

You will be needing to edit the files within this folder. For database connections, edit config.php and router.php for routing configuration. These are the only files that you need to edit for you to get started. Never mind all the other folders not mentioned for now.

Get the sample blog and experiment with it. You can make questions, comments, suggestions and/or feature request at jbeduya@gmail.com. I don't accept solicitations though but I accept donations. :) Have a nice php coding.

Monday, January 23, 2006

PHP Tarsier Development

Things to do:

* finalize the implementation of activerecord
* finalize the routing and action controller
* implement ajax for html tags
* implemented has_and_belongs_to_many for ActiveRecord
* add GNU Public License agreement
* implement render_partial_collection functionality