<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="format-detection" content="telephone=no" />
<meta name="renderer" content="webkit" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title><?php echo $system_title?></title>
<?php if ($system_keywords != '') { ?>
<meta name="keywords" content="<?php echo $system_keywords;?>" />
<?php } ?>
<?php if ($system_description != '') { ?>
<meta name="description" content="<?php echo $system_description;?>" />
<?php } ?>
<?php include($dir.$t_path.'inc_head.php');?>
<script type="text/javascript">
$(function(){
	$('.home a').addClass('current');
});
</script>
</head>
<body>
<?php include($dir.$t_path.'inc_header.php');?>
<div id="slideshow" class="oh">
	<div class="bd">
		<ul>
		<?php
		$result = sql_query('select * from cms_slideshow where s_parent = 1 order by s_order asc , id asc');
		while ($row = sql_fetch_array($result)){
		?>
		<li><a href="<?php echo ($row['s_url'] == '') ? 'javascript:;' : $row['s_url'] ;?>"><img style="max-height: <?php echo $system_slideshow;?>px;" src="<?php echo $row['s_picture'];?>" alt="<?php echo $row['s_name'];?>" title="<?php echo $row['s_name'];?>"></a></li>
		<?php
		}
		?>
		</ul>
	</div>
	<div class="hd">
		<ul>
		</ul>
	</div>
	<div class="next hide"></div> <div class="prev hide"></div>
</div>
<div id="search_wrap">
	<div class="container">
		<div class="line">
			<div class="x9">
				<div class="hot_keywords">
				<span class="fb">热门关键词：</span>
				<?php
				$arr_key = explode('|',$system_hotkeywords);
				foreach( $arr_key as $key => $value ){
					echo '<a href="search.php?key='.$value.'">'.$value.'</a> ';
				}
				?>
				</div>
			</div>
			<div class="x3">
				<div class="header_search">
					<form method="get" action="search.php">
						<input class="search_text" type="text" name="key" placeholder="请输入要查找的关键词" />
						<input class="search_btn" type="submit" value="搜索" />
					</form>
				</div>
			</div>
		</div>
	</div>
</div>
<div id="index_products">
	<div class="container">
		<?php
		$results = sql_query('select * from cms_channel where id = 3');
		if ($rows = sql_fetch_array($results)) {
		$products_twidth = ($rows['c_twidth'] != 0) ? $rows['c_twidth'] : $system_twidth ;
		$products_theight = ($rows['c_theight'] != 0) ? $rows['c_theight'] : $system_theight ;
		?>
		<div class="caname"><?php echo $rows['c_aname'];?></div>
		<div class="cname"><?php echo $rows['c_name'];?></div>
		<div class="cseoname"><?php echo $rows['c_seoname'];?></div>
		<div class="products-clist">
			<?php
			$result = sql_query('select * from cms_channel where c_parent = '.$rows['id'].' order by c_order asc , id asc');
			while ($row = sql_fetch_array($result)){
			?>
			<a href="<?php echo c_url($row['id']);?>"><?php echo $row['c_name'];?></a>			<?php
			}
			?>
		</div>
		<div class="l40 plist wow bounceIn">
			<?php
			$result = sql_query('select id,d_name,d_picture,d_scontent,d_date from cms_detail where d_parent in ('.$rows['c_sub'].') order by d_order desc , id desc limit 0, 6');
			while($row = sql_fetch_array($result)){
			?>
			<div class="x4">
				<div class="wrap mb40 hover-pulse">
					<div class="products_thumbnail"><a href="<?php echo d_url($row['id'])?>" target="_blank" title="<?php echo $row['d_name'];?>"><img src="<?php echo $row['d_picture'];?>" title="<?php echo $row['d_name'];?>" alt="<?php echo $row['d_name'];?>"/></a></div>
					<div class="title cut"><a href="<?php echo d_url($row['id'])?>" target="_blank" title="<?php echo $row['d_name'];?>"><?php echo $row['d_name'];?></a></div>
				</div>
			</div>
			<?php
			}
			?>
		</div>
		<div class="cmore"><a class="btn bg-main" href="<?php echo c_url($rows['id']);?>">查看所有<?php echo $rows['c_sname'];?>+</a></div>
		<script type="text/javascript">
		$(function() {
			<?php if ($system_thumbnail == 1) { ?>
				var products_thumbnail = $('.products_thumbnail');
				products_thumbnail.find('img').jqthumb({
					width: products_thumbnail.width(),
					height: products_thumbnail.width() / <?php echo $products_twidth;?> * <?php echo $products_theight;?>

				});
			<?php } ?>
		});
		</script>
		<?php } ?>
	</div>
</div>
<div id="index_honor" >
	<div class="container wow bounceInDown">
		<?php
		$results = sql_query('select * from cms_channel where id = 4');
		if ($rows = sql_fetch_array($results)) {
		$honor_twidth = ($rows['c_twidth'] != 0) ? $rows['c_twidth'] : $system_twidth ;
		$honor_theight = ($rows['c_theight'] != 0) ? $rows['c_theight'] : $system_theight ;
		?>
		<div class="caname"><?php echo $rows['c_aname'];?></div>
		<div class="cname"><?php echo $rows['c_name'];?></div>
		<div class="cseoname"><?php echo $rows['c_seoname'];?></div>

		<div id="honor_slideshow" >
			<div class="oh">
				<div class="l40 bd plist">
				<?php
				$result = sql_query('select id,d_name,d_picture,d_scontent,d_date from cms_detail where d_parent in ('.$rows['c_sub'].') order by d_order desc , id desc limit 0, 18');
				while($row = sql_fetch_array($result)){
				?>
				<div class="x3">
					<div class="wrap">
						<div class="honor_thumbnail"><a href="<?php echo d_url($row['id'])?>" target="_blank" title="<?php echo $row['d_name'];?>"><img src="<?php echo $row['d_picture'];?>" title="<?php echo $row['d_name'];?>" alt="<?php echo $row['d_name'];?>"/></a></div>
						<div class="title cut"><a href="<?php echo d_url($row['id'])?>" target="_blank" title="<?php echo $row['d_name'];?>"><?php echo $row['d_name'];?></a></div>
					</div>
				</div>
				<?php
				}
				?>
				</div>
				<div class="prev_next">
					<div class="prev"><span class="icon-arrow-circle-o-left"></span></div>
					<div class="next"><span class="icon-arrow-circle-o-right"></span></div>
				</div>
			</div>
		</div>
		<script type="text/javascript">
		$(function() {
			$('#honor_slideshow').slide({
				autoPlay: true,
				vis: 4,
				mainCell: '.bd',
				titCell: '.hd li',
				effect: 'leftLoop',
				trigger: 'mouseover'
			});
			<?php if ($system_thumbnail == 1) { ?>
				var honor_thumbnail = $('.honor_thumbnail');
				honor_thumbnail.find('img').jqthumb({
					width: honor_thumbnail.width(),
					height: honor_thumbnail.width() / <?php echo $honor_twidth;?> * <?php echo $honor_theight;?>

				});
			<?php } ?>

		});
		</script>
		<?php } ?>
	</div>

</div>
<div id="index_about">
	<div class="container wow rotateIn">
		<?php
		$results = sql_query('select * from cms_channel where id = 1');
		if ($rows = sql_fetch_array($results)) {
		?>
		<div class="caname"><?php echo $rows['c_aname'];?></div>
		<div class="cname"><?php echo $rows['c_name'];?></div>
		<div class="cseoname"><?php echo $rows['c_seoname'];?></div>
		<div class="cscontent mt50"><?php echo $rows['c_scontent'];?></div>
		<?php } ?>
	</div>
</div>
<div id="index_news">
	<div class="container">
		<?php
		$results = sql_query('select * from cms_channel where id = 2');
		if ($rows = sql_fetch_array($results)) {
		?>
		<div class="caname"><?php echo $rows['c_aname'];?></div>
		<div class="cname"><?php echo $rows['c_name'];?></div>
		<div class="cseoname"><?php echo $rows['c_seoname'];?></div>
		<div class="l20 mt50">
			<div class="x6 wow fadeInLeft">
				<div id="news_slide">
					<div class="bd">
					<?php
					$result = sql_query('select id,d_name,d_picture,d_scontent,d_date from cms_detail where d_parent in ('.$rows['c_sub'].') order by d_order desc , id desc limit 0, 8');
					while($row = sql_fetch_array($result)){
					?>
					<div class="wrap">
						<div class="img"><a href="<?php echo d_url($row['id']);?>"><img src="<?php echo $row['d_picture'];?>" ></a></div>
						<div class="title"><a href="<?php echo d_url($row['id']);?>"><?php echo $row['d_name'];?></a></div>
					</div>
					<?php
					}
					?>
					</div>
					<div class="hd">
						<ul></ul>
					</div>
				</div>
				<script type="text/javascript">
				$(function() {
					$('#news_slide').slide({
						autoPlay: true,
						interTime: 2500,
						delayTime: 500,
						autoPage: true,
						mainCell: '.bd',
						titCell: '.hd ul',
						effect: 'leftLoop',
						trigger: 'click'
					});
				});
				</script>
			</div>
			<div class="x6 wow fadeInRight">
				<ul class="alist">
					<?php
					$result = sql_query('select id,d_name,d_picture,d_scontent,d_date from cms_detail where d_parent in ('.$rows['c_sub'].') order by d_order desc , id desc limit 0, 10');
					while($row = sql_fetch_array($result)){
						echo '<li class="cut"><span class="fr">'.date('m-d',$row['d_date']).'</span><a href="'.d_url($row['id']).'" title="'.$row['d_name'].'">'.$row['d_name'].'</a></li>';
					}
					?>
				</ul>
			</div>
		</div>
		<?php } ?>

	</div>
</div>
<div class="mt50">
	<div class="container">
		<div class="l20">
			<div class="x4 wow fadeInRight">
				<?php
				$result = sql_query('select * from cms_channel where id = 6');
				if ($row = sql_fetch_array($result)) {
				?>
				<div class="index_hd">
					<div class="name_wrap">
						<div><?php echo $row['c_name'];?></div>
						<div class="aname"><?php echo $row['c_aname'];?></div>
						<div class="more"><a href="<?php echo c_url(6);?>">MORE+</a></div>
					</div>
				</div>
				<div class="index_bd">
					<?php echo $row['c_scontent'];?>
				</div>
				<?php } ?>
			</div>
			<div class="x8 wow fadeInLeft">
				<?php
				$results = sql_query('select * from cms_channel where id = 5');
				if ($rows = sql_fetch_array($results)) {
				$case_twidth = ($rows['c_twidth'] != 0) ? $rows['c_twidth'] : $system_twidth ;
				$case_theight = ($rows['c_theight'] != 0) ? $rows['c_theight'] : $system_theight ;
				?>
				<div class="index_hd">
					<div class="name_wrap">
						<div><?php echo $rows['c_name'];?></div>
						<div class="aname"><?php echo $rows['c_aname'];?></div>
						<div class="more"><a href="<?php echo c_url($rows['id']);?>">MORE+</a></div>
					</div>
				</div>
				<div class="index_bd">
					<div id="case_slide">
						<div class="oh">
							<div class="l20 bd" >
								<?php
								$result = sql_query('select id,d_name,d_picture,d_scontent,d_date from cms_detail where d_parent in ('.$rows['c_sub'].') order by d_order desc , id desc limit 0, 3');
								while($row = sql_fetch_array($result)){
								?>
								<div class="x4">
									<div class="wrap mb20">
										<div class="case_thumbnail"><a href="<?php echo d_url($row['id'])?>" target="_blank" title="<?php echo $row['d_name'];?>"><img src="<?php echo $row['d_picture'];?>" title="<?php echo $row['d_name'];?>" alt="<?php echo $row['d_name'];?>"/></a></div>
										<div class="title cut"><a href="<?php echo d_url($row['id'])?>" target="_blank" title="<?php echo $row['d_name'];?>"><?php echo $row['d_name'];?></a></div>
									</div>
								</div>
								<?php
								}
								?>
							</div>
						</div>
						<div class="prev_next">
							<div class="prev"><span class="icon-arrow-circle-o-left"></span></div>
							<div class="next"><span class="icon-arrow-circle-o-right"></span></div>
						</div>
					</div>
				</div>
				<script type="text/javascript">
				$(function() {
					$('#case_slide').slide({
						autoPlay: true,
						interTime: 2500,
						delayTime: 500,
						scroll: 1,
						vis: 3,
						effect: 'leftLoop',
						trigger: 'click'
					});
				});

				$(function() {
					<?php if ($system_thumbnail == 1) { ?>
						var case_thumbnail = $('.case_thumbnail');
						case_thumbnail.find('img').jqthumb({
							width: case_thumbnail.width(),
							height: case_thumbnail.width() / <?php echo $case_twidth;?> * <?php echo $case_theight;?>
						});
					<?php } ?>
				});
				</script>
				<?php } ?>
			</div>
		</div>
	</div>
</div>

<div id="index_link">
	<div class="container">
		<div class="bd1">
			<div class="link_text">
				<div class="l10">
					<?php
					$result = sql_query('select * from cms_link where l_picture = "" order by l_order asc , id asc');
					while ($row = sql_fetch_array($result)){
						echo '<div class="a8"><a href="'.$row['l_url'].'" target="_blank">'.$row['l_name'].'</a></div>';
					}
					?>
				</div>
			</div>
			<div class="link_picture">
				<div class="l10">
					<?php
					$result = sql_query('select * from cms_link where l_picture <> "" order by l_order asc , id asc');
					while ($row = sql_fetch_array($result)){
						echo '<div class="a8"><a href="'.$row['l_url'].'" target="_blank"><img src="'.$row['l_picture'].'" alt="'.$row['l_name'].'" title="'.$row['l_name'].'"></a></div>';
					}
					?>
				</div>
			</div>
		</div>
	</div>
</div>
<?php include($dir.$t_path.'inc_footer.php');?>
</body>
</html>
