catalepticstate Posted May 1, 2008 Posted May 1, 2008 Hi, on the product info page, I want to include a file called test1.php i'm trying to include a business card designer script I have written. But I need to only bring this page up if the current products category is = 1 Any ideas on how I could do this?
oschellas Posted May 1, 2008 Posted May 1, 2008 Something like below will do the trick, place the code in the product_info.php page where you want to display it: <?php if(isset($HTTP_GET_VARS['products_id']) && $HTTP_GET_VARS['products_id']!=''){ $firstcats = explode("_",$cPath); if($firstcats[0]==1){ require_once('test1.php'); }//end if parent category id = 1 }//end if product id ?>
Recommended Posts
Archived
This topic is now archived and is closed to further replies.