<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<?
	include("config/connect.php");
	include("functions.php");
	if($_SESSION["userid"])	$uid = $_SESSION["userid"];

	$ipaddress = $_SERVER['REMOTE_ADDR']; 	
	if($_SESSION["ipid"]=="" && $_SESSION["login_logout"]=="")
	{
		$qryipins = "Insert into login_logout (ipaddress,load_time) values('".$ipaddress."',NOW())";
		mysql_query($qryipins) or die(mysql_error());
		$ipid = mysql_insert_id();

		$qryipsel = "select * from login_logout where id='$ipid'";
		$rsip = mysql_query($qryipsel);
		$obj = mysql_fetch_object($rsip);
		$_SESSION["ipid"] = $obj->load_time;
		$_SESSION["ipaddress"] = $ipaddress;
	}
	
	$qryauc = "select *, p.productID as pid,p.".$lng_prefix."name as name,".$lng_prefix."short_desc as short_desc from auction a left join products p on a.productID=p.productID left join auc_due_table adt on a.auctionID=adt.auction_id where adt.auc_due_time!=0 and a.auc_status='2' and featured_flag='0' order by adt.auc_due_time limit 0,6";
	$resauc = mysql_query($qryauc);
	$totalauc = mysql_num_rows($resauc);
?>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?=$lng_characset;?>" />
<meta name="description" content="金点网" />
<meta name="keywords" content="竞拍,竞拍网,购物,娱乐,竞拍购物" />
<title>金点网</title>
<LINK media=screen href="css/library.css" type=text/css rel=stylesheet>
<LINK media=screen href="css/index.css" type=text/css rel=stylesheet>
<script language="javascript" src="jquery.js"></script>
<script language="javascript" src="effect.js"></script>
<script language="javascript" src="default.js"></script>
<script language="javascript" src="jqModal.js"></script>
<script language="javascript" src="function.js"></script>
<script language="javascript" src="basic.js"></script>

<META content="MSHTML 6.00.6000.16890" name=GENERATOR></HEAD>
<BODY class=layout_application onload="OnloadPage();">
<?
	include("h.php");
?>		
	
	<DIV id=main>
		<DIV id=having_connection_issues style="DISPLAY: none"></DIV>
		<DIV id=main_content>
			<DIV id=page_header>
				<H2>加一分拍卖</H2>
			</DIV>
			<DIV class=clearfix id=page_content>
				<DIV class=auctions>
					<DIV class=elevator>
						<OL>
  						<LI>出价，每次出价花费￥0.1
  						<LI>你是最后一个出价人 
  						<LI>一折买下拍卖商品 </LI>
  					</OL>
						<P>每出价一次商品价格上浮￥0.01。拍卖价超过市场价×10%，赢家将获得拍卖点卡回赠。没有中标也可以（市场价-累计付出）购买拍卖品。每次出价只需￥0.1 </P>
					</DIV>
					<DIV class=auction_navigator>
						<DIV class=left><BR>&nbsp; <A href="#">« 逝去的拍卖</A> </DIV>
						<DIV class=right><BR>&nbsp; <A href="#">将至的拍卖 »</A> </DIV></DIV>
						<DIV class="day_divider clear">今日 ( <?php echo date("Y-m-d", time());?>)</DIV>
		
				<?
				   if($totalauc>0){ 
				   $a = 1;
				   while($objauc=mysql_fetch_array($resauc))
				   {	
						if($a==1 && $objauc["auc_status"]==2)
						{
							$co = "'".$objauc["auctionID"]."'";
							$arr = $objauc["auctionID"];
							$prr = $objauc["auc_due_price"];
						}
						elseif($objauc["auc_status"]==2)
						{
							$co .= ",'".$objauc["auctionID"]."'";
							$arr .= ",".$objauc["auctionID"];
							$prr .= ",".$objauc["auc_due_price"];
						}
				?>
			 <div class="auction_panel">  
				<div id="Auction_boxes">
				
				        <div class="auction-item" style="display: none" title="<?=$objauc["auctionID"];?>" id="auction_<?=$objauc["auctionID"];?>"></div>
							  <TABLE class=auction_title>
  								<TBODY>
  									<TR>
    									<TD>
      									<H3><A href="auction_<?=str_replace(" ","_",strtolower(stripslashes($objauc["name"])));?>_<?=$objauc["auctionID"];?>.html"><?=stripslashes($objauc["name"]);?></A></H3>
    									</TD>
  									</TR>
  								</TBODY>
								</TABLE>																			
								  <div class="auction_panel_img">
								  	<a href="auction_<?=str_replace(" ","_",strtolower(stripslashes($objauc["name"])));?>_<?=$objauc["auctionID"];?>.html">
								  		<img src="uploads/products/thumbs_big/thumbbig_<?=$objauc["picture1"];?>" border="0" />
								  	</a><SPAN class=auction_panel_img_portrait></SPAN>
								  </div>							
								    							  
								  <div class="time">
								     <span class="left"><span id="counter_index_page_<?=$objauc["auctionID"];?>" class="" >
									     <? 
									        echo "<script language='javascript' type='text/javascript'>
									        document.getElementById('counter_index_page_".$objauc["auctionID"]."').innerHTML = calc_counter_from_time('".$objauc["auc_due_time"]."');
									        </script>";
								       ?>
								     </span></span>
								  </div>														   	
								<div class="price">
									&nbsp;<span id="currencysymbol_<?=$objauc["auctionID"];?>"></span><span id="price_index_page_<?=$objauc["auctionID"];?>">---</span>&nbsp;
								</div>
							<div class="time">
								<span class="right">
						  	 <? if($uid==""){ ?>
								<img src="<?=$lng_imagepath;?>BID_btn.png" border="0"  alt="BID" onmouseover="this.src='<?=$lng_imagepath;?>LOGIN_btn-2.png'" onmouseout="this.src='<?=$lng_imagepath;?>BID_btn.png'" onclick="javascript: window.location.href='login.html'" id="image_main_<?=$objauc["auctionID"];?>"  style="cursor: pointer"/>
						  <? } else { ?>
						    <?
						       if(getWonCount()<8)
						       {
						    ?> 
								<img src="<?=$lng_imagepath;?>BID_btn.png" border="0" class="bid-button-link" name="getbid.php?prid=<?=$objauc["productID"];?>&aid=<?=$objauc["auctionID"];?>&uid=<?=$uid;?>" alt="BID" onmouseover="this.src='<?=$lng_imagepath;?>BID_btn_hover.png'" onmouseout="this.src='<?=$lng_imagepath;?>BID_btn.png'" id="image_main_<?=$objauc["auctionID"];?>"  style="cursor: pointer"/>
						  	<? }else{ ?>
								<img src="<?=$lng_imagepath;?>BID_btn.png" border="0" name="" alt="BID" onclick="alert('<?=$lng_notice_maxbidnum;?>');" onmouseover="this.src='<?=$lng_imagepath;?>BID_btn_hover.png'" onmouseout="this.src='<?=$lng_imagepath;?>BID_btn.png'" id="image_main_<?=$objauc["auctionID"];?>"  style="cursor: pointer"/>
						  	<?	 } ?>
						  <? } ?>
						</span>
							</div>
								
							
							<DIV class=winner>				
								<?=iconv("gb2312","utf-8",$lng_bidder);?>: <span id="product_bidder_<?=iconv("gb2312","utf-8",$objauc["auctionID"]);?>">---</span>								
							</DIV>							
				 </div>				
			</div>
					<?
						$a++;
						}
					}
					else
					{
					?>
					<div style="height: 10px;">&nbsp;</div>
					<div class="noauction_message"><? echo $lng_noliveauction; ?></div>	
					<?
					}
					?>

			
			
			

<DIV class=clear>&nbsp;</DIV>
<DIV class=auction_navigator>
	<DIV class=left>&nbsp; <A href="http://www.weabid.com/?day=-2">« 逝去的拍卖</A> </DIV>
	<DIV class=right>&nbsp; <A href="http://www.weabid.com/?day=2">将至的拍卖 »</A> </DIV>
	<DIV class=clear></DIV>
</DIV>
</DIV>

<DIV class=right_panels>
	<? if($_SESSION["userid"]==""){ ?>
	<DIV class=panel>
		<DIV class=panel_top></DIV>
		<DIV class=panel_middle>
			<DIV class=sign_up_instructions>入会即赠5点! <I>注册会员只需一分钟</I>. </DIV>
			<DIV class=sign_up_instructions_button>
				<A class=green_button href="http://www.weabid.com/signup">现在就注册！</A> 
			</DIV>
		</DIV>
		<DIV class=panel_bottom></DIV>
	</DIV>
	<?  
  }
	?>
  <DIV class=panel>
		<DIV class=panel_top></DIV>
		<DIV class=panel_middle>
			<H3><? if($_SESSION["userid"]==""){ ?>购买点数<? }else{?><?=getUserName($_SESSION["userid"]);?>的帐户<H2>可用点数:<span id="bids_count" style="color: #000000"><?=GetUserFinalBids($_SESSION["userid"]);?></span></H2><?}?></H3>
			
<DIV class=panel_bids_form>
<FORM action=/signup method=post><INPUT type=hidden value=get name=_method> 
<DIV class=bid_package_item>
<DIV class=package_desc><INPUT id=5000_bids type=radio value=8295899 
name=hosted_button_id> <LABEL for=5000_bids>5000点 <SPAN 
style="FONT-SIZE: 10px">@ <B>10¢</B> ea</SPAN></LABEL> </DIV>
<DIV class=package_price><LABEL for=5000_bids>$499.98</LABEL> </DIV>
<DIV class=clear></DIV></DIV>
<DIV class=bid_package_item>
<DIV class=package_desc><INPUT id=1000_bids type=radio value=8295884 
name=hosted_button_id> <LABEL for=1000_bids>1000点 <SPAN 
style="FONT-SIZE: 10px">@ <B>12¢</B> ea</SPAN></LABEL> </DIV>
<DIV class=package_price><LABEL for=1000_bids>$119.98</LABEL> </DIV>
<DIV class=clear></DIV></DIV>
<DIV class=bid_package_item>
<DIV class=package_desc><INPUT id=500_bids type=radio CHECKED value=8295862 
name=hosted_button_id> <LABEL for=500_bids>500点 <SPAN 
style="FONT-SIZE: 10px">@ <B>13¢</B> ea</SPAN></LABEL> </DIV>
<DIV class=package_price><LABEL for=500_bids>$64.98</LABEL> </DIV>
<DIV class=clear></DIV></DIV>
<DIV class=bid_package_item>
<DIV class=package_desc><INPUT id=250_bids type=radio value=8295848 
name=hosted_button_id> <LABEL for=250_bids>250点 <SPAN 
style="FONT-SIZE: 10px">@ <B>14¢</B> ea</SPAN></LABEL> </DIV>
<DIV class=package_price><LABEL for=250_bids>$34.98</LABEL> </DIV>
<DIV class=clear></DIV></DIV>
<DIV class=bid_package_item>
<DIV class=package_desc><INPUT id=100_bids type=radio value=8295829 
name=hosted_button_id> <LABEL for=100_bids>100点 <SPAN 
style="FONT-SIZE: 10px">@ <B>15¢</B> ea</SPAN></LABEL> </DIV>
<DIV class=package_price><LABEL for=100_bids>$14.98</LABEL> </DIV>
<DIV class=clear></DIV></DIV>
<DIV class=button_holder><INPUT type=image 
alt="PayPal - The safer, easier way to pay online!" 
src="images/btn_buynowCC_LG.gif" border=0 name=submit> 
</DIV></FORM></DIV></DIV>
<DIV class=panel_bottom></DIV></DIV>
<DIV class=panel>
<DIV class=panel_top></DIV>
<DIV class=panel_middle>
<H3>我没有中标怎么办?</H3>
<DIV class=buy_now_elevator>如果您花费了50元竞拍任天堂Wii游戏主机，结果别人赢了。
拍卖结束后半小时内，您可以优惠50元的价格买下Wii（送货需要另附邮资）。<BR><BR>
也就是说，如果您赢了，就可以享受惊人优惠价格。没赢也没关系，同样可以买下它。<BR>
<A href="http://www.weabid.com/how_it_works#nobody_loses">了解更多信息</A> </DIV></DIV>
<DIV class=panel_bottom></DIV></DIV></DIV></DIV><!-- page_content -->
<DIV 
id=page_footer></DIV><!-- Just the GFX footer: no content ever. --></DIV></DIV>
<DIV id=footer_wrapper>
<DIV id=footer>
<DIV class=left_side>
<DIV class="footer_item first"><SPAN>漏洞? 妙招? 期待您的声音!</SPAN> 
&nbsp; &nbsp; <A class="feedback_link black_inline_button" 
href="http://www.weabid.com/feedback">投诉和建议</A> </DIV>
<DIV class=footer_item><SPAN>联系我们!</SPAN> &nbsp; &nbsp; <A 
class=black_inline_button href="mailto:support@WeaBid.com">联系我们</A> 
</DIV></DIV>
<DIV class=right_side>
<DIV class="footer_item first"><SPAN>想了解更多我们的资料?</SPAN> <A 
class=black_inline_button href="http://www.weabid.com/about">关于我们</A> 
</DIV>
<DIV class=footer_item><A href="http://www.weabid.com/terms">政策与条款</A> | Copyright 2009 We@Bid, Inc. </DIV></DIV>
<DIV class=clear></DIV></DIV></DIV>
<SCRIPT type=text/javascript>
    var $settings = {
        diagnosticAjaxMessages: false,
        gaId: "UA-10206147-1",
        mixpanelId: "56ebaaa0a1925c0616175ce646155f8c"
    };
    var $appInfo = {
        controller: 'auctions',
        action: 'index',
        subAction: ''
    };
</SCRIPT>

<SCRIPT src="js/library.js" type=text/javascript></SCRIPT>

<!--SCRIPT src="js/index.js" type=text/javascript></SCRIPT-->
</BODY></HTML>
