我在打印PHP标签中已经回显的html标签中的变量时遇到麻烦?我想在h1标签中打印$变量。我的代码:在已经在php标签中回显的html标签中打印php变量
<?php
while($pr = mysql_fetch_assoc($qAccess))
{
$id=$pr["user_id"];
$A=$pr["name"];
}
echo "<html
<!-- Profile info -->
<div id='profile_info'>
<h1 id='name' class='transition-02'>$A</h1>
<h4 class='line'>no heading</h4>
<h6><span class='fa fa-map-marker'></span> San Francisco , CA</h6>
</div>
<!-- End Profile info -->
</html>" ;
?>
这是什么问题?你有任何错误?你得到了什么,你期望什么? – Rizier123
这应该已经工作:) https://eval.in/445359 –
这是没有标题和旧金山,加利福尼亚州。那是你所期望的吗? – jessica