<?php use WebFX\System; use PhoenixSNS\Objects\Item; use PhoenixSNS\Objects\User; if (count($path) > 1 && $path[1] != "") { if ($path[2] == "images") { $thisuser = User::GetByIDOrShortName($path[1], true); if ($thisuser == null) { header("HTTP/1.1 404 Not Found"); header("User-Agent: psychati/1.1"); return; } $location = "avatar"; $size = "thumbnail.png"; if (count($path) > 3) { $location = $path[3]; if (count($path) > 4) { $size = $path[4]; } } $headers = apache_request_headers(); switch ($location) { case "avatar": if (isset($headers["If-Modified-Since"]) && $headers["If-Modified-Since"] != null) { // load from cache if available $time1 = strtotime($thisuser->OutfitCacheTimestamp); $time2 = strtotime($headers["If-Modified-Since"]); if ($time1 <= $time2) { header("HTTP/1.1 304 Not Modified"); return;