Share » Forums » Developer » Transaction in php script?

Transaction in php script?

Transaction in php script?

Wednesday 26 July 2006 3:27:47 am - 2 replies

Author Message

Igor Vrdoljak

Wednesday 26 July 2006 4:31:43 am

This seems to work:

$db =& eZDB::instance();
$db->begin();

..
.. your code here
..

$db->commit();

http://www.netgen.hr/eng
http://twitter.com/ivrdoljak

Ɓukasz Serwatka

Wednesday 26 July 2006 4:32:27 am

Hi Igor,

Using eZ publish DB library (ezdb) you can use it like:

include_once( "lib/ezdb/classes/ezdb.php" );

$db =& eZDB::instance();
$db->begin();

//rest PHP code goes here

$db->commit();

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu