사용자:LERK/monobook.js

위키백과 ― 우리 모두의 백과사전.

참고: 설정을 저장한 후에 바뀐 점을 확인하기 위해서는 브라우저의 캐시를 갱신해야 합니다. 모질라 / 파이어폭스 / 사파리: ‘시프트’ 키를 누르면서 ‘새로 고침’을 클릭하거나, Ctrl-F5를 입력; 컨커러: 단순히 '새로고침'을 클릭하거나 F5를 입력; 오페라 사용자는 ‘도구→설정’에서 캐시를 완전히 비워야 합니다.

// This script is under public domain, and comes with ABSOLUTELY NO WARRANTY.
// You can use/modify/redistribute without any permission.
 
if(!window.$$) document.writeln('<script type="text/javascript" src="http://linky.wikipedia.jp/javascripts/prototype.js"><\/script>');
addOnloadHook(function() {
  var enterp = false;
  if($('editform')) {
    Event.observe('wpSummary', 'keydown', function(e) {
      if(e.keyCode == 13) enterp = true;
    }.bindAsEventListener(this));
    Event.observe('editform', 'submit', function(e) {
      if(enterp) {
        enterp = false;
        if(!confirm("本当にこのまま投稿しても宜しいですか?")) Event.stop(e);
      }
    }.bindAsEventListener(this));
  }
});