177 lines
7.2 KiB
PHP
Executable File
177 lines
7.2 KiB
PHP
Executable File
<!-- $Id: user_info.htm 16854 2009-12-07 06:20:09Z sxc_shop $ -->
|
|
<?php echo $this->fetch('pageheader.htm'); ?>
|
|
<!-- Magnific Popup core CSS file -->
|
|
<link rel="stylesheet" href="styles/jquery-ui.min.css">
|
|
<script src="js/jquery-ui.min.js"></script>
|
|
<script src="js/clipboard.min.js"></script>
|
|
<script type="text/javascript" src="../js/calendar.php?lang=<?php echo $this->_var['cfg_lang']; ?>"></script>
|
|
<link href="../js/calendar/calendar.css" rel="stylesheet" type="text/css" />
|
|
|
|
<script>
|
|
function openwindow(url,name,iWidth,iHeight)
|
|
{
|
|
var url; //網頁位置;
|
|
var name; //網頁名稱;
|
|
var iWidth; //視窗的寬度;
|
|
var iHeight; //視窗的高度;
|
|
var iTop = (window.screen.availHeight-30-iHeight)/2; //視窗的垂直位置;
|
|
var iLeft = (window.screen.availWidth-10-iWidth)/2; //視窗的水平位置;
|
|
window.open(url,name,'height='+iHeight+',innerHeight='+iHeight+',width='+iWidth+',innerWidth='+iWidth+',top='+iTop+',left='+iLeft);
|
|
}
|
|
</script>
|
|
<div class="main-div">
|
|
<form method="post" action="users.php" name="theForm" onsubmit="return validate()" enctype="multipart/form-data">
|
|
<table width="100%" >
|
|
<tr>
|
|
<td>二區文字:</td>
|
|
<td>
|
|
<textarea name="ad_text2" cols=100 rows=10><?php echo $this->_var['web']['ad_text2']; ?></textarea>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td>上傳檔案:</td>
|
|
<td>
|
|
輪撥:<input type="file" name="image1"/><br />
|
|
一區:<input type="file" name="image2"/><br />
|
|
二區:<input type="file" name="image3"/><br />
|
|
三區:<input type="file" name="image4"/><br />
|
|
<div style="padding:10px 0px">
|
|
<?php if ($this->_var['web']['image1'] != ''): ?>
|
|
<a href="javascript:void(0);" onClick="openwindow('../<?php echo $this->_var['web']['image1']; ?>','照片',800,500);">
|
|
<img src="../<?php echo $this->_var['web']['image1']; ?>" width="100" height="100" />
|
|
</a>
|
|
<?php else: ?>
|
|
<?php echo $this->_var['lang']['msg_na']; ?>
|
|
<?php endif; ?>
|
|
<?php if ($this->_var['web']['image2'] != ''): ?>
|
|
<a href="javascript:void(0);" onClick="openwindow('../<?php echo $this->_var['web']['image2']; ?>','照片',800,500);">
|
|
<img src="../<?php echo $this->_var['web']['image2']; ?>" width="100" height="100" />
|
|
</a>
|
|
<?php else: ?>
|
|
<?php echo $this->_var['lang']['msg_na']; ?>
|
|
<?php endif; ?>
|
|
<?php if ($this->_var['web']['image3'] != ''): ?>
|
|
<a href="javascript:void(0);" onClick="openwindow('../<?php echo $this->_var['web']['image3']; ?>','照片',800,500);">
|
|
<img src="../<?php echo $this->_var['web']['image3']; ?>" width="100" height="100" />
|
|
</a>
|
|
<?php else: ?>
|
|
<?php echo $this->_var['lang']['msg_na']; ?>
|
|
<?php endif; ?>
|
|
<?php if ($this->_var['web']['image4'] != ''): ?>
|
|
<a href="javascript:void(0);" onClick="openwindow('../<?php echo $this->_var['web']['image4']; ?>','照片',800,500);">
|
|
<img src="../<?php echo $this->_var['web']['image4']; ?>" width="100" height="100" />
|
|
</a>
|
|
<?php else: ?>
|
|
<?php echo $this->_var['lang']['msg_na']; ?>
|
|
<?php endif; ?>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td >廣告位置:</td>
|
|
<td>
|
|
<table width="100%" >
|
|
<tr>
|
|
<td>入口</td>
|
|
<td>輪撥</td>
|
|
<td>一區</td>
|
|
<td>二區</td>
|
|
<td>三區</td>
|
|
<td>到期日</td>
|
|
</tr>
|
|
<?php $_from = $this->_var['portals']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'portal');if (count($_from)):
|
|
foreach ($_from AS $this->_var['portal']):
|
|
?>
|
|
<tr>
|
|
<td><?php echo $this->_var['portal']['name']; ?></td>
|
|
<td><input type="checkbox" name="ad[<?php echo $this->_var['portal']['id']; ?>][]" value="1" <?php if ($this->_var['portal']['block'] & 1): ?>checked<?php endif; ?>></td>
|
|
<td><input type="checkbox" name="ad[<?php echo $this->_var['portal']['id']; ?>][]" value="2" <?php if ($this->_var['portal']['block'] & 2): ?>checked<?php endif; ?>></td>
|
|
<td><input type="checkbox" name="ad[<?php echo $this->_var['portal']['id']; ?>][]" value="4" <?php if ($this->_var['portal']['block'] & 4): ?>checked<?php endif; ?>></td>
|
|
<td><input type="checkbox" name="ad[<?php echo $this->_var['portal']['id']; ?>][]" value="8" <?php if ($this->_var['portal']['block'] & 8): ?>checked<?php endif; ?>></td>
|
|
<td><input name="expire[<?php echo $this->_var['portal']['id']; ?>]" type="text" id="expire_<?php echo $this->_var['portal']['id']; ?>" size="15" value='<?php echo $this->_var['portal']['dstamp']; ?>' readonly="readonly" /><input name="selbtn<?php echo $this->_var['portal']['id']; ?>" type="button" id="selbtn<?php echo $this->_var['portal']['id']; ?>" onclick="return showCalendar('expire_<?php echo $this->_var['portal']['id']; ?>', '%Y-%m-%d', false, false, 'selbtn<?php echo $this->_var['portal']['id']; ?>');" value="<?php echo $this->_var['lang']['btn_select']; ?>" class="button"/></td>
|
|
</tr>
|
|
<?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
|
|
</table>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2" align="center">
|
|
<input type="submit" value="<?php echo $this->_var['lang']['button_submit']; ?>" class="button" />
|
|
<input type="reset" value="<?php echo $this->_var['lang']['button_reset']; ?>" class="button" />
|
|
<input type="hidden" name="act" value="<?php echo $this->_var['form_action']; ?>" />
|
|
<input type="hidden" name="id" value="<?php echo $this->_var['id']; ?>" /> </td>
|
|
</tr>
|
|
</table>
|
|
</form>
|
|
</div>
|
|
<?php echo $this->smarty_insert_scripts(array('files'=>'../js/utils.js,validator.js')); ?>
|
|
|
|
<script language="JavaScript">
|
|
<!--
|
|
|
|
if (document.forms['theForm'].elements['act'].value == "insert")
|
|
{
|
|
document.forms['theForm'].elements['username'].focus();
|
|
}
|
|
else
|
|
{
|
|
document.forms['theForm'].elements['email'].focus();
|
|
}
|
|
|
|
//onload = function()
|
|
/{
|
|
// 开始检查订单
|
|
// startCheckOrder();
|
|
//}
|
|
|
|
/**
|
|
* 检查表单输入的数据
|
|
*/
|
|
function validate()
|
|
{
|
|
validator = new Validator("theForm");
|
|
validator.isMobile("mobile_phone", invalid_mobile_phone, true);
|
|
|
|
if (document.forms['theForm'].elements['act'].value == "insert")
|
|
{
|
|
validator.required("username", no_username);
|
|
validator.required("password", no_password);
|
|
validator.required("confirm_password", no_confirm_password);
|
|
// validator.required("mobile_phone", no_mobile_phone);
|
|
validator.eqaul("password", "confirm_password", password_not_same);
|
|
|
|
var password_value = document.forms['theForm'].elements['password'].value;
|
|
if (password_value.length < 6)
|
|
{
|
|
validator.addErrorMsg(less_password);
|
|
}
|
|
if (/ /.test(password_value) == true)
|
|
{
|
|
validator.addErrorMsg(passwd_balnk);
|
|
}
|
|
}
|
|
else if (document.forms['theForm'].elements['act'].value == "update")
|
|
{
|
|
var newpass = document.forms['theForm'].elements['password'];
|
|
var confirm_password = document.forms['theForm'].elements['confirm_password'];
|
|
if(newpass.value.length > 0 || confirm_password.value.length)
|
|
{
|
|
if(newpass.value.length >= 6 || confirm_password.value.length >= 6)
|
|
{
|
|
validator.eqaul("password", "confirm_password", password_not_same);
|
|
}
|
|
else
|
|
{
|
|
validator.addErrorMsg(password_len_err);
|
|
}
|
|
}
|
|
}
|
|
|
|
return validator.passed();
|
|
}
|
|
|
|
//-->
|
|
</script>
|
|
|
|
<?php echo $this->fetch('pagefooter.htm'); ?>
|