局部wamp中未定义的常量长度错误

I have run a PHP file on Local Wamp. It gives following error,

Use of undefined constant length - assumed 'length' in C:\wamp\www\test
ewreport.php 

My coding :

<?php
echo "test success";
$con=mysql_connect("localhost", "root", "pass")or die ('I cannot connect to the database because: ' . mysql_error());
mysql_select_db("project1",$con);

$result = mysql_query("select x1, x2, x3, x4, x5, x6, time_format( x7, '%h:%i:%s %p' ) x71, x8 from newstorage") or die(mysql_error()); 
$i=0;
while($row = mysql_fetch_array($result))
        {
            $name[$i]=$row['x1'];
            $ctime[$i]=$row['x71'];
            echo $ctime[$i]."<br>"; // It prints time perfectly
            $i++;
        }
        echo $i.length;  // error occurs in this line...


?>

Please help me solve this issue..

Remove the .length :

<?php
echo "test success";
$con=mysql_connect("localhost", "root", "pass")or die ('I cannot connect to the database because: ' . mysql_error());
mysql_select_db("project1",$con);

$result = mysql_query("select x1, x2, x3, x4, x5, x6, time_format( x7, '%h:%i:%s %p' ) x71, x8 from newstorage") or die(mysql_error()); 
$i=0;
while($row = mysql_fetch_array($result))
{
  $name[$i]=$row['x1'];
  $ctime[$i]=$row['x71'];
  echo $ctime[$i]."<br>"; // It prints time perfectly
  $i++;
}
echo $i;
?>