![](http://g.hiphotos.bdimg.com/album/s%3D1100%3Bq%3D90/sign=67e7a62cc2cec3fd8f3ea374e6b8ef4e/8644ebf81a4c510f070cb9fa6159252dd52aa502.jpg?v=tbs)
我的代码:
<?php
error_reporting(0);
include("inc.php");
$conn = mysql_connect($servername,$username,$password);
$okdatabase = mysql_select_db($dbname);
$sql="SELECT * FROM advertisement ORDER BY id DESC LIMIT 1";
$result=mysql_query($sql,$conn);
while ($row=mysql_fetch_array($result)) {
$b="./advertisement/". $row[2];
echo"$b";
echo"<img src= '$b' width='1400' height='280'>";
}
?>
<?php
error_reporting(0);
include("inc.php");
$conn = mysql_connect($servername,$username,$password);
$okdatabase = mysql_select_db($dbname);
$sql="SELECT * FROM advertisement ORDER BY id DESC LIMIT 1";
$result=mysql_query($sql,$conn);
while ($row=mysql_fetch_array($result)) {
$b="./advertisement/". $row[2];
echo"$b";
echo"<img src= '$b' width='1400' height='280'>";
}
?>