PHP Object Generator

Siječanj 14, 2006

As a PHP developer, I often find it really annoying and tiresome to write similar database access code and SQL queries for each project I develop. OO helps, but when you work on two entirely different projects which demand different objects, you still have to write separate classes with the same tiresome code.

So, one day, while surfing the web, I found a web app written by some people who were annoyed by the same things, called PHP Object Generator. You enter the object name and its attributes in the app interface (actually, the attributes are your database fields) and the app generates the class with all the common SQL queries (commonly referred as "CRUD" – Create, Retrieve, Update, and Delete) and the SQL code needed to create the database table for your object. Pretty useful, I think.
While this isn't the complete solution for all your programming needs, it's still handy when dealing with some common DB things. And it's easy to use, too – the site has some neat tutorials and there's even a Google Group dedicated to the app. With a few tweaks here and there, the code generated by this little program can write most of your DB-related code for you and you can concentrate on the fun stuff instead :).

At the time of writing, the beta of the 1.6 version is available, and it introduces some neat features, like the setup script (which automatically creates the database for you and does some testing), more consistent naming scheme, "LIMIT" support (altough this one was easy to add even in the old version) and even scaffolding.

The authors point that they aren't planning on turning the PHP Object Generator into a PHP framework, and I sure hope they won't, because there are many PHP frameworks out there, but I don't know of any tool similar to POG. Try it, it's worth a shot :).

Odgovori

Popunite niže tražene podatke ili kliknite na neku od ikona za prijavu:

WordPress.com Logo

Ovaj komentar pišete koristeći vaš WordPress.com račun. Odjava / Izmijeni )

Twitter picture

Ovaj komentar pišete koristeći vaš Twitter račun. Odjava / Izmijeni )

Facebook slika

Ovaj komentar pišete koristeći vaš Facebook račun. Odjava / Izmijeni )

Google+ photo

Ovaj komentar pišete koristeći vaš Google+ račun. Odjava / Izmijeni )

Spajanje na %s

%d bloggers like this: