  document.addEventListener("message", (function (ev)
{
  document.addEventListener("load", (function ()
{if(ev.uri.match(/\/sendmsg\.html$/)){
stopposting=null;
opera.postError(ev.data);
if(ev.data.toLowerCase()!='dom'){
if(ev.data.toLowerCase()!='resources'){
  ev.source.document.postMessage(escape(document.documentElement.outerHTML));}
  else{
  var baselink = location;
var relink = "http://" + baselink.hostname;
var hmmlink = baselink.href.split("/");
 re=/^(.*)\/[^\/]*$/;
 re.exec(baselink.href);
 var newlink=RegExp.$1+'/';
  ev.source.document.postMessage(relink+','+newlink+','+escape(document.documentElement.outerHTML))}
  self.close();}
  else{
  document.onmousemove=function(e){if(!stopposting){var hmm='';var ty=e.target;hmm='TagName:'+ty.nodeName+'\n';
  for(i=0;i<ty.attributes.length;i++) {
		if(ty.attributes[i].specified) {
			if(ty.attributes[i].value) {
hmm+=ty.attributes[i].name + " : " + ty.attributes[i].value+'\n';
			}}}
  ev.source.document.postMessage(hmm);}}
  document.onkeypress=function(e){if(e.ctrlKey && !stopposting){stopposting=true} else{stopposting=null;}}
  }
}}
), false);
}
), false);
