1. PHP tags
1. XML style
Copy code The code is as follows:
2. Short style
Copy code The code is as follows:
echo "hello world"; ?>
3. Script style
Copy code The code is as follows:
2. PHP Notes
1. Single line comment: // (C style)
2. Multi-line comments: /* */ (C style)
3. Single-line script comment: # (shell style)
Tips: Comments are generally written above the code
3. PHP blank
1. Blank spacer
Line feed (carriage return), space, Tab (tab character)
2. Conventions and customs
Code snippet (2 lines), class (2 lines), function (1 line), function variable and first statement (1 line), before comment (1 line)