<?php

	defined('IN_TS') or die('Access Denied.');
	$userid = intval($TS_USER['user']['userid']);
	$size = $_REQUEST['size'];
	$buynum = $_REQUEST['buynum'];
	$color = $_REQUEST['color'];
	$title = '确认订单 - '.$TS_SITE['base']['site_title'];
	$goods_id = intval(_get('goodid'));
	$strArea = aac('location')->getAreaForApp($strUser['areaid']);
	$arrOne = $db->fetch_all_assoc("select * from ".dbprefix."area where referid='0'");
	$strShare = aac('baobei')->getOneShare($goods_id);
	
	if($goods_id == 0 || empty($strShare))
	{
		qiMsg('购买的商品不存在，请重新选择哦...^_^');
	}
	
	
	if($userid<1){
		
		header("Location: ".SITE_URL."index.php?app=user&ac=login");
		
		
	}
	
	
	
	$strAddress = $db->fetch_all_assoc("select * from ".dbprefix."address where userid=$userid");
	
    $address="";
	foreach($strAddress as $sadkey=>$saditem){
		if($address){
			$address=$address.",".$saditem[aid];
		}else{
			$address=$saditem[aid];
		}
	}
	include template("index");
	