Search our database to past shows. Our archive includes transcripts, RealAudio and RealVideo of previous shows. To find stories by area of interest or your favorite guests, just enter guests' names or keywords in the field below and click \"search\" to see the results. Searches are not case-sensitive (e.g. \"imf\", \"Imf\", and \"IMF\" are identical). Multiple keywords should be separated by a comma. For example:\n
  • enter \"banking, legislation\" to search for the words \"banking\" or \"legislation\"
  • enter \"new york, crime\" to search for the phrase \"new york\" or the word \"crime\" (you could also enter \"New York, crime\")
\n"; echo "
\n"; echo "\n"; echo "\n"; echo "

\n\n"; echo "


\n"; } $num = -1; if ($show) { $nkey = ""; $ignored = ""; if ($key) { $key = ereg_replace( ", ", ",", $key );/* strips space after commas */ $tok = strtok($key,","); while ($tok) { if ($tok == "and" || $tok == "or" || $tok == "AND" || $tok == "OR") { $tok = AddSlashes($tok); $ignored = $ignored + $tok + " "; } else { $tok = AddSlashes($tok); $split[] = $tok; $nkey = $nkey + $tok + " " ; } $tok = strtok(","); } } else { $split[0] = ""; } $op = "OR"; $order = "showdate DESC"; /* generate query string */ $key = ""; $splits = count($split); $k=0; while ($k < $splits) { if ($k==0) { $qs = $searchfield . " LIKE '%" . $split[$k] . "%'"; $key = $split[$k]; } else { $qs = $qs . " $op " . $searchfield . " LIKE '%" . $split[$k] . "%' "; $key = $key . $split[$k]; } $k++; } $qs = $qs . " ORDER BY " . $order; mysql_connect("oldev-cr01.pbs.org", "wetaaccess", "9secnav8"); $query = "SELECT * FROM shows WHERE $qs"; /*echo "query string is: " . $query . "

\n";*/ $res = mysql("wetadb","$query"); $num = mysql_numrows($res); } if ($num==1) { echo "$num show was found that matches your search

\n\n"; } elseif ($num>1) { echo "$num shows were found that match your search

\n\n"; } elseif ($num == 0) { echo "No shows were found that matched your search. Please try again using a different keyword or host name. You may also search by choosing from a list of industries on our main page.

\n\n"; echo "search again"; } if ($num > 0) { echo ""; $i = 0; while ($i<$num) { $ID = mysql_result($res,$i,"ID"); $showdate = mysql_result($res,$i,"showdate"); $guests = mysql_result($res,$i,"guests"); $topics = mysql_result($res,$i,"topics"); $keywds = mysql_result($res,$i,"keywds"); $transcripts = mysql_result($res,$i,"transcripts"); $videos = mysql_result($res,$i,"videos"); $audios = mysql_result($res,$i,"audios"); $imagefile = mysql_result($res,$i,"imagefile"); $guests = StripSlashes($guests); $topics = StripSlashes($topics); $keywds = StripSlashes($keywds); $topicarray = split(":", $topics); $transcriptarray = split(":", $transcripts); $videoarray = split(":", $videos); $audioarray = split(":", $audios); $topiccount = count($topicarray); if (ereg("([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})", $showdate, $regs)) { $newdate = date("F d, Y", mktime(0,0,0,$regs[2],$regs[3],$regs[1])); } $cur_num = $i +1; if ($cur_num%2==0) { $bgcolor = ffffff; } else { $bgcolor = fafad2; } echo ""; $i++; } echo "
"; echo ""; echo ""; $j = 0; while ($j < $topiccount) { echo "\n"; $j++; } echo "
Air Date: $newdate
Guests: $guests
$topicarray[$j]
"; if (file_exists("transcripts/$transcriptarray[0]")) { echo "
transcript  |  "; } else { echo "
transcript  |  "; } if (file_exists("realvideo/$videoarray[$j]")) { echo "realvideo  |  "; } else { echo "realvideo  |  "; } if (file_exists("realaudio/$audioarray[$j]")) { echo "realaudio"; } else { echo "realaudio"; } echo "

search again"; } ?>