#10 Last Modified header

open
nobody
None
5
2005-01-08
2005-01-08
Anonymous
No

It would be great if in the next version we could get
the "Last-Modified" header value just by using $snoopy-
>lastmodified

I've done this in my local copy. Here's the code:

1. Create a new class variable under /* user definable
vars */:
var $lastmodified = "";

2. On _httprequest function place the following code
BEFORE the line: $this->headers[] = $currentHeader;

//Start of Last-Modified code
if(preg_match("/^Last-Modified:/i",$currentHeader)) {
preg_match("/^Last-Modified:[ ]+(.*)/i",rtrim
($currentHeader),$lastmodified);
$this->lastmodified = $lastmodified[1];
}
// End of Last-Modified code

Carlos

Discussion