<!DOCTYPE html>
<html>
	<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<link rel="stylesheet" href="themes/jquery/css/themes/default/jquery.mobile-1.4.5.min.css">
	<link rel="stylesheet" href="themes/home/css/fonts/font-awesome.min.css">
    <link rel="stylesheet" href="themes/home/css/ui-box.css">
    <link rel="stylesheet" href="themes/home/css/ui-base.css">
    <link rel="stylesheet" href="themes/home/css/ui-color.css">
    <link rel="stylesheet" href="themes/home/css/icon.css">
    <link rel="stylesheet" href="themes/home/css/control.css">
    <link rel="stylesheet" href="themes/home/css/main.css">
	<script src="themes/jquery/js/jquery.js"></script>
	<script src="themes/jquery/js/jquery.mobile-1.4.5.min.js"></script>
</head>
<body class="um-vp c-wh " ontouchstart>
	<div data-role="page" id="showpage" data-quicklinks="true" class="ub ub-ver " >
      <div data-role="header" id="header" data-position="fixed" data-fullscreen="true" data-tap-toggle="false" >
	  <div class="uh bc-text-head ub bc-head">
                <div class="nav-btn" id="nav-left" onClick="javascript:window.location='index.php?ac=<?php echo $ac;?>&fileurl=plugin&type=<?php echo $type;?>'">
                    <div class="fa fa-angle-left fa-2x"></div>
                </div>
                <h1 class="ut ub-f1 ulev-3 ut-s tx-c" tabindex="0"><?php echo $_title['name'];?>通迅录</h1>
				
                <div class="nav-btn nav-bt" id="nav-right" onClick="form_add();">
					<div class="ub-img icon-ok umw2 umh4"></div>
                </div>
				
       </div>
	   <div id="error" style="display:none;">你的信息处理成功！</div>
	  
</div>
		<!-- /header -->
  <div data-role="content" id="content" >
		<form action="index.php?ac=<?php echo $ac;?>&fileurl=plugin&do=add" method="post" name="formadd" style="margin-bottom:20px;">
	    <input type="hidden" name="id" value="<?php echo $id;?>">
		<input type="hidden" name="type" value="<?php echo $type;?>">
		<input type="hidden" name="view" value="add">
		<div class="ub ub-ver">
			<div class="uinn-a6 sc-text  ulev-app1">
				公司名称
				<input id="company" name="company" value="<?php echo $row['company'];?>" type="text" placeholder="公司名称">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1" id="users">
				联系人
			   <input id="person" name="person" value="<?php echo $row['person'];?>" type="text" placeholder="联系人">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				职位
				<input id="position" name="position" value="<?php echo $row['position'];?>" type="text" placeholder="职位">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				性别
				<fieldset data-role="controlgroup" data-type="horizontal" data-mini="true">
		<input id="radio-choice-h-6a" name="sex" value="男" <?php if($row['sex']=='男'){?>CHECKED="checked"<?php }?> type="radio">
		<label for="radio-choice-h-6a">男</label>
		<input id="radio-choice-h-6b" name="sex" <?php if($row['sex']=='女'){?>CHECKED="checked"<?php }?> value="女" type="radio">
		<label for="radio-choice-h-6b">女</label>
		</fieldset>
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				手机
				<input id="phone" name="phone" value="<?php echo $row['phone'];?>" type="text" placeholder="手机">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				电话
				<input id="tel" name="tel" value="<?php echo $row['tel'];?>" type="tel" placeholder="电话">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				传真
				<input id="fax" name="fax" value="<?php echo $row['fax'];?>" type="tel" placeholder="传真">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				eMail
				<input id="mail" name="mail" value="<?php echo $row['mail'];?>" type="text" placeholder="Mail">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				MSN/(QQ)
				<input id="msn" name="msn" value="<?php echo $row['msn'];?>" type="text" placeholder="MSN/(QQ)">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				邮编
				<input id="zipcode" name="zipcode" value="<?php echo $row['zipcode'];?>" type="text" placeholder="邮编">
			</div>
			<div class="uinn-a6 sc-text  ulev-app1">
				地址
				<input id="address" name="address" value="<?php echo $row['address'];?>" type="text" placeholder="地址">
			</div>		
		</div>
	  </form>
  </div>


	</div><!-- /page -->
 <script type="text/javascript"> 
    window.onload = function(){ 
        var heg=document.getElementById("header").offsetHeight;
		var content=document.getElementById("content"); 
		content.style.cssText="margin-top:"+heg+"px;";
		<?php if($formlist!=''){?>
		$("#error").fadeIn("slow");
		$("#nav-right").hide();
		$("#content").hide();
		window.setTimeout(display,4000);
		<?php }?>
    }
	function display(){
		$("#error").hide();
		window.location='index.php?ac=<?php echo $ac;?>&fileurl=plugin&type=<?php echo getGP('type','P');?>';
	}
	function form_add(){
		if($("#company").val()==""){
			alert("公司名称不能为空！");
			return (false);
		}
		if($("#person").val()==""){
			alert("联系人不能为空！");
			return (false);
		}
		document.formadd.submit();
	}
</script>   
</body>
</html>
