mdvignesh Posted March 11, 2011 Share Posted March 11, 2011 I want to retrive data in textbox from databse I get this error Parse error: parse error in C:\wamp\www\mariyano\profile.php on line 20 I have upload the file Please help its urgent [attachment deleted by admin] Link to comment https://forums.phpfreaks.com/topic/230308-parse-error-parse-error/ Share on other sites More sharing options...
kenrbnsn Posted March 11, 2011 Share Posted March 11, 2011 Please post your code between tags. Ken Link to comment https://forums.phpfreaks.com/topic/230308-parse-error-parse-error/#findComment-1186033 Share on other sites More sharing options...
mdvignesh Posted March 11, 2011 Author Share Posted March 11, 2011 I want to retrive data in textbox from databse I get this error Parse error: parse error in C:\wamp\www\mariyano\profile.php on line 20 I have upload the file <?php //echo "<div align='center'><h3>profile</h3><br></div>"; //<p> Name: <input type="text" value=vignesh name="name"></p> //Email: <input type="text" [email protected] name=email> include("connect.php"); if(!$cn) { die('could not connect' . mysql_error); } echo "<a href='signin.php'><h3>Sign in</h3></a> <br/>"; //remember to put single quotes in url $qry=mysql_query("SELECT * FROM pro"); while($row=mysql_fetch_array($qry)) { $name=echo $row['name']; $mobile=echo $row['mobile']; $email=echo $email['email']; //echo "profiles". "<br/><br/>"; echo $row['name'] . $row['mobile'] . $row['email']; } /*<html> <head> <title> profile </title> </head> <body> <h3> Profiles<br/><br/> Name: <input type='text' name='name' value="<?php echo "jhj";?>"> <br/> Mobile: <input type='text' name='mobile' value="<?php $mobile?>"> <br/> Email: <input type='text' name='email' value="<?php $email?>"> </h3> </body> $name=echo "$row['name']"; $mobile=echo "$row['mobile']"; $email=echo "$row['email']"; */ if(mysql_query($qry,$cn)) { die('error' . mysql_error()); } echo "<h3>Profiles</h3><br/><br/>"; echo "Name: <input type=\"text\" name=\"name\" value=\"$name\"> "; echo "<br/>"; echo "Mobile: <input type=\"text\" name=\"mobile\" value=\"$mobile\"; "; echo "<br/>"; echo "Email: <input type='text' name='email' value=\"$email\"; "; ?> Please help its urgent Link to comment https://forums.phpfreaks.com/topic/230308-parse-error-parse-error/#findComment-1186037 Share on other sites More sharing options...
Pikachu2000 Posted March 11, 2011 Share Posted March 11, 2011 The problem is with these lines: $name=echo $row['name']; $mobile=echo $row['mobile']; $email=echo $email['email']; I'm sure the error was 'unexpected T_ECHO', right? Remove 'echo' from them and try again. Link to comment https://forums.phpfreaks.com/topic/230308-parse-error-parse-error/#findComment-1186039 Share on other sites More sharing options...
mdvignesh Posted March 12, 2011 Author Share Posted March 12, 2011 The problem is with these lines: $name=echo $row['name']; $mobile=echo $row['mobile']; $email=echo $email['email']; I'm sure the error was 'unexpected T_ECHO', right? Remove 'echo' from them and try again. Thank U very much :D Link to comment https://forums.phpfreaks.com/topic/230308-parse-error-parse-error/#findComment-1186535 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.