Easiest in the world PHP command get PHP how to return multi-record or multi-variable.
Create your own web site information, create domain, web host register, web programing, web promotion, e-commerce and example yahoo domain. Give our gift if you like just access link you like. Professional ERP, Open ERP, Odoo
New Hosting
ads auto
Monday, June 28, 2010
Saturday, June 26, 2010
How to check SQL script PHP code error
How to check SQL script PHP code error, which we able to use echo to do this advantage.
instance:
echo $sql;
instance:
echo $sql;
Tuesday, June 22, 2010
Sunday, June 20, 2010
Limitation of header clause in PHP
Example:
...
if(a=b)
{
...
}
else
{
...
header("Location: admin_home.php");
}
?>
header need located at last clause of php code:
must not have space and other command
...
if(a=b)
{
...
}
else
{
...
header("Location: admin_home.php");
}
?>
header need located at last clause of php code:
must not have space and other command
Saturday, June 19, 2010
php where Clause
Pattern:
SELECT column_name(s)
FROM table_name
WHERE column_name operator value
PHP code Example:
$myquery= mysql_query("SELECT * FROM Persons
WHERE FirstName='John' ");
$result=mysql_query($myquery);
if(!$result)
{
$error = "Query fail!";
return($error);
}
Where Clause with variable
$myquery ="select * from userdb where user = '".$myuser."' and usepw= '".$mepw."' ";
this clause specific 2 variables those are:
$myuser => ' " .$myuser. " '
$mepw => ' " .$mepw. " '
Please Note: ' " .$myuser. " ' => must no space => should be '".$myuser."'
SELECT column_name(s)
FROM table_name
WHERE column_name operator value
PHP code Example:
$myquery= mysql_query("SELECT * FROM Persons
WHERE FirstName='John' ");
$result=mysql_query($myquery);
if(!$result)
{
$error = "Query fail!";
return($error);
}
Where Clause with variable
$myquery ="select * from userdb where user = '".$myuser."' and usepw= '".$mepw."' ";
this clause specific 2 variables those are:
$myuser => ' " .$myuser. " '
$mepw => ' " .$mepw. " '
Please Note: ' " .$myuser. " ' => must no space => should be '".$myuser."'
PHP Correct Web Date time
PHP code fix problem regarding time not correct
$metime = date("Y-m-d H:i:s", strtotime("+5 hours"));
PHP Check Server Time Zone
echo date_default_timezone_get();;
$metime = date("Y-m-d H:i:s", strtotime("+5 hours"));
PHP Check Server Time Zone
echo date_default_timezone_get();;
Subscribe to:
Posts (Atom)