PHP程序中可包含哪三种代码
可以包含的代码有html、css、JavaScript,采用混编的写法时文件名需要以.php结尾,否则不能正常解析php代码。
index.php:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Document</title>
<style>
/*css*/
body{
background: #eee;
}
</style>
</head>
<body>
<!-- html -->
<p>html</p>
<!-- JavaScript -->
<script>
alert(123);
</script>
</body>
</html>
<?php
echo 'www.gxlcms.com';
?>更多PHP相关知识,请访问PHP中文网!
Copyright © 2019- cepb.cn 版权所有 湘ICP备2022005869号-7
违法及侵权请联系:TEL:199 18 7713 E-MAIL:2724546146@qq.com
本站由北京市万商天勤律师事务所王兴未律师提供法律服务