当前位置:网站首页>Notes in "PHP Basics" PHP
Notes in "PHP Basics" PHP
2022-07-27 08:06:00 【Go home at night】
Functional requirements
by PHP Add comments to code
The sample code
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>php Common marks in </title>
</head>
<body>
<?php
echo "C++ Style single line notes with // From the beginning to the end of the line <br />"; // C++ Style single line notes
/*
C Style multi line comments
Many lines in the middle are comments
*/
echo "C Style multi line comments with /* start , With */ end <br />";
echo "Shel Style notes in # From the beginning to the end of the line "; # shell Style notes
?>
</body>
</html>Running results
Knowledge description
In program development , For the convenience of code reading 、 Understanding and maintenance , You can use comments to explain and explain the code . Comments will be ignored by the parser when the program is running .PHP Support multiple styles of annotations :
// C++ Style single line notes :C++ Style single line notes ,“//” The following content is a single line comment , from “//” Start , To the end of the line or PHP Everything before the end of the tag is a comment .
/*
C Style multi line comments
Many lines in the middle are comments
*/:“/*” and “*/” The contents between are multi line comments , Multiline comments to “/*” Start , With “*/” end . meanwhile , Single line comments can be nested in multi line comments , But you can't nest multiple lines of comments .
# shell Style notes :“#” It's a Shell Style single line notes . stay PHP The single line annotation that is more used in development is “//” The opening single line comment .
Code comments are usually written on the top or right of the commented code , Don't write it at the bottom of the code . Nesting is not allowed for multiline comments .
边栏推荐
- C语言:优化后的希尔排序
- 如何在 60 秒内去分析和定位问题?
- Day111.尚医通:集成NUXT框架、前台页面首页数据、医院详情页
- 虚拟机克隆
- Prevent cookies from modifying ID to cheat login
- Dormitory access control system made by imitating the boss (III)
- mqtt指令收发请求订阅
- [golang] golang develops wechat official account web page authorization function
- What are the software tuning methods? Let's see what Feiteng technology experts say about dragon lizard technology
- Netdata 性能监测工具介绍、安装、使用
猜你喜欢

How to play with the purchase of SAP variant materials? Look at this article and you will understand

Sword finger offer 58 - I. flip word order
![[flight control development foundation tutorial 4] crazy shell · open source formation UAV - serial port (optical flow data acquisition)](/img/49/8e5374fee0cbf48115159ac3ff23c6.png)
[flight control development foundation tutorial 4] crazy shell · open source formation UAV - serial port (optical flow data acquisition)

【万字长文】吃透负载均衡,和阿里大牛的技术面谈

Gossip: it's really important to have a rod in your hand and a net on your shoulder. As for how many fish are in the basket?

Data extraction 2

QT creator code style plug-in beautifier

存储过程与函数

10000 word parsing MySQL index principle -- InnoDB index structure and reading

物来顺应,未来不迎,当时不杂,既过不恋
随机推荐
Harbor can't log in with the correct password
shell脚本学习day01
10000 word parsing MySQL index principle -- InnoDB index structure and reading
一段平平无奇的秋招经历
Solid smart contract development - 3.3-solid syntax control structure
The third letter to the little sister of the test | Oracle stored procedure knowledge sharing and test instructions
物联网工业级UART串口转WiFi转有线网口转以太网网关WiFi模块选型
Use of NPM
Stored procedures and functions
C语言:随机生成数+插入排序
DEMO:ST05 找文本ID 信息
Grandson's questions are difficult, and his son's invigilation is strict. I can't do it. Pay back my school money
Design and development of GUI programming for fixed-point one click query
剑指 Offer 58 - I. 翻转单词顺序
You may need an additional loader to handle the result of these loaders.
软件调优方法有哪些?看看飞腾技术专家怎么说 | 龙蜥技术
2022-07-26 group 4 abstract classes and interfaces
Teach you to build a nail warning robot hand in hand
How to obtain the cash flow data of advertising services to help analyze the advertising effect?
反弹shell是什么?反弹shell有什么用?