134 lines
		
	
	
		
			6.2 KiB
		
	
	
	
		
			PHP
		
	
	
	
	
	
		
		
			
		
	
	
			134 lines
		
	
	
		
			6.2 KiB
		
	
	
	
		
			PHP
		
	
	
	
	
	
|   | <!DOCTYPE html> | |||
|  | <html> | |||
|  |    <head> | |||
|  |       <meta charset="utf-8">  | |||
|  |       <?php include('../cms_admin/db_connection.php'); ?>
 | |||
|  |     <?php | |||
|  |     // Fetch products and categories
 | |||
|  |     $p_id = isset($_GET['id']) ? intval($_GET['id']) : 0; | |||
|  | 
 | |||
|  |     $result = mysqli_query($conn, "
 | |||
|  |         SELECT p.id, p.cn_title, p.icon, p.image, p.tracking_link, p.cn_short_description, p.cn_long_description, p.status, c.cn_name as cn_category_name | |||
|  |         FROM products p | |||
|  |         JOIN categories c ON p.category_id = c.id | |||
|  |         WHERE p.id = $p_id | |||
|  |     ");
 | |||
|  | 
 | |||
|  |     if ($result && mysqli_num_rows($result) > 0) { | |||
|  |         $row = mysqli_fetch_assoc($result); | |||
|  | 
 | |||
|  |         $product_title = htmlspecialchars($row['cn_title']); | |||
|  |         $long_description = $row['cn_long_description']; | |||
|  |         $category_name = htmlspecialchars($row['cn_category_name']); | |||
|  |         $cn_short_description = htmlspecialchars($row['cn_short_description']); | |||
|  | 
 | |||
|  |         // SEO tags
 | |||
|  |         $title = "了解更多关于 $product_title 的信息,包括特性和优势。 - AI Tool Path"; | |||
|  |         $description = "$cn_short_description"; | |||
|  |         $keywords = "$product_title, $category_name, AI工具, 工具导航, AI Tool Path, AIPT"; | |||
|  | 
 | |||
|  |         // Output meta tags
 | |||
|  |         echo "<title>$title</title>"; | |||
|  |         echo "<meta name='description' content='$description'>"; | |||
|  |         echo "<meta name='keywords' content='$keywords'>"; | |||
|  |     } else { | |||
|  |         // Redirect to the 404 page if no product is found
 | |||
|  |         echo "<script>window.location.href = '404';</script>"; | |||
|  |         exit(); | |||
|  |     } | |||
|  |     ?>
 | |||
|  | 
 | |||
|  | 
 | |||
|  |       <link href="https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700;800&display=swap" rel="stylesheet"> | |||
|  |       <link href="https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap" rel="stylesheet"> | |||
|  |       <!--Color Switcher Mockup--> | |||
|  |       <link href="css/color-switcher-design.css" rel="stylesheet"> | |||
|  |       <!-- Color Themes --> | |||
|  |       <link id="theme-color-file" href="css/color-themes/default-color.css" rel="stylesheet"> | |||
|  |       <link rel="shortcut icon" href="images/favicon.png" type="image/x-icon"> | |||
|  |       <link rel="icon" href="images/favicon.png" type="image/x-icon"> | |||
|  |       <!-- Responsive --> | |||
|  |       <meta http-equiv="X-UA-Compatible" content="IE=edge"> | |||
|  |       <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"> | |||
|  |       <!-- Stylesheets --> | |||
|  |       <link href="css/bootstrap.css" rel="stylesheet"> | |||
|  |       <link href="css/style.css" rel="stylesheet"> | |||
|  |       <link href="css/responsive.css" rel="stylesheet"> | |||
|  |       <meta name="robots" content="index, follow"> | |||
|  |           <style> | |||
|  |       .career-page-top__content-box-two h3,h1,h2,h3,h4{ | |||
|  |       font-size:18px !important; | |||
|  |       color:#ad92df !important;
 | |||
|  |       } | |||
|  |           </style> | |||
|  |    </head> | |||
|  |    <body class="body-bg-color"> | |||
|  |       <!-- Header --> | |||
|  |       <?php include 'container/header.php'; ?>
 | |||
|  | 
 | |||
|  |       <!-- Page Title Start --> | |||
|  |       <section class="page-title"> | |||
|  |          <div class="container"> | |||
|  |             <div class="page-title__inner"> | |||
|  | 
 | |||
|  |             </div> | |||
|  |          </div> | |||
|  |       </section> | |||
|  | 
 | |||
|  |       <!-- Career Page Top Start --> | |||
|  |       <section class="career-page-top"> | |||
|  |          <div class="container"> | |||
|  |             <div class="career-page-top__inner"> | |||
|  |                <div class="career-page-top__single"> | |||
|  |                   <div class="career-page-top__img"> | |||
|  |                      <img src="../cms_admin/<?php echo htmlspecialchars($row['image']); ?>" alt=""> | |||
|  |                   </div> | |||
|  |                   <div class="career-page-top__content-box mt-5"> | |||
|  |                      <div class="career-page-top__job-apply-box"> | |||
|  |                         <div class="career-page-top__job-apply-left"> | |||
|  |                            <div class="career-page-top__job-apply-icon"> | |||
|  |                               <img src="../cms_admin/<?php echo htmlspecialchars($row['icon']); ?>" alt=""> | |||
|  |                            </div> | |||
|  |                            <div class="career-page-top__job-apply-details-box"> | |||
|  |                               <h3 class="career-page-top__job-apply-title"><a href="#"><?php echo $product_title; ?></a></h3>
 | |||
|  |                               <ul class="career-page-top__job-apply-theme-list list-unstyled"> | |||
|  |                                  <li><p><?php echo $category_name; ?></p></li>
 | |||
|  |                               </ul> | |||
|  |                            </div> | |||
|  |                         </div> | |||
|  |                         <div class="career-page-top__job-apply-right"> | |||
|  |                            <div class="career-page-top__job-apply-btn-box"> | |||
|  |                               <a href="<?php echo htmlspecialchars($row['tracking_link']); ?>" class="career-page-top__job-apply-btn thm-btn">立即获取<span class="icon-arrow-right"></span></a> | |||
|  |                            </div> | |||
|  |                         </div> | |||
|  |                      </div> | |||
|  |                      <div class="career-page-top__content-box-two"> | |||
|  |                         <h3 class="career-page-top__title-1">产品说明</h3> | |||
|  |                         <p class="career-page-top__text-1" style="line-height:1.9;"><br><?php echo $long_description; ?></p>
 | |||
|  |                      </div> | |||
|  |                   </div> | |||
|  |                </div> | |||
|  |                <div class="career-page-top__interested-job"> | |||
|  |                   <div class="career-page-top__interested-job-title-box"> | |||
|  |                      <h3 class="career-page-top__interested-job-title">有兴趣获得这个工具吗?</h3> | |||
|  |                      <p class="career-page-top__interested-job-sub-title">点击按钮,享受AI带来的乐趣</p> | |||
|  |                   </div> | |||
|  |                   <div class="career-page-top__interested-job-btn-box"> | |||
|  |                      <a href="<?php echo htmlspecialchars($row['tracking_link']); ?>" class="career-page-top__interested-job-btn thm-btn">立即获取 <span class="icon-arrow-right"></span></a> | |||
|  |                   </div> | |||
|  |                </div> | |||
|  |             </div> | |||
|  |          </div> | |||
|  |       </section> | |||
|  |       <!-- Career Page End Start --> | |||
|  | 
 | |||
|  |       <!-- Free Trail Start --> | |||
|  |       <?php include 'container/free_trail.php'; ?>
 | |||
|  |       <!-- Free Trail End --> | |||
|  |       <!-- Main Footer Start --> | |||
|  |       <?php include 'container/footer.php'; ?>
 | |||
|  |       <!-- Main Footer End --> | |||
|  |       <?php include 'container/footer_links.php'; ?>
 | |||
|  |    </body> | |||
|  | </html> |