Blogger Information
Blog 19
fans 3
comment 0
visits 13100
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
4月11 作业提交
蓝色天空
Original
638 people have browsed it

实例

<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>PHP字符串</title>
	<style type="text/css">
		table, td {
			border:1px solid #333;
		}
		table {
			border-collapse: collapse;
			margin: 30px auto;
			width:50%;
			 
			text-align: center;
		}
		tr td:first-child{text-align: right;		}

		tr td{text-align: left;}

	</style>
</head>
<body>
	<?php $name='张三';  ?>
	<table>
		<tr>
			<td>姓名</td>
			<td><?php echo $name; ?></td>
		</tr>
		<tr>
			<td>职业</td>
			<td><?php echo '学生:  \"厨师\"';    ?></td>
		</tr>
		<tr>
			<td>职业</td>
			<td><?php   echo "学生<hr>\"35号\"";     ?></td>
		</tr>
		<tr>
			<td>职业</td>
			<td>你好:<?php echo $name;
                     $note = <<< HEREDOC
                     关注php中文网的公众号,获得精选的 PHP 开发文章和创业心得\n
                      致力于打造一站式免费学习平台,誓将"公益"进行到底!\n
这里是PHP爱好者共同的家园,我们热忱欢迎来自全国各地的PHP爱好者~~
HEREDOC;
echo nl2br($note);

			           ?></td>
		</tr>
		<tr>
			<td>职业</td>
			<td><?    $note2 = <<< NOWDOC
             关注php中文网的公众号,获得精选的 PHP 开发文章和创业心得\n   <h3>$name</h3>            致力于打造一站式免费学习平台,誓将"公益"进行到底!\n
这里是PHP爱好者共同的家园,我们热忱欢迎来自全国各地的PHP爱好者~~
NOWDOC;

echo nl2br($note2);



			?></td>
		</tr>
	</table>



	 
</body>
</html>

运行实例 »

点击 "运行实例" 按钮查看在线实例


Correction status:qualified

Teacher's comments:
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post