How exactly did you call it? Did you use ISPConfig's Apache (port 81) for it? It runs under the user admispconfig, not root.
Why dont you use the usual mechanisms in ISPConfig? It's is not a good idea to run scripts that need root priveliges directly from the ISPConfig interface. ISPConfig is split in a server part taht runs with root priveliges and the interface that is run under the unpriveliged admispconfig user.