Jump to content

dangtran09

New Members
  • Posts

    1
  • Joined

  • Last visited

dangtran09's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. hi all - i'm new to php and also new to this forum. i have a form that reads in 2 inputs from the user: database name and directory. <form action="welcome.php" method="post"> DB Name: <input type="text" name="dbname"><br> Directory: <input type="text" name="dir"><br> <input type="submit"> </form> what i'm trying to do is, based on the user inputs, would for the dbname, execute a mysqldump to backup the database. and for directory, execute a tar -czvf $dir.tar.gz $dir. i have the following for the tar part: $directory=$_POST["dir"]; $output = shell_exec('tar -czvf {$directory} <?php echo $directory; ?>'); however, it's not executing. please help. thanks
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.