You are here: Re: Quick Poll: PHP 4 / 5 « PHP « IT news, forums, messages
Re: Quick Poll: PHP 4 / 5

Posted by Oliver Gr�tz on 09/14/05 04:29

I've changed to PHP5 and not experienced any problems with old code. In
fact, the differences and incompatibilities are very minor and most
projects should work without any changes.

PHP5 features the new Zend Engine 2. It's not yet really faster than the
one in PHP4 but has large potential. Without going into further details:
It's better, especially if one wants to go with objects and classes.

PHP5 features SQLite. Of course you can install the PECL module and use
SQLite with PHP4 but some features like the iterators aren't available
in PHP4. As an example:

$db=new SQLiteDatabase('mydb.db');
foreach (
$db->query('SELECT * FROM adresses WHERE city="Sin City"')
as $adress)
{
echo $adress['name'];
}

That's simpler than in any PHP4/MySQL implementation. SQLite stores the
database in a single file, there's no need for a server (like with
MySQL). This makes it ideal for small quick and dirty projects or
machines with old CPU and s small amount of RAM.

Furthermore, PHP5.1 will introduce PDO which unifies this database
interface for all db systems. It's a native database abstraction layer.

You see, even if you don't want to use the OOP features like classes,
interfaces and iterators you can still benefit from them in the standard
modules.


AllOlli
____________
Coffee anyone? :-Q

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация