darkfreaks Posted September 13, 2009 Share Posted September 13, 2009 say i have the appropriate folders for categories how would i rewrite it like ?pg=page&cat=cat right now categories arent setup but page is just using substr to get php pages with. code: <?php //check if directory exists if(!is_dir('touchups')||!is_dir('websites')||!is_dir('ads')){ echo "directory does not exist";} //open directories $adir = dir("ads"); $touchdir = dir("touchups"); $webdir = dir("websites"); //outputting all files in ad directory while (($file = $adir->read()) !== false) { echo $file; } //outputting all files in touchups directory while (($file = $touchdir->read()) !== false) { echo $file; } //outputting all files in website directory while (($file = $webdir->read()) !== false) { echo $file; } ?> Link to comment https://forums.phpfreaks.com/topic/174113-url-rewrite-help/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.