谁能帮我把这段html代码改写成php的?
<tableborder="0"cellspacing="0"cellpadding="0"><tr><tdscope="row"><tableborder="1"><t...
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td scope="row">
<table border="1">
<tr>
<td id="showbfq" height="20" align="top" onclick="if(bfq.style.display=='none')
{bfq.style.display='';showbfq.innerText='优质优质';}
else{bfq.style.display='none';showbfq.innerText='点击更多';}">点击更多</td>
</tr>
<tr>
<td height="80" align="center" name="bfq" id="bfq" style="display:none;">aaa</td>
</tr>
</table>
</td>
</tr>
</table> 展开
<tr>
<td scope="row">
<table border="1">
<tr>
<td id="showbfq" height="20" align="top" onclick="if(bfq.style.display=='none')
{bfq.style.display='';showbfq.innerText='优质优质';}
else{bfq.style.display='none';showbfq.innerText='点击更多';}">点击更多</td>
</tr>
<tr>
<td height="80" align="center" name="bfq" id="bfq" style="display:none;">aaa</td>
</tr>
</table>
</td>
</tr>
</table> 展开
3个回答
展开全部
<?php
echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">";
echo "<tr>";
echo "<td scope=\"row\">";
echo "<table border=\"1\">";
echo " <tr>";
echo "<td id=\"showbfq\" height=\"20\" align=\"top\" onclick=\"if(bfq.style.display==\'none\')
{bfq.style.display=\'';showbfq.innerText=\'优质优质\';}
else{bfq.style.display=\'none\';showbfq.innerText=\点击更多\';}\">点击更多</td>";
echo "</tr>";
echo " <tr>";
echo "<td height=\"80\" align=\"center\" name=\"bfq\" id=\"bfq\" style=\"display:none;\">aaa</td>";
echo " </tr>";
echo "</table>";
echo " </td>";
echo "</tr>";
echo "</table>";
?>
也就是说将你的HTML代码放到echo "..";里面,凡是有“或者‘的前面加上\就好,可能还有些其他符号,好久没用了有点忘了,希望能采纳!!
echo "<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">";
echo "<tr>";
echo "<td scope=\"row\">";
echo "<table border=\"1\">";
echo " <tr>";
echo "<td id=\"showbfq\" height=\"20\" align=\"top\" onclick=\"if(bfq.style.display==\'none\')
{bfq.style.display=\'';showbfq.innerText=\'优质优质\';}
else{bfq.style.display=\'none\';showbfq.innerText=\点击更多\';}\">点击更多</td>";
echo "</tr>";
echo " <tr>";
echo "<td height=\"80\" align=\"center\" name=\"bfq\" id=\"bfq\" style=\"display:none;\">aaa</td>";
echo " </tr>";
echo "</table>";
echo " </td>";
echo "</tr>";
echo "</table>";
?>
也就是说将你的HTML代码放到echo "..";里面,凡是有“或者‘的前面加上\就好,可能还有些其他符号,好久没用了有点忘了,希望能采纳!!
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
$str = "<table border='0' cellspacing='0' cellpadding='0'><tr><td scope='row'><table border='1'><tr><td id='showbfq' height='20' align='top' onclick='if(bfq.style.display=='none') {bfq.style.display='';showbfq.innerText='优质优质';} else{bfq.style.display='none';showbfq.innerText='点击更多';}'>点击更多</td></tr><tr><td height='80' align='center' name='bfq' id='bfq' style='display:none;'>aaa</td> </tr> </table> </td> </tr> </table>";
echo $str;
追问
本地搭建一个服务器 安装了php模块 应该存放什么样的网页?具体怎么写?
追答
放什么样的网页得看你的服务器配置环境,比如IIS 支持很多种
怎么写得根据需要了
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
<?php
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td scope="row">
<table border="1">
<tr>
<td id="showbfq" height="20" align="top" onclick="if(bfq.style.display=='none')
{bfq.style.display='';showbfq.innerText='优质优质';}
else{bfq.style.display='none';showbfq.innerText='点击更多';}">点击更多</td>
</tr>
<tr>
<td height="80" align="center" name="bfq" id="bfq" style="display:none;">aaa</td>
</tr>
</table>
</td>
</tr>
</table>
?>
只要把TABLE的内容放到<?php ?>中就好了,如果不用TABLE就改成div
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td scope="row">
<table border="1">
<tr>
<td id="showbfq" height="20" align="top" onclick="if(bfq.style.display=='none')
{bfq.style.display='';showbfq.innerText='优质优质';}
else{bfq.style.display='none';showbfq.innerText='点击更多';}">点击更多</td>
</tr>
<tr>
<td height="80" align="center" name="bfq" id="bfq" style="display:none;">aaa</td>
</tr>
</table>
</td>
</tr>
</table>
?>
只要把TABLE的内容放到<?php ?>中就好了,如果不用TABLE就改成div
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询
广告 您可能关注的内容 |