Php语法回显错误

时间:2017-08-30 18:51:15

标签: php html sql web-deployment-project

我正在尝试让我的表单显示查询结果,以便最终用户可以编辑它们。如何编写表单输入值,以便回显结果与代码?

############### PAGE HEADER ###############
     echo '<div id="header">
     <h1> <span id="logo"><img src="/images/twh_logo2.jpg" /></span><span 
     id="title"></span> </h1>
     </div>' . "\r";

    ############### UN-VERIFIED PICK TICKETS###############
     echo '<div id="full">
    <h1> 
     <div class="title">Edit Label Details</div>
    <div id="search" class="text">
    <div>
        <form method="post">
            ID:<br>
            <input type="text" name="id" value= $result[\'id\'];"><br>
        </form>
    </div>
    </div>
</h1>
</div>' . "\r";
  ?>

1 个答案:

答案 0 :(得分:2)

中断你的字符串:

echo '<div id="full">
    ....
    <input type="text" name="id" value="' . $result['id'] . '"><br>
    ....
</div>';