Create a gist now

Instantly share code, notes, and snippets.

JavaScriptで、ブラウザデフォルトの確認ダイアログを使う方法 ref:
function confirmPugyaa(msg,target){
if(window.confirm(target + "さんに" + msg + "します。\nよろしいですか?\n")){
return true;
return false;
<form action="[% path('/hoge/?i=request&target_id=' _ %]" method="POST" onSubmit="return confirmPugyaa('m9(^Д^)プギャー', '[% u.nickname %]')">
<input type="hidden" name="target_user_id" value="[% u.user_id %]" />
<div class="info">
<input type="submit" value="申請" class="send" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment