Published on 2006-11-29 23:44:32
Answer to the Race Conditions with Ajax and PHP Sessions, AJAX Locking is a PHP class which can be used to lock server side resources to prevent race conditions that may occur when two users want to access the same resource simultaneously. It uses AJAX to lock and unlock resources from Javascript code running on the browser, thus without reloading the current page.
The package comes with several drivers that can use different containers to manage the resource lock information. Currently it supports two drivers for SQL databases and shared memory as containers. You can get the alpha version 0.2.0 from Fabio's PEAR Channel :
pear install pear.ambrosanio.com/AJAX_Locking-alpha
Member of the PHP Magazine Network, Copyright (C) 2005-2008 phpmagazine.net All Rights Reserved