<?php
$ci=& get_instance();

# 실시간급상승
$req_data = array();
$req_data['offset']             = 0;
$req_data['limit']              = 20;

$ci->load->model('web/m_realtime_keyword');
$arr_realtime_keyword    = $ci->m_realtime_keyword->realtime_keyword_list($req_data);


?>


                    <div style="padding:0px 0 0 60px;" id="roll_realtime_keyword_bottom">
						<span style="padding-right:50px; position: absolute; top: 0; left: 60px;">실시간 급상승 </span>
						<ul style="height:17px; left: 150px">
				<?
					foreach ($arr_realtime_keyword as $key=>$val) {
				?>
						<li style="height:17px">
							<span class="beachblue"><?=$val['rank']?></span>
							<span class="b_roll_txt" style="width:500px"><a href="/web/search/?search_keyword=<?=urlencode($val['keyword'])?>"><?=$val['keyword']?></a></span>
						</li>
				<?
                	}
        		?>
						</ul>
						</div>
						<div class="b_search">
							<input class="b_window" id="search_keyword_bottom" name="search_keyword_bottom" value="<?=$search_keyword?>" onkeypress="if( event.keyCode==13 ){search_keyword_bottom_proc();}">
							<button type="button" class="b_src_sumit" onclick="search_keyword_bottom_proc()"><img src="/img/web/img_search.gif"></button>
						</div>

<script>
$('#roll_realtime_keyword_bottom').vTicker();

function search_keyword_bottom_proc(){
	var search_keyword = $("#search_keyword_bottom").val();
	var result = true;
    if(search_keyword!='') 	    result = search_keyword_reg(search_keyword);
    if(result==true) {
	    location.href='/web/search/?search_keyword='+encodeURI(search_keyword);
    }
}


</script>