in reply to can't get mailx to send from within a script

Hopefully this plain-text illustration is clear enough to highlight the problem with your second examaple.

system("/bin/mailx -s "hello" john@work.com"); ^ ^ ^ ^ ^ | | | | | quote | | quote unquote | bareword unquote

It ought to be a "bareword found where operator expected" error.


Dave