Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

フロントエンド - JavaScript/jQuery - 条件分岐 #51

Open
fr-sasaki opened this issue Aug 8, 2014 · 0 comments
Open

フロントエンド - JavaScript/jQuery - 条件分岐 #51

fr-sasaki opened this issue Aug 8, 2014 · 0 comments
Labels

Comments

@fr-sasaki
Copy link
Member

■目的

jQueryでの条件分岐の書き方について学びます。

■課題

以下の要素をHTMLファイルの<article>タグ内に追加して下さい。

<form action="#" method="get">
  <input type="text" name="val"><input type="submit" value="送信">
</form>

送信を押したら、テキストフィールドの値によってアラートを表示する条件分岐を実装して下さい。

  • 入力した値が空だったら入力して下さいとアラート表示
  • 入力した値が数字だったら数字ですとアラート表示
  • 入力した値が上記以外だったら数字以外ですとアラート表示
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant