query("insert into hits values ('', '".date("Y-m-d-h-i-s")."', '".$HTTP_SERVER_VARS['REQUEST_URI']."', '".gethostbyaddr($HTTP_SERVER_VARS['REMOTE_ADDR'])."', '".$HTTP_SERVER_VARS['HTTP_REFERER']."', '".$HTTP_SERVER_VARS['HTTP_USER_AGENT']."' )") or die(mysql_error()); */ function addzero($val){ // guess what this does... if (strlen($val) == 1){ $val = "0".$val; } return $val; } foreach($_REQUEST as $k => $v){ $$k = $v; } $lim = 60; ?> There's Treasure Everywhere
Year Month Day Free text, eg "Trick question" or "Calvinball" or "Rosalyn" or "Boogerbrain"
About

0){ $srch = "Search results for \"$str\""; } if($y>0 or $m>0 or $d>0){ $srch = "Search results for ".(($y>0)?"19".$y:"*")."-".(($m>0)?$m:"*")."-".(($d>0)?$d:"*"); } if($search){ if(strlen($y) == 0){ $y="__"; } if(strlen($m) == 0){ $m="__"; }else{ $m = addzero($m); } if(strlen($d) == 0){ $d="__"; }else{ $d = addzero($d); } if(strlen($str) > 0){ $wstr = " and text like '%$str%'"; } $where = (!$showfrom) ? "where id like 'ch$y$m$d' $wstr" : "where id >= '$showfrom'"; $limit = "limit $lim"; $sql = "select * from ch $where $limit"; // echo $sql; $rs = $db->GetAll($sql); // print_r($rs); echo "

".sizeof($rs)." strips found

"; foreach($rs as $r){ echo "\n\n
".substr($r['id'],6,2)."/".substr($r['id'],4,2)."/19".substr($r['id'],2,2)." [Next $lim from this date]

"; echo "\n
"; $words = $r['text']; $punc = Array(".",",","!","?",'"',"(",")"); $words = array_unique(explode(" ",strtolower($r['text']))); foreach ($words as $w){ for($p=0;$p= 4){ echo "$w "; } } echo "
"; } }else{ echo "

There are other searchable C&H archives out there, but this one is a little simpler and more straightforward (ie you get them all on the one page).

Input any combination of dates and words in the form above and enjoy!

Note: it currently returns no more than 60 results at a time (to stop people trying to load all 3,696 strips at once).

"; } ?>

[LeSinge.org]