Advertisements

is_lighttpd_before_150

Definition:
function is_lighttpd_before_150() {}

Is the server running earlier than 1.5.0 version of lighttpd?

Return values

returns:Whether the server is running lighttpd < 1.5.0

Source code

function is_lighttpd_before_150() {

	$server_parts = explode( '/', isset( $_SERVER['SERVER_SOFTWARE'] )? $_SERVER['SERVER_SOFTWARE'] : '' );

	$server_parts[1] = isset( $server_parts[1] )? $server_parts[1] : '';

	return  'lighttpd' == $server_parts[0] && -1 == version_compare( $server_parts[1], '1.5.0' );

}

2129

Advertisements

No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: