<fh-function>

$sql="select * from sl_course,sl_usort where C_sort=S_id and C_id=".$id;
  $result = mysqli_query($conn, $sql);
  $row = mysqli_fetch_assoc($result);
  if (mysqli_num_rows($result) > 0) {
    $S_id=$row["S_id"];
    $C_id=$row["C_id"];
    $C_pic=$row["C_pic"];
    $C_price=$row["C_price"];
    $C_lesson=$row["C_lesson"];
    $P_mid=$row["P_mid"];
  }
</fh-function>
<!DOCTYPE HTML>
<html class="  ">
<head>
<meta name="renderer" content="webkit">
<meta charset="utf-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimal-ui">
<meta name="generator" content="author"  data-variable="/,cn,10001,,10001,M1156014" />
<title>[C_title] - [fh_title]</title>
<link href="media/[fh_ico]" rel="shortcut icon" />
<meta name="description" content="[P_description]" />
<meta name="keywords" content="[P_keywords]" />

<link rel='stylesheet' href='template/t13/skin/css/index.css'>
<script src="template/t13/skin/js/shop_lang_cn.js"></script> 
<script src="template/t13/skin/js/index.js"></script> 
<style>
#buy .add{
  height:25px; width:25px; margin:0 5px 0 5px;line-height:100%;
  border: hidden;
  background-color: #f32196;
  color: #FFFFFF;
  font-size: 15px;
  line-height: 100%;
  cursor: pointer;
  border-radius:3px;
}

#buy .add:hover {
  border: #f32196 solid 1px;
  background-color: #FFFFFF;
  color: #f32196;
}

#amount{
  border-top:1px solid #ABADB3;
  border-left:1px solid #ABADB3;
  border-right:1px solid #ddd;
  border-bottom:1px solid #ddd;
  height:24px;
  width:50px;
  padding:0 5px;
  line-height:100%;

}
.btn{padding: 5px;margin-top: 10px;}
.tag{}
</style>
</head>
<body>
<!--[if lte IE 8]>
<div class="text-center padding-top-50 padding-bottom-50 bg-blue-grey-100">
  <p class="browserupgrade font-size-18">
  你正在使用一个<strong>过时</strong>的浏览器。请<a href="http://browsehappy.com/" target="_blank">升级您的浏览器</a>，以提高您的体验。
  </p>
</div>
<![endif]-->
<div class="load-box"></div>
<header>
  <div class="head-box" style="background: #ffffff;height: 70px;">
    <div class="container">
      <div class="head-left">
        <div class="head-left-wrapper">
          <div class="head-left-slide">
            <div class="logo-box" style="height: 70px;line-height: 70px;"> <a href="./" title="[fh_title]"> <img src="media/[fh_logo]" alt="[fh_title]" style="max-height: 70px"> </a> </div>
            <div class="search-box hidden-xs" style="margin: 15px ">
          <div class="search-cut">
            <form  name="formsearch" action="./?type=search" method="post" style="border: solid 1px #EEEEEE;border-radius: 20px; ">
              <input type="text" name="keyword" value="" placeholder="输入关键词" style="border-radius: 20px;border: none;height: 40px">
              <button class="fa fa-search" type="submit" style="border-radius: 25px;border: none;height: 40px;line-height: 38px"></button>
            </form>
          </div>
        </div>
          </div>
        </div>
      </div>
      <div style="position: absolute;top: 15px;right: 10px;">
        <div style="display: inline-block;" class="hidden-xs">
        <a href="member/history.php?type=2">学习记录</a> &nbsp;|&nbsp; 
        <a href="member/vip.php">会员特权</a>&nbsp; &nbsp; &nbsp; 
      </div>
      
      <div style="background: #FFD500;border-radius: 20px;padding: 0 20px;top:15px;display: inline-block;"> 
        <fh-function>
      if($_SESSION["M_login"]==""){
        $api="<a class=\"login\" href=\"member/login.php\">登录</a>
              &nbsp;|&nbsp;
              <a class=\"login\" href=\"member/reg.php\">注册</a>";
      }else{
        $api="<a class=\"login\" href=\"member\">".$_SESSION["M_login"]."</a>
              &nbsp;|&nbsp;
              <a class=\"login\" href=\"member/login.php?action=unlogin\">退出</a>";
      }
      </fh-function>
      </div>
      </div>
    </div>
  </div>
  <nav>
    <div class="neck-box" style="background: #f7f7f7">
      <div class="container">
        <div class="nav-box index" style="margin: 5px;float: left;">
          
          <div class="nav-cut">
            <ul class="nav-ul">

              <fh-function>
                $sql="select * from sl_menu where U_hide=0 and U_del=0 and U_sub=0 order by U_order,U_id desc";
                s[[
                  if($type==$row["U_type"] && $id==$row["U_typeid"]){
                    $class="nav-li active";
                  }else{
                    $class="nav-li margin-left-0";
                  }

                  if($row["U_type"]=="link"){
                    $link=$row["U_link"];
                    $target="_blank";
                  }else{
                    $link="?type=".$row["U_type"]."&id=".$row["U_typeid"];
                    $target="_self";
                  }
                    $api=$api."<li class=\"".$class."\"><a href=\"".$link."\" target=\"".$target."\" title=\"".$row["U_title"]."\" >".$row["U_title"]."</a></li>";
                ]]

              </fh-function>
            </ul>
          </div>
          <div class="nav-hover">

            <fh-function>
            $sql="select * from sl_menu where U_hide=0 and U_del=0 and U_sub=0 order by U_order,U_id desc";
                s[[
                $api=$api."<ul>";

                    $sql2="select * from sl_menu where U_hide=0 and U_del=0 and U_sub=".$row["U_id"]." order by U_order,U_id desc";
                    s2[[
                      
                      if($row2["U_type"]=="link"){
                        $link2=$row2["U_link"];
                        $target="_blank";
                      }else{
                        $link2="?type=".$row2["U_type"]."&id=".$row2["U_typeid"];
                        $target="_self";
                      }
                            $api=$api."<li><a href=\"".$link2."\" target=\"".$target."\" title=\"".$row2["U_title"]."\" >".$row2["U_title"]."</a></li>";
                        ]]

                  $api=$api."</ul>";
                    ]]
            </fh-function>
            
          </div>
        </div>
      </div>
    </div>
  </nav>
  <div class="met-banner-ny vertical-align text-center" style=''>
    <h1 class="vertical-align-middle" style='color:#ffffff;'>[S_title]</h1>
  </div>
</header>
<div class="met-position  pattern-show">
  <div class="container">
    <div class="row">
      <ol class="breadcrumb">
        <li> <i class="icon wb-home" aria-hidden="true"></i><a href='./'>主页</a> > <a href='?type=course&id=[S_id]'>[S_title]</a> > [C_title] > </li>
      </ol>
    </div>
  </div>
</div>
<div class="page met-showproduct pagetype1">
  <div class="met-showproduct-head">
    <div class="container">
      <div class="row">
        <div class="col-md-6">
          <div class='met-showproduct-list fngallery text-center slick-dotted' id="met-imgs-carousel">
            <fh-function>
            $pic=explode("|",$C_pic);
            for($i=0;$i<count($pic);$i++){
              $api=$api."<div class=\"slick-slide lg-item-box\" data-src=\"".pic($pic[$i])."\" data-exthumbimage=\"".pic($pic[$i])."\"> <span> <img src=\"".pic($pic[$i])."\" data-src=\"".pic($pic[$i])."\" class=\"img-responsive\" alt=\"\" height=\"210\" width=\"380\" title=\"\">               </span> </div>";
            }
            </fh-function>
          </div>
        </div>

        <div class="col-md-6 product-intro">
          <h1 class='font-weight-300'>[C_title]</h1>

          <div class="shop-product-intro grey-500">
            <div class="padding-20 bg-grey-100 price red-600"> 价格：￥<span id="price">[C_price]</span>[C_vip]</div>
            
            <div class="form-group inline-block margin-top-30">
              <input type="button" name="button" class="btn btn-lg btn-squared btn-primary margin-right-10" onClick="window.location.href='?type=courseinfo&id=[C_id]'" value="开始学习" />
              <div id="collection_course" cid="[C_id]" style="display: inline-block;margin-top: 25px;vertical-align: top;"></div>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
  <div class="met-showproduct-body">
    <div class="container mobile-not-padding">
      <div class="row">
        <div class="col-md-9">
          <div class="product-content-body">
            <div class="panel product-detail">
              <div class="panel-body">
                <ul class="nav nav-tabs nav-tabs-line met-showproduct-navtabs affix-nav">
                  <li class="active"><a data-toggle="tab" href="#product-details" data-get="product-details">课程介绍</a></li>
                  <li><a data-toggle="tab" href="#list" data-get="product-details">课程目录</a></li>
                  <li><a data-toggle="tab" href="#evaluate" data-get="product-details">购买记录</a></li>
                </ul>
                <div class="tab-content">
                  <div class="tab-pane met-editor lazyload clearfix active" id="product-details"> 

                    [C_content]
                  </div>
                  <div class="tab-pane met-editor lazyload clearfix" id="list"> 
                    <style>
                    .z{background: #f7f7f7;font-weight: bold;line-height: 50px;padding: 0 20px}
                    .k{line-height: 50px;padding: 0 20px;display: block;}
                    .free{color: #009900}
                    .k:hover{background: #f32196;color: #ffffff;}
                    .k:hover .free{color: #ffffff}
                    .k .l{width: calc(100% - 80px);display:inline-block;height: 32px;white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    word-break: break-all;}
                  </style>
                    <fh-function>
$lesson=explode("||",$C_lesson);
$m=0;
$n=0;
      for($i=0;$i<count($lesson);$i++){
      if(strpos($lesson[$i],"_")!==false){


      if(splitx($lesson[$i],"__",1)==0 || $C_price==0){
        $price="<span class=\"free\">[免费]</span>";
      }else{
      $price="";
    }

      if($page==$m+1){
      $active="active";
    }else{
    $active="";
  }
    $api=$api."<a class=\"k\" href=\"./?type=courseinfo&id=[C_id]&page=".($m+1)."\"><div class=\"l\">课时".($m+1)."：".splitx($lesson[$i],"__",0)."</div><span style=\"float:right\">".$price." ".splitx($lesson[$i],"__",3)."</span></a>";
$m=$m+1;
    }else{
    $api=$api."<div class=\"z\">章节".($n+1)."：".$lesson[$i]."</div>";
$n=$n+1;
  }
      }
</fh-function>
                  </div>

                  <div class="tab-pane met-editor lazyload clearfix" id="evaluate"> 

<fh-function>
              $sql="select * from sl_orders,sl_member where O_state>0 and O_mid=M_id and O_cid=".$C_id." and O_del=0 order by O_id desc";
              $result = mysqli_query($conn,  $sql);
                if (mysqli_num_rows($result) > 0) {
                while($row = mysqli_fetch_assoc($result)) {
$api=$api."<p><b>用户：".enname($row["M_login"])."</b> 购买了 <span style=\"color: #f32196\">".$row["O_title"]."</span> <br><span style=\"color: #AAAAAA\">".$row["O_time"]." </span></p>";
                }
              }else{
              $api=$api."<div>暂无购买记录</div>";
            }
            </fh-function>
                  </div>

                </div>
              </div>
            </div>
          </div>
        </div>
        <div class="col-md-3">

<fh-function>
if($P_mid>0){
  $api=$api."<div class=\"panel product-hot\">
            <div class=\"panel-body\">
              <h2 class=\"margin-bottom-15 font-size-16 font-weight-300\">店铺信息 <div id=\"collection_shop\" style=\"float:right\" mid=\"".$P_mid."\"></div></h2>
              <img src=\"media/".getrs("select * from sl_member where M_id=$P_mid","M_head")."\" style=\"height:50px;border-radius:10px;margin-right:10px;display:inline-block;vertical-align:top\"> 
              <div style=\"display:inline-block\"><b><a href=\"./shop.php?M_id=".$P_mid."\">".getrs("select * from sl_member where M_id=$P_mid","M_shop")."</a></b><br><a href=\"http://wpa.qq.com/msgrd?v=3&uin=".getrs("select * from sl_member where M_id=$P_mid","M_qq")."&site=qq&menu=yes\">QQ：".getrs("select * from sl_member where M_id=$P_mid","M_qq")."</a></div>
            <div style=\"margin-top:10px;\"><b>店铺公告：</b>";
            $api=$api.getrs("select * from sl_member where M_id=$P_mid","M_notice");
        $api=$api."</div></div></div>";
}
</fh-function>
          

          <div class="panel product-hot">
            <div class="panel-body">
              <h2 class="margin-bottom-15 font-size-16 font-weight-300">热门推荐</h2>
              <ul class="blocks-2 blocks-sm-3 blocks-md-100 blocks-xlg-100  mob-masonry" data-scale='1'>

                <fh-function>
                $sql="select * from sl_course where C_del=0  and C_sort=$S_id order by C_order,C_id desc limit 5";
                s[[
            

                  $api=$api."<li> <a href=\"?type=courseintro&id=".$row["C_id"]."\" class=\"img\" title=\"".$row["C_title"]."\"> <img src=\"".pic(splitx($row["C_pic"],"|",0))."\" class=\"cover-image\" style=\"height:200px;\" alt=\"".$row["C_title"]."\"> </a> <a href=\"?type=courseintro&id=".$row["C_id"]."\" class=\"txt\" title=\"".$row["C_title"]."\">".$row["C_title"]."</a>
                  <p class='margin-bottom-0 red-600'>￥".p($row["C_price"])."</p>
                </li>";
                ]]
                </fh-function>
              </ul>
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</div>
<link rel='stylesheet' href='template/t13/skin/css/shop_v3.css'>
<div style="padding-top: 20px;">
<div class="container">
  
<p>
<img src="media/[fh_logo]" alt="[fh_title]" style="margin-bottom: 10px;max-width: 200px">
</p>
<p>
<fh-function>
                $sql="select * from sl_menu where U_hide=0 and not U_type='index' and not U_type='link' and U_del=0 and U_sub=0 order by U_order,U_id desc";
                s[[
                  $api=$api."<a style=\"margin-right:20px\" target=\"_blank\" href=\"?type=".$row["U_type"]."&id=".$row["U_typeid"]."\"  title=\"".$row["U_title"]."\">".$row["U_title"]."</a> ";
                  ]]

            
        </fh-function>
</p>
<img src="media/[fh_qrcode]" style="width: 80px;float: right;margin-top: -120px">

  
</div>
<hr>

  <div class="container">
    <div class="met-links">
      <ol class="breadcrumb">
        <a style="margin-right:30px;font-size:13px;">友情链接 :</a>
        <fh-function>
        $sql="select * from sl_link where L_del=0 order by L_id desc";
        s[[$api=$api."<a style=\"margin-right:30px;font-size:13px;\" href=\"".$row["L_link"]."\" target=\"_blank\">".$row["L_title"]."</a>";]]
        </fh-function>
      </ol>
    </div>

<div style="margin: 20px 0;">
    [fh_copyright][fh_beian][fh_code] 在线客服：<a href="?type=contact">联系客服</a>
  </div>

  </div>
</div>
<button type="button" class="btn btn-icon btn-primary btn-squared met-scroll-top hide"><i class="icon wb-chevron-up" aria-hidden="true"></i></button>
<button type="button" onclick="window.location.href='member/cart.php'" class="btn btn-icon btn-primary btn-squared met-scroll-top hide" style="bottom: 50px;"><i class="icon wb-shopping-cart" aria-hidden="true"></i></button>

[fh_kefu]
</body>
</html>