Jump to content

Calling a PHP script in bash


wiggst3r

Recommended Posts

Hi

 

I have the following code, which I want to replace with the correct code that will run a php script

 

if ! mount | grep -q /media/external; then
  echo "no backup" | mail you@home
  exit 1
  fi

 

All it does is checks if my external usb hdd is mounted, if not, mails me.

 

I don't want to install any mail packages on my system. Just want to replace where the mail function is called, with a called to a php file

 

Thanks.

Link to comment
https://forums.phpfreaks.com/topic/129759-calling-a-php-script-in-bash/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.