0838f1c15b
If a file is linked in the email, the last one will be added to the service, otherwise, the e-mail body will be used
14 lines
348 B
Bash
Executable File
14 lines
348 B
Bash
Executable File
#!/bin/sh
|
|
|
|
DIR="/var/www/p0m.fr/paste/"
|
|
|
|
tmpfile=`mktemp`
|
|
|
|
cat <&0 > $tmpfile
|
|
|
|
from=`cat "$tmpfile" | formail -x From | tail -n 1 | $DIR/conv2047-0.1.pl -d`
|
|
subject=`cat "$tmpfile" | formail -x subject | $DIR/conv2047-0.1.pl -d`
|
|
|
|
cat "$tmpfile" | $DIR/apimail.php "$from" "$subject"
|
|
#chmod +r `cat "$tmpfile" | $DIR/apimail.php "$from" "$subject"`
|