PHP win32service Functions

EditRocket provides the following information on win32service functions in the PHP source code builder.

mixed win32_create_service ( array $details [, string $machine ] ) -

int win32_delete_service ( string $servicename [, string $machine ] ) - Attempts to delete a service from the SCM database. Administrative privileges are required for this to succeed.

int win32_get_last_control_message ( void ) - Returns the control code that was last sent to this service process. When running as a service you should periodically check this to determine if your service needs to stop running.

mixed win32_query_service_status ( string $servicename [, string $machine ] ) - Queries the current status for a service, returning an array of information.

bool win32_set_service_status ( int $status ) - Informs the SCM of the current status of a running service. This call is only valid for a running service process.

int win32_start_service ( string $servicename [, string $machine ] ) - Attempts to start the named service. Usually requires administrative privileges.

mixed win32_start_service_ctrl_dispatcher ( string $name ) - When launched via the Service Control Manager, a service process is required to check-in with it to establish service monitoring and communication facilities. This function performs the check-in by spawning a thread to handle the lower-level communication with the service control manager.

int win32_stop_service ( string $servicename [, string $machine ] ) - Stops a named service. Requires administrative privileges.