show exception message in system.err instead of printing stacktrace
fixed php export