I'm doing an administration for my server and I want to make it remotelly but I found a problem. When I'm starting minecraft server, the process of that file is still working and my page is going to be frozen till that process is killed.
I found many of answers but unfortunately, I'm running it on Windows.
Is it possible? I know that I can start the .bat server which start server, but I want to make it clear.
My code:
chdir("D:/xampp/htdocs/hosting/servers/" . $id);
//$WshShell = new COM("WScript.Shell");
//$oExec = $WshShell->Run("ava -Xmx1g -jar minecraft_server.jar", 0, false);
//idk how WshShell works, but it didn't worked..
exec("java -Xmx1g -jar minecraft_server.jar");
Thank you in advance for your reply!
EDIT
Well, got one problem. I've tried to start something else with WinShell but nothing happend. Nothing is happening when I want to start with WinShell so do I have to enable something to enable WinShell or do anybody know why my WinShell running nothing?
Code
chdir("D:/xampp/htdocs/hosting/servers/" . $id);
$WshShell = new COM("WScript.Shell");
$oExec = $WshShell->Run("java -Xmx1g -jar minecraft_server.jar", 0, false);