$category Articles"; include '../../templates/template3.html'; echo "

$category Articles

"; include '../../templates/template4.html'; if (is_dir($dir)) { if ($dh = opendir($dir)) { while (($file = readdir($dh)) !== false) { if ($file=='.' || $file=='..') continue; $fh = fopen($dir."/".$file, "rb"); $contents = fread($fh, 1500); $p1 = strpos($contents, "

"); $p2 = strpos($contents, "

"); $p3 = strpos($contents, "")+50; $p4 = strpos($contents, " ", $p3+200); $teaser = str_replace(array("

", "

", "
", "
", "", "", "", "", "", "", "

", "

", "
", "
", "", "", "", "", "", ""), " ", substr($contents, $p3, $p4-$p3))."..."; echo "

".substr($contents, $p1+4, $p2-$p1-4)."

".$teaser."

Continue Reading...

\n"; fclose($fh); } closedir($dh); } } include '../../templates/template5.html'; ?>