Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>The simplest approach is to use <a href="http://php.net/manual/de/function.shell-exec.php" rel="nofollow">shell_exec</a> for your purpose. It executes a command via shell and returns the complete output as a string, hence you can display it on your website. </p> <p>If this doesn't suit your purpose, because maybe you want some responses while waiting for the command to finish, check out the other <a href="http://www.php.net/manual/en/ref.exec.php" rel="nofollow">program execution functions available</a> in php (hint: there are a few good comments on the manual pages).</p> <p>Keep in mind, when evoking commandline scripts this way, generated output will have the file owner, group and permissions of your webserver (p.e. wwwrun or whatever). If parts of your deployment need a separate owner, group and/or file permissions, you have to manually set them either in your scripts or after invoking <a href="http://php.net/manual/de/function.shell-exec.php" rel="nofollow">shell_exec</a> (<a href="http://de2.php.net/manual/en/function.chmod.php" rel="nofollow"><code>chmod</code></a>, <a href="http://de2.php.net/manual/en/function.chown.php" rel="nofollow"><code>chown</code></a> and <a href="http://de2.php.net/manual/en/function.chgrp.php" rel="nofollow"><code>chgrp</code></a> can deal with this in php).</p> <p>About security: Alot of web-based applications put that kind of function into a separate installation directory, and kindly ask you to remove this directory after installing. I even remember some of them shouting at admins quite persistent unless it is removed. This is an easy way preventing this script being invoked by wrong hands at a wrong time. If your application might need it after installing, then you have to put it into an area where only authorized users have access to (p.e. admin area or something similar).</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload