MySQL transactions examples in PHP

17. May 2013

MySQL transactions examples in PHP

 

 http://stackoverflow.com/questions/2708237/php-mysql-transactions-examples

mysql_query("SET AUTOCOMMIT=0");
mysql_query("START TRANSACTION");
$a1 = mysql_query("INSERT INTO rarara (l_id) VALUES('1')");
$a2 = mysql_query("INSERT INTO rarara (l_id) VALUES('2')");
if ($a1 and $a2)
{ 
mysql_query("COMMIT"); 
} 
else
{
mysql_query("ROLLBACK"); 
}

MySQL, PHP , ,

How to run php website on IIS 7 with ASP.NET website simultaneously

7. April 2013

How to run php website on IIS 7 with ASP.NET website simultaneously

The process to do this is ( i suppose that IIS 7 is currently working and serving a ASP.NET website ) install php from microsoft web platfom installer ( you can get that here - http://www.microsoft.com/web/downloads/platform.aspx ) it will automatically install the dependencies .

Now php is installed and we will have to install CGI from control panel -> Program and Features - > Turn windows features ON or OFF

and check CGI features as shown in picture

 

 

Now simply add a new website in IIS with default app pool and your site is up and running with php installed .

 

 

IIS