Home >Backend Development >PHP Tutorial >PHP注释及与HTML混写

PHP注释及与HTML混写

WBOY
WBOYOriginal
2016-06-23 14:28:521018browse

一、注释

View Code

<!DOCTYPE html><html><title>注释</title>         <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><body>     <a href="../index.php">返回首页</a>     <hr></hr><?php    echo "/**/号注释<br/>";    /*  *号注释 */    echo "#号注释<br/>";    # #号注释    echo "// 注释<br/>";    //  // 注释?></body></html>

二、与HTML混写

<!DOCTYPE html><html><title>与HTML混写</title>         <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><body>     <a href="../index.php">返回首页</a>     <hr></hr>1.php标签<br/><?php echo '<B>与HTML混写1</B><br/>'; ?>2.php短标签<br/><? echo '<B>short Tag 与HTML混写2</B><br/>'; ?>3.php判断<br/><?phpif (true) {?>    <strong>This is true.与HTML混写3</strong><?php} else {?>    <strong>This is false.与HTML混写3</strong><?php}?> <br/>4.script language="php"<br/><script language="php">    echo 'script language=php 与HTML混写4<br/>';</script></body></html>

 

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn