<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>$keywords_array[k_title]</title>
<meta name="keywords" content="$keywords_array[k_keywords]" />
<meta name="description" content="$keywords_array[k_description]" />
<link href="{$BASE_V}style.css" rel="stylesheet" type="text/css" />
<script language="javascript">var webpath="{$BASE}";</script>
<script type="text/javascript" src="{$BASE}js/calendar/jquery.min.js"></script>
<script type="text/javascript" src="{$Order_api}room.utf8.js"></script>
<link href="{$Order_api}/room.utf8.css" rel="stylesheet" type="text/css" />
</head>
<body>
<!--{template inc/header}-->
<div id="maincontent">
    <div class="index_content">
        <div class="leibiao_list">
            <DIV id=soso_17u>
                <H3>酒店搜索</H3>
                <DIV class=search_right>
                    <DIV class="search_content search_ba">
                        <!--{template inc/hotel_search}-->
                    </DIV>
                </DIV>
            </DIV>
            <div class="blue_ce" id="hotel_near">
                <div class="lie_blue">
                    <h3>附近酒店</h3>
                </div>
                <DIV class="bd_info">
                    <UL class=faq>
                        <!--{model:hotelinfo getNearbyHotels($info['NearbyHotels'], 10, 'limit') return=nearbyHotels_ary_b}-->
                        <!--{loop $nearbyHotels_ary_b[rs] $k $v}-->
                        <LI>
                            <P><SPAN class=price>￥$v[min_price]</SPAN> <a href='{PHP_SELF}?m=hotelinfo&hotel_id=$v[hotel_id]' title='$v[hotelname]'>$v[hotelname_strlen]</a> </P>
                            <P>相距：$v[juli]公里</P>
                        </LI>
                        <!--{/loop}-->
                    </UL>
                </DIV>
            </div>
			<!--{template inc/hotel_welcome}-->						
			<!--{template inc/lable}-->
			<!--{template inc/hotel_news}-->
			<!--{template inc/hotel_history}-->
			<!--{template inc/why}-->
            <!--{template inc/help}-->
        </div>
        <div class="list_nrttj">
            <div class="hty_nav"> <span>您所在位置：</span> <a href="/">首页</a> &gt;&nbsp;<a href="{PHP_SELF}?m=allcity">全国酒店</a> &gt; <a href="{PHP_SELF}?m=city&cityid=$info[CityID]">$info[CityName]酒店</a> &gt;&nbsp;<a href="{PHP_SELF}?m=hotellist&cityid=$info[CityID]&rank=${common::hotelranknamenum($info[star])}">{$info[CityName]}${common::hotelrankname($info[star])}酒店</a>&gt;&nbsp;$info[HotelName] </div>
            <DIV class="hotel_introduce">
                <H1>$info[HotelName]</H1>
                <P class="p_show" id="hotelinfo" showvalue="${echo preg_replace("/<a[^>]+>(.+?)<\/a>/i","$1",$content);}"><span>${echo Functions::cut_str(strip_tags($content),100);}</span><a class="indceDown" href="javascript:void(0)">详细信息</a>
                </P>
                <DIV class=clear_float></DIV>
            </DIV>
            <div class="viewcut"> 
	            <a class="current02" href="#">酒店概况</a>
	            <a href="#hotel_comment">酒店点评</a>
	            <a href="#hotel_question">酒店问答</a>
	            <a href="#hotel_map">酒店地图</a> 
	            <a href="#hotel_near">附近酒店</a>  
            </div>
            <div class="infost">
                <div class="top" >
                    <div class="Container" style="width: 269px; height: 178px;">
                        <ul class="Slider" id="Slider" style="top: 1px;">
                            <!--{model:hotelinfo hpicshow($info[Hotelpictures]) return=pic_array}-->
                            <!--{loop $pic_array $v}-->
                            <li><img alt="$v[pic_name]" src='{$picurl}{$v[pic_url]}' width="269" height="178" border='0' /></li>
                            <!--{/loop}-->
                        </ul>
                        <ul class="rotatorNumber" id="numeric">
                            <!--{loop $pic_array $k $v}-->
                            <li>${echo $k+1}</li>
                            <!--{/loop}-->
                        </ul>
                    </div>
                </div>
                <DIV class="info_news">
                    <UL>
                        <LI>酒店等级：<a href="{PHP_SELF}?m=hotellist&cityid=$info[CityID]&rank=${common::hotelranknamenum($info[star])}">${common::hotelrankname($info[star])}</a> </LI>
                        {if $info[Address]<>""}
                        <LI>酒店地址：$info[Address]</LI>
                        {/if}
                        {if $info[Tags]<>""}
                        <LI>客人印象：
                            <!--{model:hotelinfo tags_ary($info[Tags]) return=tags_ary}-->
                            <!--{loop $tags_ary $v}-->
                            <span>$v</span>
                            <!--{/loop}-->
                        </LI>
                        {/if}
                        {if $info[kaiye]<>""}
                        <LI>开业时间：{$info[kaiye]}</LI>
                        {/if}
                        {if $info[zhuangxiu]<>""}
                        <li>装修时间：{$info[zhuangxiu]}</li>
                        {/if}
                        {if $info[cbd_name]<>""}
                        <LI>商业区域：<a href="{PHP_SELF}?m=hotellist&cityid=$info[CityID]&cbd_id=$info[cbd_id]">$info[cbd_name]</a> </LI>
                        {/if}
                    </UL>
                </DIV>
            </div>
            <DIV class="roomsyBox mtop">
                <DIV class=roomsy_head>
                    <H3>房型价格</H3>
                    <div class="info_yuding03">
                        <ul>
                            <li class="info_ruli">入住日期：
                                <input name="txtComeDate" type="text" value="$sk_array[tm1]" id="txtComeDate" class="info_ruzhu" onClick="javascript:event.cancelBubble=true;showCalendar('txtComeDate',false,'txtComeDate','txtOutDate','txtOutDate','$sk_array[tm1]','','','','','text','')"/>
                                &nbsp;离店日期：
                                <input name="txtOutDate" type="text" value="$sk_array[tm2]" id="txtOutDate" class="info_ruzhu" onClick="javascript:event.cancelBubble=true;showCalendar('txtOutDate',false,'txtOutDate','','','$sk_array[tm2]','','','','','text','')"/>
                                <input name="ebooking" type="button" value="修改" onClick="refreshprice('$info[hotel_id]','$Order_api');" class="form_but01" />
                            </li>
                        </ul>
                    </div>
                </DIV>
                <DIV class="fangxingnr">
                    <div style="padding-left:8px;" class="fang_news">
                        <div id='h$info[hotel_id]'>
                            <p style="text-align:center;"><img src="{$BASE_V}images/loadprice.gif" /></p>
                        </div>
                    </div>
                </DIV>
            </DIV>
            <div class="roomsyBox mtop" id="hotel_map">
                <div class="fangxingnr">
                    <DIV class="info_index_map">
                        <div id="DP_Map_Show" style="width:732px;height:350px;border:0px #CCC solid;margin-left:7px;"></div>
                    </DIV>
                </div>
            </div>
            <div class="roomsyBox mtop" id="hotel_comment">
                <div class="roomsy_head">
                    <H3>客人点评</H3>
                </div>
	            <div class="infost">
	                <div id="comment_index_body"><img align="absmiddle" src="{$BASE}js/loading.gif"/>最新酒店点评正在努力加载中...</div>
	            </div>                
            </div>
            <div class="roomsyBox mtop">
                <div class="roomsy_head">
                    <h3>交通指南</h3>
                </div>
                <div class="fangxingnr">
                    <DIV class="depBlue_main"> 位置距离：${hotelinfo::Select_Info($info[Traffic])} </DIV>
                </div>
            </div>
            <div class="roomsyBox mtop" id="hotel_question">
                <div class="roomsy_head">
                    <H3>酒店问答</H3>
                </div>
                <div class="infost">
                  <div id="question_index_body"><img align="absmiddle" src="{$BASE}js/loading.gif"/>最新酒店问答正在努力加载中...</div>
                </div>
            </div>            
            <div class="roomsyBox mtop">
                <div class="roomsy_head">
                    <h3>服务项目</h3>
                </div>
                <div class="fangxingnr">
                    <DIV class=db_main2>
                        <DL>
                            <DT>房间设施： </DT>
                            <DD 
		  class=es_dd>${hotelinfo::Select_Info($info[Service])} </DD>
                        </DL>
                        <DL>
                            <DT>餐饮设施： </DT>
                            <DD class=es_dd>${hotelinfo::Select_Info($info[Canyin])}</DD>
                        </DL>
                        <DL>
                            <DT>休闲娱乐： </DT>
                            <DD class=es_dd>无</DD>
                        </DL>
                        <DL class=es_last_item>
                            <DT>可接受信用卡： </DT>
                            <DD class=es_dd>${hotelinfo::Select_Info($info[Card])}</DD>
                        </DL>
                        <DIV class=clear_float></DIV>
                    </DIV>
                </div>
            </div>
        </div>
    </div>
    <!--{model:hotelinfo getNearbyHotels($info['NearbyHotels'], 10) return=nearbyHotels_ary}-->
    <!--{template inc/footer}-->
</div>
<form action="{PHP_SELF}" method="get" target="_blank" name="doBook" id="doBook">
    <input name="m" type="hidden" value="ebook"/>
    <input name="hid" type="hidden"/>
    <input name="rid" type="hidden" />
    <input name="pid" type="hidden" />
    <input name="tm1" type="hidden" value="$sk_array[tm1]" />
    <input name="tm2" type="hidden" value="$sk_array[tm2]" />
</form>
</div>
</body>
</html>
<script  language="javascript" >
loadPrice('$info[hotel_id]','$sk_array[tm1]','$sk_array[tm2]');
</script>
<script type="text/javascript">
j.include("{$BASE}js/calendar/Date.js","{$BASE}js/calendar/calendar.js","{$BASE}js/calendar/citys.js","{$BASE}js/calendar/city_menu.js","{$BASE}js/zhuna-js/mapbar31.2.js");
j.includecss("{$BASE}js/calendar/city_menu.css","{$BASE}js/zhuna-js/nyroModal.css");

$(function(){
if(!$("#tm1").val())$("#tm1").val(ZNDate.format(ZNDate.plus(ZNDate.today(),0)));
if(!$("#tm2").val())$("#tm2").val(ZNDate.format(ZNDate.plus(ZNDate.today(),3)));
initMap();
$(".indceDown").toggle(
		function(){
			$("#hotelinfo span").text($("#hotelinfo").attr("showvalue"));
			$(this).text("收起");
		},
		function(){
			var hotel_intro = String($("#hotelinfo").attr("showvalue")).substring(0,100)+"...";
			$("#hotelinfo span").text(hotel_intro);
			$(this).text("详细信息");
		}
	);
});
var len  = $("#numeric > li").length;var index = 0;
var interval = setInterval(function(){rotatorimg(index,269,178);index++;if(index==len){index=0;}},5000);
$("#numeric li").mouseover(function(){index= $("#numeric li").index(this);rotatorimg(index,269,178);});	


$(".info_nav ul li").click(function(){rollto($(this).find("a").html());});
$("#info_top_con ul").find("li:eq(1) span").each(function(){if(!!$(this).html())$(this).addClass("yx").css({"background-color":""+("#"+rancolor())+""}).mouseover(function(){$(this).css({"background-color":"#1F78D0"})}).mouseout(function(){$(this).css({"background-color":"#"+rancolor()})})});
function rollto(v){
this.roll=function(s){$('html').animate({scrollTop:$(".info_gk").eq(s).offset().top},'fast');$('body').animate({scrollTop:$(".info_gk").eq(s).offset().top},'fast');}
switch(v){
case "酒店介绍":this.roll(0);break;
case "酒店图片":this.roll(2);break;
case "客人点评":this.roll(3);break;
case "交通地图":this.roll(4);break;
case "酒店问答":this.roll(5);break;
case "周边酒店":this.roll(6);break;}
}

var maplet = null,mData=[{$nearbyHotels_ary[jsItem]}],mks=new Array(),polyline;
function initMap(){
	maplet = new Maplet("DP_Map_Show");
	maplet.centerAndZoom(new MPoint('北京市'),8);
	maplet.addControl(new MStandardControl());
	maplet.showOverview(false);	
	var mk=new MMarker(   
				new MPoint("$info[MapPoint]"),   
				new MIcon("{$BASE_V}images/0.gif",34,36), 
				null,
				new MLabel("$info[HotelName]",10,-8,80)
			);
	maplet.addOverlay(mk);
	mks.push(mk)
	for(var i=0;i<mData.length;i++){
		var mk=new MMarker(   
				new MPoint(mData[i][3]),   
				new MIcon("{$BASE_V}images/No/"+(i+1)+".gif",17,22),   

				new MInfoWindow(mData[i][1],'<img src="'+mData[i][2]+'" width="86" height="68" align="left" style="margin:5px;">名称：'+mData[i][1].substring(0,12)+'<br>价格：最低'+mData[i][5]+'元起订<br>地址：'+mData[i][4].substring(0,25)+'<br><a href="{PHP_SELF}?m=hotelinfo&hotel_id='+mData[i][0]+'" target="_blank">了解酒店详情>></a>'),
				
				null); 
		maplet.setIwStdSize(300,150); 
		maplet.addOverlay(mk);
		mks.push(mk);
	}
	maplet.setAutoZoom();
};
function showhotel(id,i){
	maplet.removeOverlay(polyline); 
	mks[i].openInfoWindow();
	for(var i=0;i<mData.length;i++){
		if(mData[i][0]==id){
			    var brush = new MBrush("blue");brush.stroke = 15;brush.overlap.enable = true;   
				polyline = new MPolyline([new MPoint("$info[MapPoint]"),new MPoint(mData[i][3])],brush);
				polyline.setEditable(true);
				maplet.addOverlay(polyline); 
				mks.push(polyline);
				maplet.setAutoZoom();
		}
	}
}

$(function(){
    getQuestionLimit($info[hotel_id], 3);
    getCommentLimit($info[hotel_id], 3);    
});

function getQuestionLimit(hotel_id,limit){
    var string = '';
    var url = "hotel_id="+hotel_id+"&limit="+limit;
    $.post("{PHP_SELF}?m=hotelinfo.getQuestionLimit&"+url,
        function(data){
            var obj=eval("("+data+")");//转换为json对象
            var nofind = obj.nofind;
            var rs = obj.rs;
            $.each(rs,function(j, n){
                var hotel_id = n.hotel_id;
                var hotelname = n.hotelname;
                var question = n.question;
                var answer = n.answer;              
                string += '<div class="dp_box"><div class="dp_box_r"><dl><dt><a href="{PHP_SELF}?m=hotelinfo&hotel_id='+hotel_id+'" target="_blank">'+hotelname+'</a></dt><dt title="'+question+'<br/>">'+question+'<br/></dt><dd title="'+answer+'">'+answer+'</dd></dl></div></div>';
            });
            string += nofind;   
            $('#question_index_body').html(string);
    }); 
}

function getCommentLimit(hotel_id,limit){
    var string = '';
    var url = "hotel_id="+hotel_id+"&limit="+limit;
    $.post("{PHP_SELF}?m=hotelinfo.getCommentLimit&"+url,
        function(data){
            var obj=eval("("+data+")");//转换为json对象
            var nofind = obj.nofind;
            var rs = obj.rs;
            $.each(rs,function(j, n){
                var hotel_id = n.hotel_id;
                var hotelname = n.hotelname;
                var yonghu = n.yonghu;
                var addtime = n.addtime;
                var content = n.content.substr(0,24);  
                string += '<div class="dp_box"><div class="dp_box_r"><dl><dt>'+yonghu+'于'+addtime+'</dt><dt>点评酒店：<a href="{PHP_SELF}?m=hotelinfo&hotel_id='+hotel_id+'" title="'+hotelname+'" target="_blank">'+hotelname+'</a></dt><dd>说：'+content+'</dd></dl></div></div>';
            });
            string += nofind;   
            $('#comment_index_body').html(string);
    }); 
}
</script>
