Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
sora
/
sanitary-net
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
59964145
authored
Mar 01, 2023
by
o.kimura
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
バリデートにblurを追加
parent
a3e62071
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
shared/js/form.js
shared/js/form.js
View file @
59964145
$
(
function
()
{
$
(
"#your_name"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#your_name"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".name_err"
).
css
(
"display"
,
"block"
);
$
(
".name_err"
).
text
(
"お名前が未入力です。"
)
...
...
@@ -13,7 +13,7 @@ $(function () {
}
});
$
(
"#hurigana"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#hurigana"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".huri_err"
).
css
(
"display"
,
"block"
);
$
(
".huri_err"
).
text
(
"フリガナが未入力です。"
)
...
...
@@ -26,7 +26,7 @@ $(function () {
}
});
$
(
"#mail_add"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#mail_add"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".mail_add_err"
).
css
(
"display"
,
"block"
);
$
(
".mail_add_err"
).
text
(
"メールアドレスが未入力です。"
);
...
...
@@ -43,7 +43,7 @@ $(function () {
}
});
$
(
"#mail_confirm"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#mail_confirm"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".add_confirm_err"
).
css
(
"display"
,
"block"
);
$
(
".add_confirm_err"
).
text
(
"確認用メールアドレスが未入力です。"
);
...
...
@@ -64,7 +64,7 @@ $(function () {
}
});
$
(
"#age"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#age"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".age_err"
).
css
(
"display"
,
"block"
);
$
(
".age_err"
).
text
(
"年齢が未入力です。"
);
...
...
@@ -98,7 +98,7 @@ $(function () {
}
});
$
(
"#addr"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#addr"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".add_err"
).
css
(
"display"
,
"block"
);
$
(
".add_err"
).
text
(
"住所が未入力です。"
)
...
...
@@ -122,7 +122,7 @@ if ($(this).val().match(/^\d+$/)) {
}
});*/
$
(
"#content"
).
on
(
"keydown keyup"
,
function
()
{
$
(
"#content"
).
on
(
"keydown keyup
blur
"
,
function
()
{
if
(
$
(
this
).
val
()
==
""
)
{
$
(
".question_err"
).
css
(
"display"
,
"block"
);
$
(
".question_err"
).
text
(
"ご意見・ご質問が未入力です。"
)
...
...
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