What role does the semicolon play in PHP code syntax, and how can its absence affect the code execution?

The semicolon in PHP code syntax is used to terminate statements. If a semicolon is missing at the end of a statement, it can lead to syntax errors and affect the code execution. To fix this issue, ensure that every statement in your PHP code ends with a semicolon.

// Incorrect code without semicolon
echo "Hello, World"  // Missing semicolon at the end of the statement

// Corrected code with semicolon
echo "Hello, World";  // Semicolon added at the end of the statement