
<?  if($_SESSION['uid']==''){?>	   <div style="margin:10px 10px 10px 10px">
	   <script type="text/javascript"><!--

google_ad_client = "pub-1898463304382703";

/* 120x600, created 12/03/08 */

google_ad_slot = "2988110911";

google_ad_width = 120;

google_ad_height = 600;

//-->

</script>

<script type="text/javascript"

src="http://pagead2.googlesyndication.com/pagead/show_ads.js">

</script>

</div>
<?  } else {?>
<?
 $uname=mysql_fetch_array(mysql_query("select id,uname,image,no_bids from user where id=".$_SESSION['uid']));
?>

<div id="aac">
<div class="ab"></div><div class="at tac"><img src="<?=_BASEURLMEDIA_?>/myaccount_credit.gif" alt="my credits" /></div><div class="ac"></div>
<div class="textual_solid">
<div class="allp5px">
<div class="tp10px" >
Welcome
<span class="normaltextgreybold ttc">
<?=substr($uname['uname'],0,15);?></span></div>
<? 
  $pay_query=mysql_query("select sold_price from t123go_product_sold where payment='0' and uid=".$_SESSION['uid']);
  $pay_num=mysql_num_rows($pay_query);
  $auction_payment=0;
  while( $user_pay=mysql_fetch_array($pay_query))
 	{
		 $auction_payment=$auction_payment + $user_pay['sold_price'];
		}
		if($pay_num!='0')
		  echo "<div class='tm10px'><a href='useraccount/index.html'>You have Pending Payments.</a></div>";
		  
  		?>
        <div class="tm10px "><div class="normaltextgreenbold11 sfl">Available Green Credits:</div> 
<div id="user_current_bids" class="normaltextblackbold11 lm5px sfl"> <?=$uname['no_bids'];?>
</div>

</div>
<script language="javascript">
function find_no_bids(strURL)
{

 	var xmlHttpReq_num = false;
    var self_num = this;
    // Mozilla/Safari
    if (window.XMLHttpRequest) {
        self_num.xmlHttpReq_num = new XMLHttpRequest();
    }
    // IE
    else if (window.ActiveXObject) { 
        self_num.xmlHttpReq_num = new ActiveXObject("Microsoft.XMLHTTP"); 
    }
	
    self_num.xmlHttpReq_num.open('POST', strURL, true);
    self_num.xmlHttpReq_num.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
    self_num.xmlHttpReq_num.onreadystatechange = function() {
        if (self_num.xmlHttpReq_num.readyState == 4) 
		{
            document.getElementById("user_current_bids").innerHTML=self_num.xmlHttpReq_num.responseText;
        }
    }
    self_num.xmlHttpReq_num.send('');

	setTimeout("find_no_bids('ajax_num_bids.php')",2000);
}

setTimeout("find_no_bids('ajax_num_bids.php')",2000);
</script>
</div>
</div>
<div class="tft1"><div class="tft2"></div><div class="tft3"></div></div>
</div>

<div id="view_left">
<div><a href="<?=_BASEURL_?>/useraddresses/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/my_profile.gif" alt="My Profile" /></div><div class="sfr lm10px">My Profile </div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/myauctions/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/myauctions.gif" alt="<?=_MY_AUC_TIONS_?>" /></div><div class="sfr lm10px"><?=_MY_AUC_TIONS_?></div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/my-greenbot/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/greenbot.gif" alt="<?=_DOO_BI_BD_?>" /></div><div class="sfr lm10px"><?=_DOO_BI_BD_?></div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/watchlist/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/watchedauction.gif"  alt="<?=_WATCH_ACT_?>"/></div><div class="sfr lm10px"><?=_WATCH_ACT_?></div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/wonauctions/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/won_auctions.gif"  alt="<?=_WON_ACT_?>"/></div><div class="sfr lm10px"><?=_WON_ACT_?></div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/buybids/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/buycredits.gif" alt="Buy Green Credits" /></div><div class="sfr lm10px">Buy Green Credits</div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/bidhistory/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/greenbank.gif"  alt="Green Bank "/></div><div class="sfr lm10px">Green Bank </div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/myvouchers/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/myvouchers.gif" alt="My <?=_VOUCHRS_?>" /></div><div class="sfr lm10px">My <?=_VOUCHRS_?></div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/useraccount/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/pendingpayments.gif"  alt="<?=_PRODCT_ACT_?>s"/></div><div class="sfr lm10px"><?=_PRODCT_ACT_?>s</div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/changepassword/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/changepassword.gif" alt="<?=_CHNG_PWD_?>" /></div><div class="sfr lm10px"><?=_CHNG_PWD_?></div></div></dt></a></div>
<div><a href="<?=_BASEURL_?>/closeaccount/index.html"><dt class="view_bg"><div class="myc"><div class="sfl"><img src="<?=_BASEURLICONS_?>/closeaccount.gif"  alt="<?=_CLS_ACCOUNT_?>"/></div><div class="sfr lm10px"><?=_CLS_ACCOUNT_?></div></div></dt></a></div>
</div>


       <? }?>
