代码初始化
This commit is contained in:
78
application/index/controller/Ajax.php
Normal file
78
application/index/controller/Ajax.php
Normal file
@@ -0,0 +1,78 @@
|
||||
<?php
|
||||
|
||||
namespace app\index\controller;
|
||||
|
||||
use app\common\controller\Frontend;
|
||||
use think\Lang;
|
||||
use think\Loader;
|
||||
use think\Response;
|
||||
|
||||
/**
|
||||
* Ajax异步请求接口
|
||||
* @internal
|
||||
*/
|
||||
class Ajax extends Frontend
|
||||
{
|
||||
|
||||
protected $noNeedLogin = ['lang', 'upload'];
|
||||
protected $noNeedRight = ['*'];
|
||||
protected $layout = '';
|
||||
|
||||
/**
|
||||
* 加载语言包
|
||||
*/
|
||||
public function lang()
|
||||
{
|
||||
$this->request->get(['callback' => 'define']);
|
||||
$header = ['Content-Type' => 'application/javascript'];
|
||||
if (!config('app_debug')) {
|
||||
$offset = 30 * 60 * 60 * 24; // 缓存一个月
|
||||
$header['Cache-Control'] = 'public';
|
||||
$header['Pragma'] = 'cache';
|
||||
$header['Expires'] = gmdate("D, d M Y H:i:s", time() + $offset) . " GMT";
|
||||
}
|
||||
|
||||
$controllername = $this->request->get('controllername');
|
||||
$lang = $this->request->get('lang');
|
||||
if (!$lang || !in_array($lang, config('allow_lang_list')) || !$controllername || !preg_match("/^[a-z0-9_\.]+$/i", $controllername)) {
|
||||
return jsonp(['errmsg' => '参数错误'], 200, [], ['json_encode_param' => JSON_FORCE_OBJECT | JSON_UNESCAPED_UNICODE]);
|
||||
}
|
||||
|
||||
$controllername = input("controllername");
|
||||
$className = Loader::parseClass($this->request->module(), 'controller', $controllername, false);
|
||||
|
||||
//存在对应的类才加载
|
||||
if (class_exists($className)) {
|
||||
$this->loadlang($controllername);
|
||||
}
|
||||
|
||||
//强制输出JSON Object
|
||||
return jsonp(Lang::get(), 200, $header, ['json_encode_param' => JSON_FORCE_OBJECT | JSON_UNESCAPED_UNICODE]);
|
||||
}
|
||||
|
||||
/**
|
||||
* 生成后缀图标
|
||||
*/
|
||||
public function icon()
|
||||
{
|
||||
$suffix = $this->request->request("suffix");
|
||||
$suffix = $suffix ? $suffix : "FILE";
|
||||
$data = build_suffix_image($suffix);
|
||||
$header = ['Content-Type' => 'image/svg+xml'];
|
||||
$offset = 30 * 60 * 60 * 24; // 缓存一个月
|
||||
$header['Cache-Control'] = 'public';
|
||||
$header['Pragma'] = 'cache';
|
||||
$header['Expires'] = gmdate("D, d M Y H:i:s", time() + $offset) . " GMT";
|
||||
$response = Response::create($data, '', 200, $header);
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* 上传文件
|
||||
*/
|
||||
public function upload()
|
||||
{
|
||||
return action('api/common/upload');
|
||||
}
|
||||
|
||||
}
|
||||
19
application/index/controller/Index.php
Normal file
19
application/index/controller/Index.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
|
||||
namespace app\index\controller;
|
||||
|
||||
use app\common\controller\Frontend;
|
||||
|
||||
class Index extends Frontend
|
||||
{
|
||||
|
||||
protected $noNeedLogin = '*';
|
||||
protected $noNeedRight = '*';
|
||||
protected $layout = '';
|
||||
|
||||
public function index()
|
||||
{
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
}
|
||||
333
application/index/controller/User.php
Normal file
333
application/index/controller/User.php
Normal file
@@ -0,0 +1,333 @@
|
||||
<?php
|
||||
|
||||
namespace app\index\controller;
|
||||
|
||||
use addons\wechat\model\WechatCaptcha;
|
||||
use app\common\controller\Frontend;
|
||||
use app\common\library\Ems;
|
||||
use app\common\library\Sms;
|
||||
use app\common\model\Attachment;
|
||||
use think\Config;
|
||||
use think\Cookie;
|
||||
use think\Hook;
|
||||
use think\Session;
|
||||
use think\Validate;
|
||||
|
||||
/**
|
||||
* 会员中心
|
||||
*/
|
||||
class User extends Frontend
|
||||
{
|
||||
protected $layout = 'default';
|
||||
protected $noNeedLogin = ['login', 'register', 'third'];
|
||||
protected $noNeedRight = ['*'];
|
||||
|
||||
public function _initialize()
|
||||
{
|
||||
parent::_initialize();
|
||||
$auth = $this->auth;
|
||||
|
||||
if (!Config::get('fastadmin.usercenter')) {
|
||||
$this->error(__('User center already closed'), '/');
|
||||
}
|
||||
|
||||
//监听注册登录退出的事件
|
||||
Hook::add('user_login_successed', function ($user) use ($auth) {
|
||||
$expire = input('post.keeplogin') ? 30 * 86400 : 0;
|
||||
Cookie::set('uid', $user->id, $expire);
|
||||
Cookie::set('token', $auth->getToken(), $expire);
|
||||
});
|
||||
Hook::add('user_register_successed', function ($user) use ($auth) {
|
||||
Cookie::set('uid', $user->id);
|
||||
Cookie::set('token', $auth->getToken());
|
||||
});
|
||||
Hook::add('user_delete_successed', function ($user) use ($auth) {
|
||||
Cookie::delete('uid');
|
||||
Cookie::delete('token');
|
||||
});
|
||||
Hook::add('user_logout_successed', function ($user) use ($auth) {
|
||||
Cookie::delete('uid');
|
||||
Cookie::delete('token');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 会员中心
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$this->view->assign('title', __('User center'));
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
/**
|
||||
* 注册会员
|
||||
*/
|
||||
public function register()
|
||||
{
|
||||
$url = $this->request->request('url', '', 'url_clean');
|
||||
if ($this->auth->id) {
|
||||
$this->success(__('You\'ve logged in, do not login again'), $url ? $url : url('user/index'));
|
||||
}
|
||||
if ($this->request->isPost()) {
|
||||
$username = $this->request->post('username');
|
||||
$password = $this->request->post('password', '', null);
|
||||
$email = $this->request->post('email');
|
||||
$mobile = $this->request->post('mobile', '');
|
||||
$captcha = $this->request->post('captcha');
|
||||
$token = $this->request->post('__token__');
|
||||
$rule = [
|
||||
'username' => 'require|length:3,30',
|
||||
'password' => 'require|length:6,30',
|
||||
'email' => 'require|email',
|
||||
'mobile' => 'regex:/^1\d{10}$/',
|
||||
'__token__' => 'require|token',
|
||||
];
|
||||
|
||||
$msg = [
|
||||
'username.require' => 'Username can not be empty',
|
||||
'username.length' => 'Username must be 3 to 30 characters',
|
||||
'password.require' => 'Password can not be empty',
|
||||
'password.length' => 'Password must be 6 to 30 characters',
|
||||
'email' => 'Email is incorrect',
|
||||
'mobile' => 'Mobile is incorrect',
|
||||
];
|
||||
$data = [
|
||||
'username' => $username,
|
||||
'password' => $password,
|
||||
'email' => $email,
|
||||
'mobile' => $mobile,
|
||||
'__token__' => $token,
|
||||
];
|
||||
//验证码
|
||||
$captchaResult = true;
|
||||
$captchaType = config("fastadmin.user_register_captcha");
|
||||
if ($captchaType) {
|
||||
if ($captchaType == 'mobile') {
|
||||
$captchaResult = Sms::check($mobile, $captcha, 'register');
|
||||
} elseif ($captchaType == 'email') {
|
||||
$captchaResult = Ems::check($email, $captcha, 'register');
|
||||
} elseif ($captchaType == 'wechat') {
|
||||
$captchaResult = WechatCaptcha::check($captcha, 'register');
|
||||
} elseif ($captchaType == 'text') {
|
||||
$captchaResult = \think\Validate::is($captcha, 'captcha');
|
||||
}
|
||||
}
|
||||
if (!$captchaResult) {
|
||||
$this->error(__('Captcha is incorrect'));
|
||||
}
|
||||
$validate = new Validate($rule, $msg);
|
||||
$result = $validate->check($data);
|
||||
if (!$result) {
|
||||
$this->error(__($validate->getError()), null, ['token' => $this->request->token()]);
|
||||
}
|
||||
if ($this->auth->register($username, $password, $email, $mobile)) {
|
||||
$this->success(__('Sign up successful'), $url ? $url : url('user/index'));
|
||||
} else {
|
||||
$this->error($this->auth->getError(), null, ['token' => $this->request->token()]);
|
||||
}
|
||||
}
|
||||
//判断来源
|
||||
$referer = $this->request->server('HTTP_REFERER', '', 'url_clean');
|
||||
if (!$url && $referer && !preg_match("/(user\/login|user\/register|user\/logout)/i", $referer)) {
|
||||
$url = $referer;
|
||||
}
|
||||
$this->view->assign('captchaType', config('fastadmin.user_register_captcha'));
|
||||
$this->view->assign('url', $url);
|
||||
$this->view->assign('title', __('Register'));
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
/**
|
||||
* 会员登录
|
||||
*/
|
||||
public function login()
|
||||
{
|
||||
$url = $this->request->request('url', '', 'url_clean');
|
||||
if ($this->auth->id) {
|
||||
$this->success(__('You\'ve logged in, do not login again'), $url ?: url('user/index'));
|
||||
}
|
||||
if ($this->request->isPost()) {
|
||||
$account = $this->request->post('account');
|
||||
$password = $this->request->post('password', '', null);
|
||||
$keeplogin = (int)$this->request->post('keeplogin');
|
||||
$token = $this->request->post('__token__');
|
||||
$rule = [
|
||||
'account' => 'require|length:3,50',
|
||||
'password' => 'require|length:6,30',
|
||||
'__token__' => 'require|token',
|
||||
];
|
||||
|
||||
$msg = [
|
||||
'account.require' => 'Account can not be empty',
|
||||
'account.length' => 'Account must be 3 to 50 characters',
|
||||
'password.require' => 'Password can not be empty',
|
||||
'password.length' => 'Password must be 6 to 30 characters',
|
||||
];
|
||||
$data = [
|
||||
'account' => $account,
|
||||
'password' => $password,
|
||||
'__token__' => $token,
|
||||
];
|
||||
$validate = new Validate($rule, $msg);
|
||||
$result = $validate->check($data);
|
||||
if (!$result) {
|
||||
$this->error(__($validate->getError()), null, ['token' => $this->request->token()]);
|
||||
}
|
||||
if ($this->auth->login($account, $password)) {
|
||||
$this->success(__('Logged in successful'), $url ? $url : url('user/index'));
|
||||
} else {
|
||||
$this->error($this->auth->getError(), null, ['token' => $this->request->token()]);
|
||||
}
|
||||
}
|
||||
//判断来源
|
||||
$referer = $this->request->server('HTTP_REFERER', '', 'url_clean');
|
||||
if (!$url && $referer && !preg_match("/(user\/login|user\/register|user\/logout)/i", $referer)) {
|
||||
$url = $referer;
|
||||
}
|
||||
$this->view->assign('url', $url);
|
||||
$this->view->assign('title', __('Login'));
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
/**
|
||||
* 退出登录
|
||||
*/
|
||||
public function logout()
|
||||
{
|
||||
if ($this->request->isPost()) {
|
||||
$this->token();
|
||||
//退出本站
|
||||
$this->auth->logout();
|
||||
$this->success(__('Logout successful'), url('user/index'));
|
||||
}
|
||||
$html = "<form id='logout_submit' name='logout_submit' action='' method='post'>" . token() . "<input type='submit' value='ok' style='display:none;'></form>";
|
||||
$html .= "<script>document.forms['logout_submit'].submit();</script>";
|
||||
|
||||
return $html;
|
||||
}
|
||||
|
||||
/**
|
||||
* 个人信息
|
||||
*/
|
||||
public function profile()
|
||||
{
|
||||
$this->view->assign('title', __('Profile'));
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改密码
|
||||
*/
|
||||
public function changepwd()
|
||||
{
|
||||
if ($this->request->isPost()) {
|
||||
$oldpassword = $this->request->post("oldpassword", '', null);
|
||||
$newpassword = $this->request->post("newpassword", '', null);
|
||||
$renewpassword = $this->request->post("renewpassword", '', null);
|
||||
$token = $this->request->post('__token__');
|
||||
$rule = [
|
||||
'oldpassword' => 'require|regex:\S{6,30}',
|
||||
'newpassword' => 'require|regex:\S{6,30}',
|
||||
'renewpassword' => 'require|regex:\S{6,30}|confirm:newpassword',
|
||||
'__token__' => 'token',
|
||||
];
|
||||
|
||||
$msg = [
|
||||
'renewpassword.confirm' => __('Password and confirm password don\'t match')
|
||||
];
|
||||
$data = [
|
||||
'oldpassword' => $oldpassword,
|
||||
'newpassword' => $newpassword,
|
||||
'renewpassword' => $renewpassword,
|
||||
'__token__' => $token,
|
||||
];
|
||||
$field = [
|
||||
'oldpassword' => __('Old password'),
|
||||
'newpassword' => __('New password'),
|
||||
'renewpassword' => __('Renew password')
|
||||
];
|
||||
$validate = new Validate($rule, $msg, $field);
|
||||
$result = $validate->check($data);
|
||||
if (!$result) {
|
||||
$this->error(__($validate->getError()), null, ['token' => $this->request->token()]);
|
||||
}
|
||||
|
||||
$ret = $this->auth->changepwd($newpassword, $oldpassword);
|
||||
if ($ret) {
|
||||
$this->success(__('Reset password successful'), url('user/login'));
|
||||
} else {
|
||||
$this->error($this->auth->getError(), null, ['token' => $this->request->token()]);
|
||||
}
|
||||
}
|
||||
$this->view->assign('title', __('Change password'));
|
||||
return $this->view->fetch();
|
||||
}
|
||||
|
||||
public function attachment()
|
||||
{
|
||||
//设置过滤方法
|
||||
$this->request->filter(['strip_tags']);
|
||||
if ($this->request->isAjax()) {
|
||||
$mimetypeQuery = [];
|
||||
$where = [];
|
||||
$filter = $this->request->request('filter');
|
||||
$filterArr = (array)json_decode($filter, true);
|
||||
if (isset($filterArr['mimetype']) && preg_match("/(\/|\,|\*)/", $filterArr['mimetype'])) {
|
||||
$this->request->get(['filter' => json_encode(array_diff_key($filterArr, ['mimetype' => '']))]);
|
||||
$mimetypeQuery = function ($query) use ($filterArr) {
|
||||
$mimetypeArr = array_filter(explode(',', $filterArr['mimetype']));
|
||||
foreach ($mimetypeArr as $index => $item) {
|
||||
$query->whereOr('mimetype', 'like', '%' . str_replace("/*", "/", $item) . '%');
|
||||
}
|
||||
};
|
||||
} elseif (isset($filterArr['mimetype'])) {
|
||||
$where['mimetype'] = ['like', '%' . $filterArr['mimetype'] . '%'];
|
||||
}
|
||||
|
||||
if (isset($filterArr['filename'])) {
|
||||
$where['filename'] = ['like', '%' . $filterArr['filename'] . '%'];
|
||||
}
|
||||
|
||||
if (isset($filterArr['createtime'])) {
|
||||
$timeArr = explode(' - ', $filterArr['createtime']);
|
||||
$where['createtime'] = ['between', [strtotime($timeArr[0]), strtotime($timeArr[1])]];
|
||||
}
|
||||
$search = $this->request->get('search');
|
||||
if ($search) {
|
||||
$where['filename'] = ['like', '%' . $search . '%'];
|
||||
}
|
||||
|
||||
$model = new Attachment();
|
||||
$offset = $this->request->get("offset", 0);
|
||||
$limit = $this->request->get("limit", 0);
|
||||
$total = $model
|
||||
->where($where)
|
||||
->where($mimetypeQuery)
|
||||
->where('user_id', $this->auth->id)
|
||||
->order("id", "DESC")
|
||||
->count();
|
||||
|
||||
$list = $model
|
||||
->where($where)
|
||||
->where($mimetypeQuery)
|
||||
->where('user_id', $this->auth->id)
|
||||
->order("id", "DESC")
|
||||
->limit($offset, $limit)
|
||||
->select();
|
||||
$cdnurl = preg_replace("/\/(\w+)\.php$/i", '', $this->request->root());
|
||||
foreach ($list as $k => &$v) {
|
||||
$v['fullurl'] = ($v['storage'] == 'local' ? $cdnurl : $this->view->config['upload']['cdnurl']) . $v['url'];
|
||||
}
|
||||
unset($v);
|
||||
$result = array("total" => $total, "rows" => $list);
|
||||
|
||||
return json($result);
|
||||
}
|
||||
$mimetype = $this->request->get('mimetype', '');
|
||||
$mimetype = substr($mimetype, -1) === '/' ? $mimetype . '*' : $mimetype;
|
||||
$this->view->assign('mimetype', $mimetype);
|
||||
$this->view->assign("mimetypeList", \app\common\model\Attachment::getMimetypeList());
|
||||
return $this->view->fetch();
|
||||
}
|
||||
}
|
||||
5
application/index/lang/en/index.php
Normal file
5
application/index/lang/en/index.php
Normal file
@@ -0,0 +1,5 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
];
|
||||
142
application/index/lang/zh-cn.php
Normal file
142
application/index/lang/zh-cn.php
Normal file
@@ -0,0 +1,142 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
'Keep login' => '保持会话',
|
||||
'Forgot password' => '忘记密码?',
|
||||
'Username' => '用户名',
|
||||
'User id' => '会员ID',
|
||||
'Nickname' => '昵称',
|
||||
'Password' => '密码',
|
||||
'Sign up' => '注 册',
|
||||
'Sign in' => '登 录',
|
||||
'Sign out' => '退 出',
|
||||
'Guest' => '游客',
|
||||
'Welcome' => '%s,你好!',
|
||||
'Add' => '添加',
|
||||
'Edit' => '编辑',
|
||||
'Delete' => '删除',
|
||||
'Move' => '移动',
|
||||
'Name' => '名称',
|
||||
'Status' => '状态',
|
||||
'Weigh' => '权重',
|
||||
'Operate' => '操作',
|
||||
'Warning' => '温馨提示',
|
||||
'Default' => '默认',
|
||||
'Article' => '文章',
|
||||
'Page' => '单页',
|
||||
'OK' => '确定',
|
||||
'Cancel' => '取消',
|
||||
'Loading' => '加载中',
|
||||
'Money' => '余额',
|
||||
'Score' => '积分',
|
||||
'More' => '更多',
|
||||
'Normal' => '正常',
|
||||
'Hidden' => '隐藏',
|
||||
'Submit' => '提交',
|
||||
'Reset' => '重置',
|
||||
'Execute' => '执行',
|
||||
'Close' => '关闭',
|
||||
'Search' => '搜索',
|
||||
'Refresh' => '刷新',
|
||||
'First' => '首页',
|
||||
'Previous' => '上一页',
|
||||
'Next' => '下一页',
|
||||
'Last' => '末页',
|
||||
'None' => '无',
|
||||
'Online' => '在线',
|
||||
'Logout' => '退出',
|
||||
'Profile' => '个人资料',
|
||||
'Index' => '首页',
|
||||
'Hot' => '热门',
|
||||
'Recommend' => '推荐',
|
||||
'Dashboard' => '控制台',
|
||||
'Code' => '编号',
|
||||
'Message' => '内容',
|
||||
'Line' => '行号',
|
||||
'File' => '文件',
|
||||
'Menu' => '菜单',
|
||||
'Type' => '类型',
|
||||
'Title' => '标题',
|
||||
'Content' => '内容',
|
||||
'Apply' => '应用',
|
||||
'Clear' => '清空',
|
||||
'Custom Range' => '自定义',
|
||||
'Today' => '今天',
|
||||
'Yesterday' => '昨天',
|
||||
'Last 7 days' => '最近7天',
|
||||
'Last 30 days' => '最近30天',
|
||||
'Last month' => '上月',
|
||||
'This month' => '本月',
|
||||
'Choose' => '选择',
|
||||
'Append' => '追加',
|
||||
'Upload' => '上传',
|
||||
'Memo' => '备注',
|
||||
'Parent' => '父级',
|
||||
'Params' => '参数',
|
||||
'Permission' => '权限',
|
||||
'Go back' => '返回上一页',
|
||||
'Jump now' => '立即跳转',
|
||||
'Advance search' => '高级搜索',
|
||||
'Check all' => '选中全部',
|
||||
'Expand all' => '展开全部',
|
||||
'Begin time' => '开始时间',
|
||||
'End time' => '结束时间',
|
||||
'Create time' => '创建时间',
|
||||
'Flag' => '标志',
|
||||
'Gitee' => '码云',
|
||||
'Github' => 'Github',
|
||||
'QQ group' => 'QQ群',
|
||||
'Member center' => '会员中心',
|
||||
'Copyrights' => '版权所有',
|
||||
'Responsive' => '响应式开发',
|
||||
'Languages' => '多语言',
|
||||
'Module' => '模块化开发',
|
||||
'Extension' => '自由可扩展',
|
||||
'Auth' => '权限管理',
|
||||
'The fastest framework based on ThinkPHP5 and Bootstrap' => '基于ThinkPHP5和Bootstrap的极速后台开发框架',
|
||||
'Features' => '功能特性',
|
||||
'Home' => '首页',
|
||||
'Store' => '插件市场',
|
||||
'Wxapp' => '小程序',
|
||||
'Services' => '服务',
|
||||
'Download' => '下载',
|
||||
'Demo' => '演示',
|
||||
'Donation' => '捐赠',
|
||||
'Forum' => '社区',
|
||||
'Docs' => '文档',
|
||||
'User center' => '会员中心',
|
||||
'Change password' => '修改密码',
|
||||
'Please login first' => '请登录后再操作',
|
||||
'Uploaded successful' => '上传成功',
|
||||
'You can upload up to %d file%s' => '你最多还可以上传%d个文件',
|
||||
'You can choose up to %d file%s' => '你最多还可以选择%d个文件',
|
||||
'Chunk file write error' => '分片写入失败',
|
||||
'Chunk file info error' => '分片文件错误',
|
||||
'Chunk file merge error' => '分片合并错误',
|
||||
'Chunk file disabled' => '未开启分片上传功能',
|
||||
'Cancel upload' => '取消上传',
|
||||
'Upload canceled' => '上传已取消',
|
||||
'No file upload or server upload limit exceeded' => '未上传文件或超出服务器上传限制',
|
||||
'Uploaded file format is limited' => '上传文件格式受限制',
|
||||
'Uploaded file is not a valid image' => '上传文件不是有效的图片文件',
|
||||
'Are you sure you want to cancel this upload?' => '确定取消上传?',
|
||||
'Remove file' => '移除文件',
|
||||
'You can only upload a maximum of %s files' => '你最多允许上传 %s 个文件',
|
||||
'You can\'t upload files of this type' => '不允许上传的文件类型',
|
||||
'Server responded with %s code' => '服务端响应(Code:%s)',
|
||||
'File is too big (%sMiB), Max filesize: %sMiB' => '当前上传(%sM),最大允许上传文件大小:%sM',
|
||||
'Send verification code' => '发送验证码',
|
||||
'Redirect now' => '立即跳转',
|
||||
'Operation completed' => '操作成功!',
|
||||
'Operation failed' => '操作失败!',
|
||||
'Unknown data format' => '未知的数据格式!',
|
||||
'Network error' => '网络错误!',
|
||||
'Advanced search' => '高级搜索',
|
||||
'Invalid parameters' => '未知参数',
|
||||
'No results were found' => '记录未找到',
|
||||
'Parameter %s can not be empty' => '参数%s不能为空',
|
||||
'Token verification error' => 'Token验证错误!',
|
||||
'You have no permission' => '你没有权限访问',
|
||||
'An unexpected error occurred' => '发生了一个意外错误,程序猿正在紧急处理中',
|
||||
'This page will be re-directed in %s seconds' => '页面将在 %s 秒后自动跳转',
|
||||
];
|
||||
3
application/index/lang/zh-cn/ajax.php
Normal file
3
application/index/lang/zh-cn/ajax.php
Normal file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
|
||||
return [];
|
||||
5
application/index/lang/zh-cn/index.php
Normal file
5
application/index/lang/zh-cn/index.php
Normal file
@@ -0,0 +1,5 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
|
||||
];
|
||||
89
application/index/lang/zh-cn/user.php
Normal file
89
application/index/lang/zh-cn/user.php
Normal file
@@ -0,0 +1,89 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
'User center' => '会员中心',
|
||||
'Register' => '注册',
|
||||
'Login' => '登录',
|
||||
'Account' => '账号',
|
||||
'Mobile' => '手机号',
|
||||
'Email' => '邮箱',
|
||||
'Captcha' => '验证码',
|
||||
'Lv' => 'Lv',
|
||||
'Score' => '积分',
|
||||
'Day' => '天',
|
||||
'Intro' => '个人介绍',
|
||||
'Successions' => '连续登录',
|
||||
'Maxsuccessions' => '最长连续登录',
|
||||
'Logintime' => '登录时间',
|
||||
'Prevtime' => '最后登录',
|
||||
'Change' => '修改',
|
||||
'Click to edit' => '点击编辑',
|
||||
'Email/Mobile/Username' => '邮箱/手机/用户名',
|
||||
'Sign up successful' => '注册成功',
|
||||
'Email active successful' => '邮箱激活成功',
|
||||
'Username can not be empty' => '用户名不能为空',
|
||||
'Username must be 3 to 30 characters' => '用户名必须3-30个字符',
|
||||
'Username must be 6 to 30 characters' => '用户名必须6-30个字符',
|
||||
'Account must be 3 to 50 characters' => '账户必须3-50个字符',
|
||||
'Password can not be empty' => '密码不能为空',
|
||||
'Password must be 6 to 30 characters' => '密码必须6-30个字符',
|
||||
'Email is incorrect' => '邮箱格式不正确',
|
||||
'Mobile is incorrect' => '手机格式不正确',
|
||||
'Username already exist' => '用户名已经存在',
|
||||
'Nickname already exist' => '昵称已经存在',
|
||||
'Email already exist' => '邮箱已经存在',
|
||||
'Mobile already exist' => '手机号已经存在',
|
||||
'Username is incorrect' => '用户名不正确',
|
||||
'Reset password' => '修改密码',
|
||||
'Reset password by email' => '通过邮箱',
|
||||
'Reset password by mobile' => '通过手机重置',
|
||||
'Reset password successful' => '修改密码成功',
|
||||
'Account is locked' => '账户已经被锁定',
|
||||
'Password is incorrect' => '密码不正确',
|
||||
'Account is incorrect' => '账户不正确',
|
||||
'Account not exist' => '账户不存在',
|
||||
'Account can not be empty' => '账户不能为空',
|
||||
'Username or password is incorrect' => '用户名或密码不正确',
|
||||
'You are not logged in' => '你当前还未登录',
|
||||
'You\'ve logged in, do not login again' => '你已经登录,请不要重复登录',
|
||||
'This guy hasn\'t written anything yet' => '这个人很懒,啥也没写',
|
||||
'Profile' => '个人资料',
|
||||
'Old password' => '旧密码',
|
||||
'New password' => '新密码',
|
||||
'Renew password' => '确认新密码',
|
||||
'Change password' => '修改密码',
|
||||
'New email' => '新邮箱',
|
||||
'New mobile' => '新手机号',
|
||||
'Change password successful' => '修改密码成功',
|
||||
'Password and confirm password don\'t match' => '两次输入的密码不一致',
|
||||
'Captcha is incorrect' => '验证码不正确',
|
||||
'Please try again after 1 day' => '请于1天后再尝试登录',
|
||||
'Logged in successful' => '登录成功',
|
||||
'Logout successful' => '退出成功',
|
||||
'User center already closed' => '会员中心已经关闭',
|
||||
'Don\'t have an account? Sign up' => '还没有账号?点击注册',
|
||||
'Already have an account? Sign in' => '已经有账号?点击登录',
|
||||
'Operation failed' => '操作失败',
|
||||
'Invalid parameters' => '参数不正确',
|
||||
'Change password failure' => '修改密码失败',
|
||||
'All' => '全部',
|
||||
'Url' => '物理路径',
|
||||
'Imagewidth' => '宽度',
|
||||
'Imageheight' => '高度',
|
||||
'Imagetype' => '图片类型',
|
||||
'Imageframes' => '图片帧数',
|
||||
'Preview' => '预览',
|
||||
'Filename' => '文件名',
|
||||
'Filesize' => '文件大小',
|
||||
'Mimetype' => 'Mime类型',
|
||||
'Image' => '图片',
|
||||
'Audio' => '音频',
|
||||
'Video' => '视频',
|
||||
'Text' => '文档',
|
||||
'Application' => '应用',
|
||||
'Zip' => '压缩包',
|
||||
'Extparam' => '透传数据',
|
||||
'Createtime' => '创建日期',
|
||||
'Uploadtime' => '上传时间',
|
||||
'Storage' => '存储引擎',
|
||||
];
|
||||
27
application/index/view/common/captcha.html
Normal file
27
application/index/view/common/captcha.html
Normal file
@@ -0,0 +1,27 @@
|
||||
<!--@formatter:off-->
|
||||
{if "[type]" == 'email'}
|
||||
<input type="text" name="captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length});digits;remote({:url('api/validate/check_ems_correct')}, event=[event], email:#email)" />
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-captcha" data-url="{:url('api/ems/send')}" data-type="email" data-event="[event]">发送验证码</a>
|
||||
</span>
|
||||
{elseif "[type]" == 'mobile'/}
|
||||
<input type="text" name="captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length});digits;remote({:url('api/validate/check_sms_correct')}, event=[event], mobile:#mobile)" />
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-captcha" data-url="{:url('api/sms/send')}" data-type="mobile" data-event="[event]">发送验证码</a>
|
||||
</span>
|
||||
{elseif "[type]" == 'wechat'/}
|
||||
{if get_addon_info('wechat')}
|
||||
<input type="text" name="captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length});remote({:addon_url('wechat/captcha/check')}, event=[event])" />
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-captcha" data-url="{:addon_url('wechat/captcha/send')}" data-type="wechat" data-event="[event]">获取验证码</a>
|
||||
</span>
|
||||
{else/}
|
||||
请在后台插件管理中安装《微信管理插件》
|
||||
{/if}
|
||||
{elseif "[type]" == 'text' /}
|
||||
<input type="text" name="captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length})" />
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<img src="{:captcha_src()}" width="100" height="32" onclick="this.src = '{:captcha_src()}?r=' + Math.random();"/>
|
||||
</span>
|
||||
{/if}
|
||||
<!--@formatter:on-->
|
||||
26
application/index/view/common/meta.html
Normal file
26
application/index/view/common/meta.html
Normal file
@@ -0,0 +1,26 @@
|
||||
<meta charset="utf-8">
|
||||
<title>{$title|default=''|htmlentities} – {$site.name|htmlentities}</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
|
||||
<meta name="renderer" content="webkit">
|
||||
|
||||
{if isset($keywords)}
|
||||
<meta name="keywords" content="{$keywords|htmlentities}">
|
||||
{/if}
|
||||
{if isset($description)}
|
||||
<meta name="description" content="{$description|htmlentities}">
|
||||
{/if}
|
||||
|
||||
<link rel="shortcut icon" href="__CDN__/assets/img/favicon.ico" />
|
||||
|
||||
<link href="__CDN__/assets/css/frontend{$Think.config.app_debug?'':'.min'}.css?v={$Think.config.site.version|htmlentities}" rel="stylesheet">
|
||||
|
||||
<!-- HTML5 shim, for IE6-8 support of HTML5 elements. All other JS at the end of file. -->
|
||||
<!--[if lt IE 9]>
|
||||
<script src="__CDN__/assets/js/html5shiv.js"></script>
|
||||
<script src="__CDN__/assets/js/respond.min.js"></script>
|
||||
<![endif]-->
|
||||
<script type="text/javascript">
|
||||
var require = {
|
||||
config: {$config|json_encode}
|
||||
};
|
||||
</script>
|
||||
1
application/index/view/common/script.html
Normal file
1
application/index/view/common/script.html
Normal file
@@ -0,0 +1 @@
|
||||
<script src="__CDN__/assets/js/require{$Think.config.app_debug?'':'.min'}.js" data-main="__CDN__/assets/js/require-frontend{$Think.config.app_debug?'':'.min'}.js?v={$site.version|htmlentities}"></script>
|
||||
12
application/index/view/common/sidenav.html
Normal file
12
application/index/view/common/sidenav.html
Normal file
@@ -0,0 +1,12 @@
|
||||
<div class="sidebar-toggle"><i class="fa fa-bars"></i></div>
|
||||
<div class="sidenav" id="sidebar-nav">
|
||||
{:hook('user_sidenav_before')}
|
||||
<ul class="list-group">
|
||||
<li class="list-group-heading">{:__('Member center')}</li>
|
||||
<li class="list-group-item {:check_nav_active('user/index')}"> <a href="{:url('user/index')}"><i class="fa fa-user-circle fa-fw"></i> {:__('User center')}</a> </li>
|
||||
<li class="list-group-item {:check_nav_active('user/profile')}"> <a href="{:url('user/profile')}"><i class="fa fa-user-o fa-fw"></i> {:__('Profile')}</a> </li>
|
||||
<li class="list-group-item {:check_nav_active('user/changepwd')}"> <a href="{:url('user/changepwd')}"><i class="fa fa-key fa-fw"></i> {:__('Change password')}</a> </li>
|
||||
<li class="list-group-item {:check_nav_active('user/logout')}"> <a href="{:url('user/logout')}"><i class="fa fa-sign-out fa-fw"></i> {:__('Sign out')}</a> </li>
|
||||
</ul>
|
||||
{:hook('user_sidenav_after')}
|
||||
</div>
|
||||
34
application/index/view/index/index.html
Normal file
34
application/index/view/index/index.html
Normal file
@@ -0,0 +1,34 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
<title>{$site.name|htmlentities}</title>
|
||||
<link rel="shortcut icon" href="__CDN__/assets/img/favicon.ico"/>
|
||||
<link href="__CDN__/assets/css/index.css" rel="stylesheet">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<div id="mainbody">
|
||||
<div class="container">
|
||||
<div class="text-center">
|
||||
<h1>{$site.name|htmlentities}</h1>
|
||||
<a href="{:url('index/user/index', '', false, true)}">{:__('Member center')}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="footer">
|
||||
<div class="container">
|
||||
<p>Copyright @ {$site.name|htmlentities} {:date('Y',time())} 版权所有 <a href="https://beian.miit.gov.cn" target="_blank">{$site.beian|htmlentities}</a></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
159
application/index/view/index/up.html
Normal file
159
application/index/view/index/up.html
Normal file
@@ -0,0 +1,159 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>文件上传表单</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
max-width: 600px;
|
||||
margin: 0 auto;
|
||||
padding: 20px;
|
||||
line-height: 1.6;
|
||||
}
|
||||
.upload-container {
|
||||
border: 2px dashed #ccc;
|
||||
padding: 30px;
|
||||
text-align: center;
|
||||
border-radius: 5px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.upload-btn {
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
padding: 10px 20px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
cursor: pointer;
|
||||
font-size: 16px;
|
||||
}
|
||||
.upload-btn:hover {
|
||||
background-color: #45a049;
|
||||
}
|
||||
#file-info {
|
||||
margin-top: 10px;
|
||||
font-size: 14px;
|
||||
color: #666;
|
||||
}
|
||||
.progress-container {
|
||||
margin-top: 20px;
|
||||
display: none;
|
||||
}
|
||||
.progress-bar {
|
||||
width: 100%;
|
||||
background-color: #f1f1f1;
|
||||
border-radius: 4px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
#progress {
|
||||
height: 20px;
|
||||
background-color: #4CAF50;
|
||||
border-radius: 4px;
|
||||
width: 0%;
|
||||
text-align: center;
|
||||
line-height: 20px;
|
||||
color: white;
|
||||
}
|
||||
#status {
|
||||
font-size: 14px;
|
||||
color: #666;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>文件上传</h1>
|
||||
|
||||
<form id="uploadForm" enctype="multipart/form-data">
|
||||
<div class="upload-container">
|
||||
<input type="file" id="fileInput" name="file" style="display: none;">
|
||||
<label for="fileInput" class="upload-btn">选择文件</label>
|
||||
<div id="file-info">未选择文件</div>
|
||||
</div>
|
||||
|
||||
<div class="progress-container" id="progressContainer">
|
||||
<div class="progress-bar">
|
||||
<div id="progress">0%</div>
|
||||
</div>
|
||||
<div id="status">准备上传...</div>
|
||||
</div>
|
||||
|
||||
<button type="submit" class="upload-btn">上传文件</button>
|
||||
</form>
|
||||
|
||||
<script>
|
||||
document.getElementById('fileInput').addEventListener('change', function(e) {
|
||||
const fileInfo = document.getElementById('file-info');
|
||||
if (this.files.length > 0) {
|
||||
const file = this.files[0];
|
||||
fileInfo.textContent = `已选择: ${file.name} (${formatFileSize(file.size)})`;
|
||||
} else {
|
||||
fileInfo.textContent = '未选择文件';
|
||||
}
|
||||
});
|
||||
|
||||
document.getElementById('uploadForm').addEventListener('submit', function(e) {
|
||||
e.preventDefault();
|
||||
|
||||
const fileInput = document.getElementById('fileInput');
|
||||
if (fileInput.files.length === 0) {
|
||||
alert('请先选择文件');
|
||||
return;
|
||||
}
|
||||
|
||||
const file = fileInput.files[0];
|
||||
const formData = new FormData();
|
||||
formData.append('file', file);
|
||||
|
||||
const progressContainer = document.getElementById('progressContainer');
|
||||
const progressBar = document.getElementById('progress');
|
||||
const status = document.getElementById('status');
|
||||
|
||||
progressContainer.style.display = 'block';
|
||||
status.textContent = '上传中...';
|
||||
|
||||
const xhr = new XMLHttpRequest();
|
||||
xhr.open('POST', 'http://chat.qxmier.com/adminapi/UploadFile/file_upload', true);
|
||||
|
||||
xhr.upload.onprogress = function(e) {
|
||||
if (e.lengthComputable) {
|
||||
const percent = Math.round((e.loaded / e.total) * 100);
|
||||
progressBar.style.width = percent + '%';
|
||||
progressBar.textContent = percent + '%';
|
||||
}
|
||||
};
|
||||
|
||||
xhr.onload = function() {
|
||||
if (xhr.status === 200) {
|
||||
status.textContent = '上传成功!';
|
||||
try {
|
||||
const response = JSON.parse(xhr.responseText);
|
||||
console.log('服务器响应:', response);
|
||||
alert('文件上传成功!');
|
||||
} catch (e) {
|
||||
console.log('响应解析失败:', e);
|
||||
}
|
||||
} else {
|
||||
status.textContent = '上传失败: ' + xhr.statusText;
|
||||
alert('上传失败: ' + xhr.statusText);
|
||||
}
|
||||
};
|
||||
|
||||
xhr.onerror = function() {
|
||||
status.textContent = '上传过程中发生错误';
|
||||
alert('上传过程中发生错误');
|
||||
};
|
||||
|
||||
xhr.send(formData);
|
||||
});
|
||||
|
||||
function formatFileSize(bytes) {
|
||||
if (bytes === 0) return '0 Bytes';
|
||||
const k = 1024;
|
||||
const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB'];
|
||||
const i = Math.floor(Math.log(bytes) / Math.log(k));
|
||||
return parseFloat((bytes / Math.pow(k, i)).toFixed(2)) + ' ' + sizes[i];
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
63
application/index/view/layout/default.html
Normal file
63
application/index/view/layout/default.html
Normal file
@@ -0,0 +1,63 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
{include file="common/meta" /}
|
||||
<link href="__CDN__/assets/css/user.css?v={$Think.config.site.version|htmlentities}" rel="stylesheet">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<nav class="navbar navbar-white navbar-fixed-top" role="navigation">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#header-navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="{:url('/')}">{$site.name|htmlentities}</a>
|
||||
</div>
|
||||
<div class="collapse navbar-collapse" id="header-navbar">
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li><a href="{:url('/')}">{:__('Home')}</a></li>
|
||||
<li class="dropdown">
|
||||
{if $user}
|
||||
<a href="{:url('user/index')}" class="dropdown-toggle" data-toggle="dropdown">
|
||||
<span class="avatar-img"><img src="{$user.avatar|htmlentities|cdnurl}" alt=""></span>
|
||||
<span class="visible-xs-inline-block" style="padding:5px;">{$user.nickname} <b class="caret"></b></span>
|
||||
</a>
|
||||
{else /}
|
||||
<a href="{:url('user/index')}" class="dropdown-toggle" data-toggle="dropdown">{:__('Member center')} <b class="caret"></b></a>
|
||||
{/if}
|
||||
<ul class="dropdown-menu">
|
||||
{if $user}
|
||||
<li><a href="{:url('user/index')}"><i class="fa fa-user-circle fa-fw"></i>{:__('User center')}</a></li>
|
||||
<li><a href="{:url('user/profile')}"><i class="fa fa-user-o fa-fw"></i>{:__('Profile')}</a></li>
|
||||
<li><a href="{:url('user/changepwd')}"><i class="fa fa-key fa-fw"></i>{:__('Change password')}</a></li>
|
||||
<li><a href="{:url('user/logout')}"><i class="fa fa-sign-out fa-fw"></i>{:__('Sign out')}</a></li>
|
||||
{else /}
|
||||
<li><a href="{:url('user/login')}"><i class="fa fa-sign-in fa-fw"></i> {:__('Sign in')}</a></li>
|
||||
<li><a href="{:url('user/register')}"><i class="fa fa-user-o fa-fw"></i> {:__('Sign up')}</a></li>
|
||||
{/if}
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<main class="content">
|
||||
{__CONTENT__}
|
||||
</main>
|
||||
|
||||
<footer class="footer" style="clear:both">
|
||||
<p class="copyright">Copyright © {:date("Y")} {$site.name|htmlentities} All Rights Reserved <a href="https://beian.miit.gov.cn" target="_blank">{$site.beian|htmlentities}</a></p>
|
||||
</footer>
|
||||
|
||||
{include file="common/script" /}
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
61
application/index/view/user/attachment.html
Normal file
61
application/index/view/user/attachment.html
Normal file
@@ -0,0 +1,61 @@
|
||||
<link rel="stylesheet" href="__CDN__/assets/libs/bootstrap-table/dist/bootstrap-table.min.css">
|
||||
{if $Think.get.dialog}
|
||||
<style>
|
||||
body {
|
||||
padding-top: 0;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
nav.navbar-fixed-top, footer.footer {
|
||||
display: none;
|
||||
}
|
||||
|
||||
main.content {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.fixed-table-container {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.panel-heading .nav-tabs {
|
||||
padding: 0 15px;
|
||||
}
|
||||
|
||||
.panel-heading .nav-tabs li {
|
||||
font-size: 14px;
|
||||
}
|
||||
</style>
|
||||
{/if}
|
||||
<div class="panel panel-default panel-intro" style="padding:0;">
|
||||
{if !$Think.get.mimetype||$Think.get.mimetype=='*'}
|
||||
<div class="panel-heading">
|
||||
<ul class="nav nav-tabs" data-field="mimetype">
|
||||
<li class="active"><a href="#t-all" data-value="" data-toggle="tab">{:__('All')}</a></li>
|
||||
{foreach name="mimetypeList" item="vo"}
|
||||
<li><a href="#t-{$key}" data-value="{$key}" data-toggle="tab">{$vo}</a></li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<div class="panel-body">
|
||||
<div id="myTabContent" class="tab-content">
|
||||
<div class="tab-pane fade active in" id="one">
|
||||
<div class="widget-body no-padding">
|
||||
<div id="toolbar" class="toolbar">
|
||||
<a href="javascript:;" class="btn btn-primary btn-refresh" title="刷新"><i class="fa fa-refresh"></i> </a>
|
||||
<span><button type="button" id="faupload-image" class="btn btn-success faupload" data-mimetype="{$mimetype|default=''|htmlentities}" data-multiple="true"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
|
||||
{if request()->get('multiple') == 'true'}
|
||||
<a class="btn btn-danger btn-choose-multi"><i class="fa fa-check"></i> {:__('Choose')}</a>
|
||||
{/if}
|
||||
</div>
|
||||
<table id="table" class="table table-bordered table-hover" width="100%">
|
||||
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
43
application/index/view/user/changepwd.html
Normal file
43
application/index/view/user/changepwd.html
Normal file
@@ -0,0 +1,43 @@
|
||||
<div id="content-container" class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
{include file="common/sidenav" /}
|
||||
</div>
|
||||
<div class="col-md-9">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-body">
|
||||
<h2 class="page-header">{:__('Change password')}</h2>
|
||||
<form id="changepwd-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
|
||||
{:token()}
|
||||
<div class="form-group">
|
||||
<label for="oldpassword" class="control-label col-xs-12 col-sm-2">{:__('Old password')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<input type="password" class="form-control" id="oldpassword" name="oldpassword" value="" data-rule="required;password" placeholder="{:__('Old password')}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="newpassword" class="control-label col-xs-12 col-sm-2">{:__('New password')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<input type="password" class="form-control" id="newpassword" name="newpassword" value="" data-rule="required;password" placeholder="{:__('New password')}" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="renewpassword" class="control-label col-xs-12 col-sm-2">{:__('Renew password')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<input type="password" class="form-control" id="renewpassword" name="renewpassword" value="" data-rule="required;password" placeholder="{:__('Renew password')}" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group normal-footer">
|
||||
<label class="control-label col-xs-12 col-sm-2"></label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<button type="submit" class="btn btn-primary btn-embossed disabled">{:__('Submit')}</button>
|
||||
<button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
69
application/index/view/user/index.html
Normal file
69
application/index/view/user/index.html
Normal file
@@ -0,0 +1,69 @@
|
||||
<style>
|
||||
.basicinfo {
|
||||
margin: 15px 0;
|
||||
}
|
||||
|
||||
.basicinfo .row > .col-xs-4 {
|
||||
padding-right: 0;
|
||||
}
|
||||
|
||||
.basicinfo .row > div {
|
||||
margin: 5px 0;
|
||||
}
|
||||
</style>
|
||||
<div id="content-container" class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
{include file="common/sidenav" /}
|
||||
</div>
|
||||
<div class="col-md-9">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-body">
|
||||
<h2 class="page-header">
|
||||
{:__('Member center')}
|
||||
<a href="{:url('user/profile')}" class="btn btn-primary pull-right"><i class="fa fa-pencil"></i> {:__('Profile')}</a>
|
||||
</h2>
|
||||
<div class="row user-baseinfo">
|
||||
<div class="col-md-3 col-sm-3 col-xs-3 text-center user-center">
|
||||
<a href="{:url('user/profile')}" title="{:__('Click to edit')}">
|
||||
<span class="avatar-img"><img src="{$user.avatar|htmlentities|cdnurl}" alt=""></span>
|
||||
</a>
|
||||
</div>
|
||||
<div class="col-md-9 col-sm-9 col-xs-9">
|
||||
<div class="ui-content">
|
||||
<h4><a href="{:url('user/profile')}">{$user.nickname|htmlentities}</a></h4>
|
||||
<p class="text-muted">
|
||||
{$user.bio|default=__("This guy hasn't written anything yet")|htmlentities}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-9 col-sm-9 col-xs-12">
|
||||
<div class="ui-content">
|
||||
<div class="basicinfo">
|
||||
<div class="row">
|
||||
<div class="col-xs-4 col-md-2">{:__('Money')}</div>
|
||||
<div class="col-xs-8 col-md-4">
|
||||
<a href="javascript:;" class="viewmoney">{$user.money}</a>
|
||||
</div>
|
||||
<div class="col-xs-4 col-md-2">{:__('Score')}</div>
|
||||
<div class="col-xs-8 col-md-4">
|
||||
<a href="javascript:;" class="viewscore">{$user.score}</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-4 col-md-2">{:__('Logintime')}</div>
|
||||
<div class="col-xs-8 col-md-4">{$user.logintime|date="Y-m-d H:i:s",###}</div>
|
||||
<div class="col-xs-4 col-md-2">{:__('Prevtime')}</div>
|
||||
<div class="col-xs-8 col-md-4">{$user.prevtime|date="Y-m-d H:i:s",###}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
94
application/index/view/user/login.html
Normal file
94
application/index/view/user/login.html
Normal file
@@ -0,0 +1,94 @@
|
||||
<div id="content-container" class="container">
|
||||
<div class="user-section login-section">
|
||||
<div class="logon-tab clearfix"><a class="active">{:__('Sign in')}</a> <a href="{:url('user/register')}?url={$url|urlencode|htmlentities}">{:__('Sign up')}</a></div>
|
||||
<div class="login-main">
|
||||
<form name="form" id="login-form" class="form-vertical" method="POST" action="">
|
||||
<!--@IndexLoginFormBegin-->
|
||||
<input type="hidden" name="url" value="{$url|htmlentities}"/>
|
||||
{:token()}
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="account">{:__('Account')}</label>
|
||||
<div class="controls">
|
||||
<input class="form-control" id="account" type="text" name="account" value="" data-rule="required" placeholder="{:__('Email/Mobile/Username')}" autocomplete="off">
|
||||
<div class="help-block"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="password">{:__('Password')}</label>
|
||||
<div class="controls">
|
||||
<input class="form-control" id="password" type="password" name="password" data-rule="required;password" placeholder="{:__('Password')}" autocomplete="off">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="controls">
|
||||
<div class="checkbox inline">
|
||||
<label>
|
||||
<input type="checkbox" name="keeplogin" checked="checked" value="1"> {:__('Keep login')}
|
||||
</label>
|
||||
</div>
|
||||
<div class="pull-right"><a href="javascript:;" class="btn-forgot">{:__('Forgot password')}</a></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<button type="submit" class="btn btn-primary btn-lg btn-block">{:__('Sign in')}</button>
|
||||
<a href="{:url('user/register')}?url={$url|urlencode|htmlentities}" class="btn btn-default btn-lg btn-block mt-3 no-border">{:__("Don't have an account? Sign up")}</a>
|
||||
</div>
|
||||
<!--@IndexLoginFormEnd-->
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/html" id="resetpwdtpl">
|
||||
<form id="resetpwd-form" class="form-horizontal form-layer" method="POST" action="{:url('api/user/resetpwd')}">
|
||||
<div class="form-body">
|
||||
<input type="hidden" name="action" value="resetpwd"/>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-xs-12 col-sm-3">{:__('Type')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<div class="radio">
|
||||
<label for="type-email"><input id="type-email" checked="checked" name="type" data-send-url="{:url('api/ems/send')}" data-check-url="{:url('api/validate/check_ems_correct')}" type="radio" value="email"> {:__('Reset password by email')}</label>
|
||||
<label for="type-mobile"><input id="type-mobile" name="type" type="radio" data-send-url="{:url('api/sms/send')}" data-check-url="{:url('api/validate/check_sms_correct')}" value="mobile"> {:__('Reset password by mobile')}</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" data-type="email">
|
||||
<label for="email" class="control-label col-xs-12 col-sm-3">{:__('Email')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<input type="text" class="form-control" id="email" name="email" value="" data-rule="required(#type-email:checked);email;remote({:url('api/validate/check_email_exist')}, event=resetpwd, id=0)" placeholder="">
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group hide" data-type="mobile">
|
||||
<label for="mobile" class="control-label col-xs-12 col-sm-3">{:__('Mobile')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<input type="text" class="form-control" id="mobile" name="mobile" value="" data-rule="required(#type-mobile:checked);mobile;remote({:url('api/validate/check_mobile_exist')}, event=resetpwd, id=0)" placeholder="">
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="captcha" class="control-label col-xs-12 col-sm-3">{:__('Captcha')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<div class="input-group">
|
||||
<input type="text" name="captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length});digits;remote({:url('api/validate/check_ems_correct')}, event=resetpwd, email:#email)"/>
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-primary btn-captcha" data-url="{:url('api/ems/send')}" data-type="email" data-event="resetpwd">{:__('Send verification code')}</a>
|
||||
</span>
|
||||
</div>
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="newpassword" class="control-label col-xs-12 col-sm-3">{:__('New password')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<input type="password" class="form-control" id="newpassword" name="newpassword" value="" data-rule="required;password" placeholder="">
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group form-footer">
|
||||
<div class="col-xs-12 col-sm-8 col-sm-offset-3">
|
||||
<button type="submit" class="btn btn-md btn-primary">{:__('Ok')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</script>
|
||||
200
application/index/view/user/profile.html
Normal file
200
application/index/view/user/profile.html
Normal file
@@ -0,0 +1,200 @@
|
||||
<style>
|
||||
.profile-avatar-container {
|
||||
position:relative;
|
||||
width:100px;
|
||||
}
|
||||
.profile-avatar-container .profile-user-img{
|
||||
width:100px;
|
||||
height:100px;
|
||||
}
|
||||
.profile-avatar-container .profile-avatar-text {
|
||||
display:none;
|
||||
}
|
||||
.profile-avatar-container:hover .profile-avatar-text {
|
||||
display:block;
|
||||
position:absolute;
|
||||
height:100px;
|
||||
width:100px;
|
||||
background:#444;
|
||||
opacity: .6;
|
||||
color: #fff;
|
||||
top:0;
|
||||
left:0;
|
||||
line-height: 100px;
|
||||
text-align: center;
|
||||
}
|
||||
.profile-avatar-container button{
|
||||
position:absolute;
|
||||
top:0;left:0;width:100px;height:100px;opacity: 0;
|
||||
}
|
||||
</style>
|
||||
<div id="content-container" class="container">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
{include file="common/sidenav" /}
|
||||
</div>
|
||||
<div class="col-md-9">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-body">
|
||||
<h2 class="page-header">{:__('Profile')}</h2>
|
||||
<form id="profile-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="{:url('api/user/profile')}">
|
||||
{:token()}
|
||||
<input type="hidden" name="avatar" id="c-avatar" value="{:$user->getData('avatar')}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label col-xs-12 col-sm-2"></label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<div class="profile-avatar-container">
|
||||
<img class="profile-user-img img-responsive img-circle" src="{$user.avatar|htmlentities|cdnurl}" alt="">
|
||||
<div class="profile-avatar-text img-circle">{:__('Click to edit')}</div>
|
||||
<button type="button" id="faupload-avatar" class="faupload" data-mimetype="png,jpg,jpeg,gif" data-input-id="c-avatar"><i class="fa fa-upload"></i> {:__('Upload')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-xs-12 col-sm-2">{:__('Username')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<input type="text" class="form-control" id="username" name="username" value="{$user.username|htmlentities}" data-rule="required;username;remote({:url('api/validate/check_username_available')}, id={$user.id})" placeholder="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-xs-12 col-sm-2">{:__('Nickname')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<input type="text" class="form-control" id="nickname" name="nickname" value="{$user.nickname|htmlentities}" data-rule="required;remote({:url('api/validate/check_nickname_available')}, id={$user.id})" placeholder="">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="c-bio" class="control-label col-xs-12 col-sm-2">{:__('Intro')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<input id="c-bio" data-rule="" data-tip="一句话介绍一下你自己" class="form-control" name="bio" type="text" value="{$user.bio|htmlentities}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="c-email" class="control-label col-xs-12 col-sm-2">{:__('Email')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<div class="input-group">
|
||||
<input type="text" class="form-control" id="c-email" name="email" value="{$user.email|htmlentities}" disabled placeholder="">
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-change" data-type="email">{:__('Change')}</a>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="c-mobile" class="control-label col-xs-12 col-sm-2">{:__('Mobile')}:</label>
|
||||
<div class="col-xs-12 col-sm-4">
|
||||
<div class="input-group">
|
||||
<input type="text" class="form-control" id="c-mobile" name="mobile" value="{$user.mobile|htmlentities}" disabled placeholder="">
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-change" data-type="mobile">{:__('Change')}</a>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group normal-footer">
|
||||
<label class="control-label col-xs-12 col-sm-2"></label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<button type="submit" class="btn btn-primary btn-embossed disabled">{:__('Ok')}</button>
|
||||
<button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="text/html" id="emailtpl">
|
||||
<form id="email-form" class="form-horizontal form-layer" method="POST" action="{:url('api/user/changeemail')}">
|
||||
<div class="form-body">
|
||||
<input type="hidden" name="action" value="changeemail" />
|
||||
<div class="form-group">
|
||||
<label class="control-label col-xs-12 col-sm-3">{:__('New Email')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<input type="text" class="form-control" id="email" name="email" value="" data-rule="required;email;remote({:url('api/validate/check_email_available')}, event=changeemail, id={$user.id})" placeholder="{:__('New email')}">
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-xs-12 col-sm-3">{:__('Captcha')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<div class="input-group">
|
||||
<input type="text" name="captcha" id="email-captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length});digits;remote({:url('api/validate/check_ems_correct')}, event=changeemail, email:#email)" />
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-captcha" data-url="{:url('api/ems/send')}" data-type="email" data-event="changeemail">获取验证码</a>
|
||||
</span>
|
||||
</div>
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-footer">
|
||||
<div class="form-group" style="margin-bottom:0;">
|
||||
<div class="col-xs-12 col-sm-8 col-sm-offset-3">
|
||||
<button type="submit" class="btn btn-md btn-primary">{:__('Submit')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</script>
|
||||
<script type="text/html" id="mobiletpl">
|
||||
<form id="mobile-form" class="form-horizontal form-layer" method="POST" action="{:url('api/user/changemobile')}">
|
||||
<div class="form-body">
|
||||
<input type="hidden" name="action" value="changemobile" />
|
||||
<div class="form-group">
|
||||
<label for="c-mobile" class="control-label col-xs-12 col-sm-3">{:__('New mobile')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<input type="text" class="form-control" id="mobile" name="mobile" value="" data-rule="required;mobile;remote({:url('api/validate/check_mobile_available')}, event=changemobile, id={$user.id})" placeholder="{:__('New mobile')}">
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label for="mobile-captcha" class="control-label col-xs-12 col-sm-3">{:__('Captcha')}:</label>
|
||||
<div class="col-xs-12 col-sm-8">
|
||||
<div class="input-group">
|
||||
<input type="text" name="captcha" id="mobile-captcha" class="form-control" data-rule="required;length({$Think.config.captcha.length});digits;remote({:url('api/validate/check_sms_correct')}, event=changemobile, mobile:#mobile)" />
|
||||
<span class="input-group-btn" style="padding:0;border:none;">
|
||||
<a href="javascript:;" class="btn btn-info btn-captcha" data-url="{:url('api/sms/send')}" data-type="mobile" data-event="changemobile">获取验证码</a>
|
||||
</span>
|
||||
</div>
|
||||
<span class="msg-box"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-footer">
|
||||
<div class="form-group" style="margin-bottom:0;">
|
||||
<div class="col-xs-12 col-sm-8 col-sm-offset-3">
|
||||
<button type="submit" class="btn btn-md btn-primary">{:__('Submit')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</script>
|
||||
<style>
|
||||
.form-layer {height:100%;min-height:150px;min-width:300px;}
|
||||
.form-body {
|
||||
width:100%;
|
||||
overflow:auto;
|
||||
top:0;
|
||||
position:absolute;
|
||||
z-index:10;
|
||||
bottom:50px;
|
||||
padding:15px;
|
||||
}
|
||||
.form-layer .form-footer {
|
||||
height:50px;
|
||||
line-height:50px;
|
||||
background-color: #ecf0f1;
|
||||
width:100%;
|
||||
position:absolute;
|
||||
z-index:200;
|
||||
bottom:0;
|
||||
margin:0;
|
||||
}
|
||||
.form-footer .form-group{
|
||||
margin-left:0;
|
||||
margin-right:0;
|
||||
}
|
||||
</style>
|
||||
61
application/index/view/user/register.html
Normal file
61
application/index/view/user/register.html
Normal file
@@ -0,0 +1,61 @@
|
||||
<div id="content-container" class="container">
|
||||
<div class="user-section login-section">
|
||||
<div class="logon-tab clearfix"><a href="{:url('user/login')}?url={$url|urlencode|htmlentities}">{:__('Sign in')}</a> <a class="active">{:__('Sign up')}</a></div>
|
||||
<div class="login-main">
|
||||
<form name="form1" id="register-form" class="form-vertical" method="POST" action="">
|
||||
<!--@IndexRegisterFormBegin-->
|
||||
<input type="hidden" name="invite_user_id" value="0"/>
|
||||
<input type="hidden" name="url" value="{$url|htmlentities}"/>
|
||||
{:token()}
|
||||
<div class="form-group">
|
||||
<label class="control-label required">{:__('Email')}<span class="text-success"></span></label>
|
||||
<div class="controls">
|
||||
<input type="text" name="email" id="email" data-rule="required;email" class="form-control" placeholder="{:__('Email')}">
|
||||
<p class="help-block"></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{:__('Username')}</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="username" name="username" data-rule="required;username" class="form-control" placeholder="{:__('Username must be 3 to 30 characters')}">
|
||||
<p class="help-block"></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{:__('Password')}</label>
|
||||
<div class="controls">
|
||||
<input type="password" id="password" name="password" data-rule="required;password" class="form-control" placeholder="{:__('Password must be 6 to 30 characters')}">
|
||||
<p class="help-block"></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label">{:__('Mobile')}</label>
|
||||
<div class="controls">
|
||||
<input type="text" id="mobile" name="mobile" data-rule="required;mobile" class="form-control" placeholder="{:__('Mobile')}">
|
||||
<p class="help-block"></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--@CaptchaBegin-->
|
||||
{if $captchaType}
|
||||
<div class="form-group">
|
||||
<label class="control-label">{:__('Captcha')}</label>
|
||||
<div class="controls">
|
||||
<div class="input-group">
|
||||
{include file="common/captcha" event="register" type="$captchaType" /}
|
||||
</div>
|
||||
<p class="help-block"></p>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
<!--@CaptchaEnd-->
|
||||
|
||||
<div class="form-group">
|
||||
<button type="submit" class="btn btn-primary btn-lg btn-block">{:__('Sign up')}</button>
|
||||
<a href="{:url('user/login')}?url={$url|urlencode|htmlentities}" class="btn btn-default btn-lg btn-block mt-3 no-border">{:__('Already have an account? Sign in')}</a>
|
||||
</div>
|
||||
<!--@IndexRegisterFormEnd-->
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user