SimplePie_HTTP_Parser::http_version

Advertisement

Summery Summery

Parse the HTTP version

Syntax Syntax

SimplePie_HTTP_Parser::http_version()

Source Source

File: wp-includes/SimplePie/HTTP/Parser.php

		{
			$len = strspn($this->data, '0123456789.', 5);
			$this->http_version = substr($this->data, 5, $len);
			$this->position += 5 + $len;
			if (substr_count($this->http_version, '.') <= 1)
			{
				$this->http_version = (float) $this->http_version;
				$this->position += strspn($this->data, "\x09\x20", $this->position);
				$this->state = 'status';
			}
			else
			{
				$this->state = false;
			}
		}
		else
		{
			$this->state = false;
		}
	}

	/**
	 * Parse the status code

Advertisement

Advertisement

Leave a Reply