", $_POST['wall']); printf(""); /* get wallpaper id and get info from api */ preg_match("/(?!.*-)([A-Za-z0-9]+)/", $_POST['wall'], $matches); $res = getwallpaper("https://wallhaven.cc/api/v1/w/$matches[0]?apikey=$apikey"); ?>
\n
\n", $res["uploader"]["avatar"]["medium"]); printf("%s\n
\n", $res["uploader"]["username"], $res["uploader"]["group"], $res["uploader"]["username"]); printf("%s old\n", $res["created_at"], timesince(strtotime($res["created_at"]))); ?>
TagsSimilar Wallpapers\n", $matches[0]); foreach ($res["tags"] as $tags) printf("%s\n", $tags["alias"], $tags["purity"], $tags["id"], $tags["name"]); ?>

Properties Category %s

\n", ucfirst($res["category"])); printf("

Purity %s

\n", $res["purity"], toupperpurity($res["purity"])); printf("

Resolution %s

\n", $res["resolution"]); printf("

File Size %s

\n", humanfilesize($res["file_size"])); printf("

Share %s

\n", $matches[0], $_POST['purity'], $matches[0]); ?>

Server doesn't have an apikey, cannot view image.

"); ?>