[eluser]Bart v B[/eluser]
if you give me some time, then i will share my solution for this.
I am working on a hosting controlpanel that works with some shell scripting.
It's a very bad practice to give php su or sudo rights.
So my idea for that is very simple, i let php create a simple textfile, and let the server do the rest.
I hope that you have a linux server, and if so, what kind of distro are you using?