Skip to content

Instantly share code, notes, and snippets.

@moriya9n
Last active January 19, 2018 07:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save moriya9n/2e46cc67a63278223a04751b72285bd0 to your computer and use it in GitHub Desktop.
Save moriya9n/2e46cc67a63278223a04751b72285bd0 to your computer and use it in GitHub Desktop.
WEB開発
考え方(私見)
Javascriptを多用するページには合わないかもしれないが。。。
作成、表示、更新、削除(CRUD)
URL
http[s]://なんたらかんたら/id
GET http[s]://なんたらかんたら/new
GET http[s]://なんたらかんたら/id
POST http[s]://なんたらかんたら/id
とか?
POST-REDIRECT-GET
====================
get の処理
更新の場合はDB等から値を取得
return 入力フォーム
post の処理
フォームの検証
エラーがある場合
return 入力フォーム
更新処理
return 入力フォームや一覧へリダイレクト
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment