Good PHP code should be structured.
Good PHP code should be normalized.
Good PHP code should be self-adapting.
Good PHP code should be safe.
Where are the advantages and disadvantages of PHP code?
Copy to ClipboardWhat to refer to: [www.bkjia.com]1. Non-optimized PHP code
Echo ("
Search results for query: ".
$_get[' query ']. “.
”);
?>
2. Simple and optimized code
Echo ("
Search results for query: ".
Htmlspecialchars ($_get[' query '). “.
”);
?>
3. Reasonably optimized code
if (isset ($_get[' query '))
{
Echo '
Search results for query: ',
Htmlspecialchars ($_get[' query '], ent_quotes), '.
’;
}
?>
http://www.bkjia.com/PHPjc/363959.html www.bkjia.com true http://www.bkjia.com/PHPjc/363959.html techarticle Good PHP code should be structured. Good PHP code should be normalized. Good PHP code should be self-adapting. Good PHP code should be safe. PHP Code of Excellent ...