Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
smart_core_connect
/
core-connect
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
f0493c63
authored
Jun 06, 2018
by
Teeradone Darunnat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
teeradone addValidate passwordtext
parent
be304415
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
www/webroot/js/validate/jQuery.validate.addValidate.js
+3
-0
No files found.
www/webroot/js/validate/jQuery.validate.addValidate.js
View file @
f0493c63
...
@@ -26,6 +26,9 @@
...
@@ -26,6 +26,9 @@
| 19. ckquarter-min ,Example 'ckquarter-min' = '2'
| 19. ckquarter-min ,Example 'ckquarter-min' = '2'
| ------------------------------------------------------------------------------------------------------------------
| ------------------------------------------------------------------------------------------------------------------
*/
*/
jQuery
.
validator
.
addMethod
(
"passwordtext"
,
function
(
value
,
element
)
{
return
this
.
optional
(
element
)
||
/^
([
a-zA-Z0-9
])
+$/
.
test
(
value
);
},
"รหัสผ่านต้องเป็นตัวอักษร a-z, A-Z และ 0-9 ความยาวขั้นต่ำ 6 ตัวอักษร."
);
jQuery
.
validator
.
addMethod
(
"emailtext"
,
function
(
value
,
element
)
{
jQuery
.
validator
.
addMethod
(
"emailtext"
,
function
(
value
,
element
)
{
return
this
.
optional
(
element
)
||
/^
([
a-zA-Z0-9@_.
])
+$/
.
test
(
value
);
return
this
.
optional
(
element
)
||
/^
([
a-zA-Z0-9@_.
])
+$/
.
test
(
value
);
},
"โปรดระบุที่อยู่อีเมล์ที่ถูกต้อง."
);
},
"โปรดระบุที่อยู่อีเมล์ที่ถูกต้อง."
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment