exec(PHP 4, PHP 5) exec — Execute an external program Описание
string exec
( string $command
[, array &$output
[, int &$return_var
]] )
exec() executes the given command . Список параметров
Возвращаемые значенияThe last line from the result of the command. If you need to execute a command and have all the data from the command passed directly back without any interference, use the passthru() function. To get the output of the executed command, be sure to set and use the output parameter. Примеры
Пример #1 An exec() example
<?phpПримечанияВнимание
Если вы собираетесь передавать функции данные, отправленные пользователем, вы должны использовать функции escapeshellarg() или escapeshellcmd() для того, чтобы обезопасить исполнение команд.
Внимание
В случае работы в безопасном режиме, все слова, следующие за начальной командой, рассматриваются как единый аргумент. То есть echo y | echo x будет работать как echo "y | echo x". |
|
|
| © 2009 Тест скорости интернета | Boont.Ru |