'; exit(); */ if ($head_data[2] != '') $title = $head_data[2]; else { $section_split = explode('-', $sections[(count($sections) - 1)]); if ($section_split[0] == '') $section_split = explode('-', $sections[(count($sections) -2)]); for ($i=0; $i < count($section_split); $i++) $title .= ucwords($section_split[$i]).' '; $title = preg_replace('![0-9]|\.htm|\.php!', '', $title); //strips off the numbers in articles and the file extension } if (strstr($head_data[6], 'THISONE|'))//a file needs to be included { $page_data = extract_file($head_data[6]); //top & bottom are called from the include file include($page_data['file_path']); } elseif (strstr($head_data[6], 'READTHIS|'))//a file needs to be read, use this for external files hosted off site { $page_data = extract_readfile($head_data[6]); //top & bottom are called from the include file inner_top($title, $head_data[0], $head_data[1], $head_data[4]); echo $page_data['top_half']; echo curler($page_data['file_path']); echo $page_data['bottom_half']; inner_bottom($head_data[3], $head_data[5], $head_data[4]); } else { inner_top($title, $head_data[0], $head_data[1], $head_data[4]); echo $head_data[6]; inner_bottom($head_data[3], $head_data[5], $head_data[4]); } exit(); }//close else it's an article or section ?>