note 74100 added to function.php-check-syntax
| From: | QuisatIVEGOTspamENOUGHomicidiodotnl at osu1 dot php dot net | Date: | Sat, 24 Mar 2007 23:42:49 +0000 |
| Subject: | note 74100 added to function.php-check-syntax | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-124777@lists.php.net to get a copy of this message | ||
<?PHP
// Think about shell-command escaping if you`re using user-input
function php_check_syntax($file,&$error) {
exec("php -l $file",$error,$code);
if($code==0)
return true;
return false;
}
?>
Note: This is UNIX
Note: If your environment-variable PATH is not set correctly, you will need to insert the path to
php (like /usr/local/bin/php)
----
Server IP: 83.137.20.120
Probable Submitter: 82.174.113.83
----
Manual Page -- http://www.php.net/manual/en/function.php-check-syntax.php
Edit -- https://master.php.net/note/edit/74100
Del: integrated -- https://master.php.net/note/delete/74100/integrated
Del: useless -- https://master.php.net/note/delete/74100/useless
Del: bad code -- https://master.php.net/note/delete/74100/bad+code
Del: spam -- https://master.php.net/note/delete/74100/spam
Del: non-english -- https://master.php.net/note/delete/74100/non-english
Del: in docs -- https://master.php.net/note/delete/74100/in+docs
Del: other reasons-- https://master.php.net/note/delete/74100
Reject -- https://master.php.net/note/reject/74100
Search -- https://master.php.net/manage/user-notes.php