Return to Snippet

Revision: 5718
at March 29, 2008 10:19 by Tank


Initial Code
	private function getMethod($buffer)
	{
		$methodStart = strpos($buffer, "\"") + 1;
		$methodEnd = strpos($buffer, "\"", $methodStart);
	
		$requestString = 
			substr($buffer, 
				$methodStart, 
				$methodEnd - $methodStart
			);
		
		list($method, $page, $protocol) =
			split(" ", $requestString);
			
		return $method;
	}

Initial URL

                                

Initial Description

                                

Initial Title
Get Method (GET/POST) from Lighttpd Log

Initial Tags
log

Initial Language
PHP