【发布时间】:2017-06-30 10:35:03
【问题描述】:
假设我们有这样的事情:
<?php
while(some statement here)
{
echo "some HTML here";
//..................
}
?>
如你所知,我们可以这样做:
<?php
while(some statement here)
{?>
some HTML here
..............
<?php
} ?>
现在,如果我有这样的东西怎么办?
<?php
function example(){
$out="";
while(some statement here)
{
$out.="some HTML here";
$out.="some other HTML here";
//.......................
}
return $out;
}
?>
如何从<?php ?> 中获取 HTML 代码,使其更具可读性并且可以使用 NotePad++ 等编辑器轻松编辑?提前致谢
【问题讨论】:
标签: php html coding-style