<?php
	ob_start();
	session_start();
		if($_SESSION['lang']=='')
{
	$_SESSION['lang'] = "en";
}	
	include 'languages/lang_liveauction_'.$_SESSION['lang'].'.php';
	include 'languages/lang_common_'.$_SESSION['lang'].'.php';
 	include("include/db.inc.php"); 
 	include("include/bit_functions.inc.php");
	include("include/functions.php");
	 include("include/pager.php");
	 include("include/meta_functions.php");
   $db1=new db;
   $db1->open();
  mysql_query("SET NAMES 'utf8'");  $currency_symbol_new=symbol_currency();
   $uid=$_SESSION['uid'];
 
   $myres=remainbid1();	
   $pids="";
   
	$jsqury1="SELECT pid,cid,pname,brand,price,bid_price,thumbnail,bider_id,description,type1 FROM t123go_product where 
	start_time <= DATE_ADD(now(), INTERVAL 72 HOUR) and end_time > DATE_SUB(now(), INTERVAL 2 MINUTE) and status='1' order by end_time limit 4 ";
	$jsres1=mysql_query($jsqury1);
 	while($jsrec1=mysql_fetch_array($jsres1))
	{
	$pids.=$jsrec1['pid'].",";
	$_SESSION['new'][$jsrec1['pid']]=$jsrec1['bid_price'];
	}
	
	//  top live auctions //	
	$lat_auction=substr($pids,0,-1);
	//  top live auctions //
	
	$homeres1=mysql_query($jsqury1);

?>
<!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">
<base href="<?=_BASEURL_?>/" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>
<?=_TITLE_?>
All Live Auctions like Fixed auctions, Penny Auctions, Future Auctions, Closed Auctions and 100% Off Auctions</title>
<meta name="description" content="<?=meta_description($pids)?>" />
<meta name="keywords" content="<?=meta_keyword($pids)?>" />
<META Http-Equiv="Cache-Control" Content="no-cache">
<META Http-Equiv="Pragma" Content="no-cache">
<META Http-Equiv="Expires" Content="0">
<meta name="author" content="Info-Tech Ltd.">
<meta name="publisher" content="Info-Tech Ltd.">
<meta name="copyright" content="Money Auctions | Powered by Money Auctions">
<meta name="page-topic" content="Service">
<meta name="audience" content="all">
<meta http-equiv="content-language" content="us">
<meta name="Language" content="english">
<meta name="robots" content="index,follow">
<meta name="revisit-after" content="3">
<link href="css/english/index.css" rel="stylesheet" type="text/css" />
<link href="css/english/special.css" rel="stylesheet" type="text/css" />
<link href="css/english/myaccount.css" rel="stylesheet" type="text/css" />
<!--[if lte IE 6]><style type="text/css" media="screen">/* <![CDATA[ */ @import url(<?=_BASEURLCSSNEW_?>/ie6.css?0:102290); /* ]]> */</style><![endif]-->
<!--[if gte IE 7]><style type="text/css" media="screen">/* <![CDATA[ */ @import url(<?=_BASEURLCSSNEW_?>/ie7.css?0:99961); /* ]]> */</style><![endif]-->

<script src="<?=_BASEURL_?>/js/home_counter.js" type="text/javascript"></script>
<? include("timer.js.php");?>
</head>
<body onload="home_detail();">
  <div id="green_wrapper">
    <? include("header.php");?>
    
    <div id="product_detail" style="background-color:#FFFFFF">
      <?
  $parr=explode(",",$pids);
  echo "<form name='frm'>";
      for($y=0; $y < count($parr)-1; $y++)
   {
   
      $pid=$parr[$y];
	  $diff=mysql_fetch_array(mysql_query("SELECT TIME_TO_SEC( TIMEDIFF( end_time, now( ))),
	  bid_price,bider_id FROM t123go_product where pid='$pid'")) ;
	  
	  ?>
      <input type="hidden" name="price_<?=$pid?>" value="<?=$diff[bid_price]?>" />
      <input type="hidden" name="bider_<?=$pid?>" value="<?=get_uname($diff[bider_id])?>" />
      <input type="hidden" name="diff_<?=$pid?>" value="<?=$diff[0]?>" />
      <input type="hidden" name="new_<?=$pid?>" value="0" />
      <?
   }	
	echo "</form>";  
 ?>
    </div>
	 <div id="special_bids">    
<div class="t1"><div class="t2"><?=_BDNW_ACT_ABTEND_?></div></div><div class="t3"></div>
<div class="cl"><div class="t4">
          <?
	$i=1;
 while($myrow=mysql_fetch_array($homeres1))
{

?>
          <div class="sfl_show">
            <div class="tac bm5px w220"> <a href="<?=get_cat_name($myrow['cid']);?>/<?=str_replace(" ","-",trim($myrow['pname']))?>/auction/<?=$myrow['pid']?>" class="product_title_or"> <strong>
              <?=substr($myrow['pname'],0,100);?>
              </strong></a> </div>
            <div class="sflim"> <a href="<?=get_cat_name($myrow['cid']);?>/<?=str_replace(" ","-",trim($myrow['pname']))?>/auction/<?=$myrow['pid']?>">
              <?=image_90($myrow['pid']); ?>
              </a> </div>
			   <div style="display:none" id="maximumbid_<?=$myrow['pid']?>" class="highestbid"></div>
            <div class="sflbid">
              <div  id="productcounter_<?=$myrow['pid']?>" style="font-size:12px; color:#010046; font-weight:bold">
			 <span  id="counter_index_page_<?=$myrow['pid']?>"></span> </div>
              <div  id="productprice_<?=$myrow[pid]?>" style="font-size:14px; color:#64BD25; font-weight:bold"><?=$currency_symbol_new?>  <span  id="price_index_page_<?=$myrow['pid']?>">
                <?
		  echo $myrow['bid_price'];
		?>
                </span> </div>
              <div style="color:#F6851F; font-size:12px; font-weight:bold;"  id="winner_index_page_<?=$myrow['pid']?>"></div>
              <div  id="button_finished_index_page_<?=$myrow['pid']?>" style="display:none" >
                <?  if($uid==''){?>
                <a href="<?=_BASEURL_?>/login/index.html">
                <input type="button" name="bid"  value=" "/>
                <? } else if($myres<=0){?>
                <input type="button" name="bid" onclick="alert('<?=_UR_NTABL_BDH_?>')" value="  "/>
                <?  } else {?>
                <input type="button" name="bid" onclick="product_bid('<?=$myrow[pid]?>'); return false;" value="" style="margin-top:-1px;"/>
                <? }?>
                </a> </div>
              
            </div>
          </div>
          <? $i++;}?>
        </div>
      </div>
      <div class="t5">
        <div class="t6"></div>
      </div>
      <div class="t7"></div>
    </div>
	
	<div  align="left" class="cl" style="padding-left:8px; padding-right:8px;">
   
   
   <?
        $sql_qry=mysql_query("select contact_seller from tbl_footer");
		$myst=mysql_fetch_array($sql_qry);
		echo $myst['contact_seller'];
		?>


</div>
	
	
	
    
   
  <? include("footer.php");?>
</div>
</body>
</html>
