// ==UserScript==
// @name livejournal.com - Forms fix
// @author Michael Xeningem Gray 
// @namespace http://userjs.org/ 
// @version 2.0
// @description  Make comment forms on LiveJournal.com work properly in
//			Opera.
// @ujs:category site: fixes
// @ujs:published 2006-01-07 23:04
// @ujs:modified 2006-01-07 22:06
// @ujs:documentation http://userjs.org/scripts/site/fixes/livejournal-com-forms-fix 
// @ujs:download http://userjs.org/scripts/download/site/fixes/livejournal-com-forms-fix.js
// ==/UserScript==


/* 
 * This script is granted to the public domain.
 */

window.addEventListener('load',function(e) {
if (document.getElementById("qrform"))
  {// For Opera 9 tp1 and newer
  var qe = document.getElementById("qrdiv");
  qe.innerHTML=qe.innerHTML;
  }	 
 if (!document.getElementById("qrform")&&document.getElementById("qrformdiv")) {
	// For Opera 8.50 and older
	var qe = document.getElementById("qrformdiv");
	var fe = document.createElement("form");      
      if (fe) {
        fe.id = "qrform";
        fe.name="qrform";
        fe.method="POST";
        fe.action="http://www.livejournal.com/talkpost_do.bml";         
        fe.innerHTML =qe.innerHTML;
        qe.innerHTML = "";
        qe.appendChild(fe);
      }
    }
},false);
