include ('management/include/functions.php'); extract($_REQUEST); //print_r($id); $bid = explode("/", $id); $split_id = $bid[0]; $split_name = $bid[1]; $prod_details_urlnew = $site_url . '/details/' . 'noc-Silicon-ip' . '/' . '980660'; header("location:$prod_details_urlnew"); $actual_link = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] === 'on' ? "https" : "http") . "://{$_SERVER['HTTP_HOST']}{$_SERVER['REQUEST_URI']}"; $url_ex = $bid = explode("/", $actual_link); //print_r($url_ex); $seg4 = $url_ex['4']; $check_split_id = explode("-", $split_id); $nowaction = $check_split_id[0]; $nowid = $check_split_id[1]; //$sql = " SELECT * from product "; //$sql .= " WHERE status = 'active' "; if ($nowaction == 'c' & $nowid != '') { //$sql_where .= " and FIND_IN_SET($nowid,cat_id) "; //$sql_where .= " and (FIND_IN_SET($nowid,P.cat_id) OR FIND_IN_SET($nowid,P.subcat_id) OR FIND_IN_SET($nowid,P.sub_subcat_id) ) "; $category_details = mysqli_fetch_array(mysqli_query($connection,"select * from category where category_id ='$nowid'")); $banner_img = $category_details['category_banner']; $category_name = $category_details['category_name']; $filter_name = $category_details['category_name']; $cat_meta_title = $category_details['category_title']; $cat_meta_keyword = $category_details['category_keyword']; $cat_meta_description = $category_details['category_desc']; if ($banner_img != '') { $banner_img = "$site_url/upload/category/" . $banner_img; } else { $banner_img = "$site_url/images/default.jpg"; } } if ($nowaction == 's' & $nowid != '') { //$sql_where .= " and FIND_IN_SET($nowid,subcat_id) "; $category_details = mysqli_fetch_array(mysqli_query($connection,"select * from category where category_id ='$nowid'")); $banner_img = $category_details['category_banner']; $category_name = $category_details['category_name']; $filter_name = $category_details['category_name']; $cat_meta_title = $category_details['category_title']; $cat_meta_keyword = $category_details['category_keyword']; $cat_meta_description = $category_details['category_desc']; if ($banner_img != '') { $banner_img = "$site_url/upload/category/" . $banner_img; } else { $banner_img = "$site_url/images/default.jpg"; } } if ($nowaction == 'sc' & $nowid != '') { //$sql_where .= " and FIND_IN_SET($nowid,sub_subcat_id) "; $category_details = mysqli_fetch_array(mysqli_query($connection,"select * from category where category_id ='$nowid'")); $banner_img = $category_details['category_banner']; $category_name = $category_details['category_name']; $filter_name = $category_details['category_name']; $filter_url = $category_details['category_url']; $cat_meta_title = $category_details['category_title']; $cat_meta_keyword = $category_details['category_keyword']; $cat_meta_description = $category_details['category_desc']; if ($banner_img != '') { $banner_img = "$site_url/upload/category/" . $banner_img; } else { $banner_img = "$site_url/images/default.jpg"; } } /* $sql_group = " GROUP BY prod_id "; $sql_order = " ORDER BY id ASC "; $query = $sql.$sql_where.$sql_group.$sql_order; $getproduct = mysqli_query($connection,$query); $product_count = mysqli_num_rows($getproduct); */ if ($cat_meta_title != '') { $meta_title = $cat_meta_title; $meta_keyword = $cat_meta_keyword; $meta_description = $cat_meta_description; } else { $meta_title = "Truechip | www.truechip.net"; $meta_keyword = "Truechip"; $meta_description = "Truechip is a privately held company, with a global footprint and Sales coverage across North America, Europe and Asia."; } $main_category_name = $get->get_category_name_by_id($nowid); $main_category_description = $get->get_category_description_by_id($nowid); $main_category_metadescription = $get->get_category_desc($nowid); $main_cat_url = str_replace(" ", "-", strtolower($main_category_name)); $redirect_url = $site_url.'/product/'.$main_cat_url.'/'. 's-'.$nowid; $getsubmenuquery = $get->get_subcategory_menu($nowid); $countsubmenu = mysqli_num_rows($getsubmenuquery); //if($seg4 == $main_cat_url){ ?>