[pmwiki-devel] OFF-TOPIC - PHP/MySQL app example

Petko Yotov 5ko at 5ko.fr
Sat Jan 31 06:16:10 CST 2009


On Saturday 31 January 2009 12:52:44 Peter Bowers wrote:
> Apologies for the off-topic post, but you guys here are the most
> knowledgeable people I know about PHP development...
>
> I'm just starting to get my feet wet with developing an application on a
> PHP/MySQL platform.  I've got it mostly working as a prototype, but it's
> not pretty.  I'd like to find some application that will show me elegant
> ways of accessing MySQL from PHP...
>
> Do any of you know a good open-source app I could look at to get ideas and
> patterns and etc?

For starting a new program, unless it is a very very simple one and will never 
grow larger, I can recommend the use of a PHP framework that is adapted for 
MySQL integration. See a list at Wikipedia:

  http://en.wikipedia.org/wiki/Php_framework#PHP

In the past (2006), I have tried CodeIgniter which had some excellent features 
and excellent documentation. See :

  http://en.wikipedia.org/wiki/CodeIgniter
  http://codeigniter.com/

If not a web framework, at least you should use an abstraction layer for the 
database access -- instead of the built-in functions mysql_query() and other 
mysql_*: your own sql_query() which calls mysql_query() -- to be able to 
later migrate to another database engine.

There is also phpclasses.org where you can find a number of useful snippets 
(free registration required).

Thanks,
Petko



More information about the pmwiki-devel mailing list