<!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">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<meta name="format-detection" content="telephone=no" />
<title>SURVVPOS</title>
<script src="<?= base_url() ?>assets/front/js/jquery-1.8.3.min.js"></script>
<link href="<?= base_url() ?>assets/front/css/style.css" rel="stylesheet" type="text/css" />
<script src="<?= base_url() ?>assets/front/js/datePicker.js"></script>
<script src="<?= base_url() ?>assets/front/js/common.js"></script>
<script>
    var baseurl = '<?= base_url() . $this->config->item("index_page") ?>';
    var rootpath = '<?= base_url() ?>';

</script>
<style>
.upbutton input{ height:50px;}
.data-head{ position:relative}
.upbutton{ position: absolute; width:70px; height:50px; top:0; right:0;opacity: 0}
</style>
</head>

<body class="bg_fa"> 
<!---->
<div class="placeholder-head"></div>
<div class="head"><a href="javascript:history.back(-1)" class="return"></a>个人资料</div>
<div class="warp"> 
 	<div class="line"></div>
	<form action="<?= site_url('index.php/member/data_save') ?>" method="post" >
    	<dl class="data">
				  <input type="hidden" value="<?= $user['birthdate'] ?>" placeholder="" class="input" id="birthdate" name="birthdate"/>
				   <input type="hidden" value="<?= $user['logo'] ?>" placeholder="" class="input" id="logo_fileupload" name="logo"/>
                <dd class="data_img"><label class="title">头像</label>
                    <div class="data-head">
					<img src="<?php if($user['logo'] =="" ) { ?><?= base_url() ?>assets/front/images/head.jpg<?php } else { ?><?= $user['logo']?><?php }?>" id="preview_fileupload" />
					 <span class="upbutton"><a class="update" href="javascript:;"><!--点击上传--></a>
                            <input id="fileupload" type="file" name="files" accept="image/*" ></span>
					</div>
                </dd>

                <dd><label class="title">昵称</label>
                    <input type="text" value="<?= $user['name1'] ?>" placeholder="请输入昵称" name="name1" class="input" />
                </dd>
                <dd><label class="title">姓名</label>
                    <input type="text" value="<?= $user['name2'] ?>" placeholder="请输入姓名" name="name2" class="input" />
                </dd>
                <dd><label class="title">性别</label>
                    <div class="data-sex">
                        <label for="man"><input type="radio" name="sex1" <?php if($user['sex1'] == 0 && $user['sex1'] != "") { ?>checked<?php } ?> id="man" value="0" />男</label>
                        <label for="woman"><input type="radio" name="sex1" <?php if($user['sex1'] == 1) { ?>checked<?php } ?>  id="woman" value="1" />女</label>
                    </div>
                </dd> 
                <dd><label class="title">生日</label>
                   <div id="demo1" class="input"><?= $user['birthdate'] ?></div>
                </dd>
                <dd><label class="title">手机号</label>
                    <input type="text" value="<?= $user['tel1'] ?>" disabled="disabled" placeholder="" class="input" />
                </dd>
                <dd><label class="title">地址</label>
                    <input type="text" value="<?= $user['addr1_l1'] ?>" placeholder="请输入地址" class="input" name="addr1_l1" />
                </dd>  
     </dl>
     <input type="submit" value="保存资料" class="print_btn" />
    </form>
</div>
<!----> 
<script src="<?= base_url() ?>assets/jqueryfileupload/vendor/jquery.ui.widget.js"></script>
<script src="<?= base_url() ?>assets/jqueryfileupload/jquery.fileupload.js"></script>
<script src="<?= base_url() ?>assets/admin/js/myuploader.js"></script>
 <script>
  $(document).ready(function () {
        uploadSiglePicture("fileupload", true);
    });

	var calendar = new datePicker();
calendar.init({
	'trigger': '#demo1', /*按钮选择器，用于触发弹出插件*/
	'type': 'date',/*模式：date日期；datetime日期时间；time时间；ym年月；*/
	'minDate':'1900-1-1',/*最小日期*/
	'maxDate':'2100-12-31',/*最大日期*/
	'onSubmit':function(){/*确认时触发事件*/
		var theSelectData=calendar.value;
		document.getElementById("demo1").innerHTML = theSelectData
		$("#birthdate").val(theSelectData);
	},
	'onClose':function(){/*取消时触发事件*/
	}
});
	
	</script>
</body>
</html>