/***********************************************************************************************************
 * net.pictureofthe.javascript.PictureOfTheClass
 * Location: http://www.pictureofthe.net/library/net/pictureofthe/javascript/PictureOfTheClass.js
 * Version Location: http://www.pictureofthe.net/library/net/pictureofthe/javascript/siewpage/builds/2008071800/PictureOfTheClass.js
 * Index Version Location: http://www.pictureofthe.net/library/net/pictureofthe/javascript/pictureofthe/builds/2008071800/index.html
 * © pictureofthe.com (http://www.pictureofthe.com/)
***********************************************************************************************************/

if (typeof net == "undefined") {net = {};};
if (typeof net.pictureofthe == "undefined") {net.pictureofthe = {};};
if (typeof net.pictureofthe.javascript == "undefined") {net.pictureofthe.javascript = {};};

if (typeof net.pictureofthe.javascript.PictureOfTheClass == "undefined") {
 net.pictureofthe.javascript.PictureOfTheClass = function() {};
 net.pictureofthe.javascript.PictureOfTheClass.prototype = new com.oclib.javascript.lang.Root();  

 net.pictureofthe.javascript.PictureOfTheClass.prototype.classCreated = "2008071800"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classCreator = "http://www.pictureofthe.net/"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classIndexLocation = "http://www.pictureofthe.net/library/net/pictureofthe/"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classLocation = "http://www.pictureofthe.net/library/net/pictureofthe/javascript/PictureOfTheClass.js"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.className = "PictureOfTheClass"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classNamespace = "net.pictureofthe.javascript.PictureOfTheClass"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classVersion = "2008071800"; 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classVersionIndexLocation = "http://www.pictureofthe.net/library/net/pictureofthe/javascript/pictureofthe/builds/2008071800/index.html";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.classVersionLocation = "http://www.pictureofthe.net/library/net/pictureofthe/javascript/pictureofthe/builds/2008071800/PictureOfTheClass.js";  

 net.pictureofthe.javascript.PictureOfTheClass.prototype.dom = null;  
  net.pictureofthe.javascript.PictureOfTheClass.prototype.getDom = function () {return this.dom;};
  net.pictureofthe.javascript.PictureOfTheClass.prototype.setDom = function (dom) {this.dom = dom;};
 net.pictureofthe.javascript.PictureOfTheClass.prototype.events = null;   
  net.pictureofthe.javascript.PictureOfTheClass.prototype.getEvents = function () {return this.events;};
  net.pictureofthe.javascript.PictureOfTheClass.prototype.setEvents = function (events) {this.events = events;};
  
 net.pictureofthe.javascript.PictureOfTheClass.prototype.a = "";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.actionType = "passive";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.activeAdd = 1;
 net.pictureofthe.javascript.PictureOfTheClass.prototype.adult = "";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.errorcode = "";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.previousIid = "";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.iid = "";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.li = "";
 net.pictureofthe.javascript.PictureOfTheClass.prototype.urlUploadWeb = "/cgi-bin/library/net/pictureofthe/cpp/uploadweb/2008071800/uploadweb";   
  net.pictureofthe.javascript.PictureOfTheClass.prototype.getUrlUploadWeb = function () {return this.urlUploadWeb;};
  net.pictureofthe.javascript.PictureOfTheClass.prototype.setUrlUploadWeb = function (urlUploadWeb) {this.urlUploadWeb = urlUploadWeb;};
 net.pictureofthe.javascript.PictureOfTheClass.prototype.urlVote = "/cgi-bin/library/net/pictureofthe/cpp/vote/2008071800/vote";   
  net.pictureofthe.javascript.PictureOfTheClass.prototype.getVote = function () {return this.urlUploadWeb;};
  net.pictureofthe.javascript.PictureOfTheClass.prototype.setVote = function (urlUploadWeb) {this.urlUploadWeb = urlUploadWeb;};
 net.pictureofthe.javascript.PictureOfTheClass.prototype.voteStep = 1;   

 net.pictureofthe.javascript.PictureOfTheClass.prototype.init = function() {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.init is runing...");};
  this.a = this.dom.getTextContent("a");
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb this.a:"+this.a);};
  this.actionType = this.dom.getTextContent("actiontype");
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb this.actionType:"+this.actionType);};
  this.adult = this.dom.getTextContent("isadult");
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb this.adult:"+this.adult);};
  this.iid = this.dom.getTextContent("iid");
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb this.iid:"+this.iid);};
  this.li = this.dom.getTextContent("li");
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb this.li:"+this.li);};
  var the = this;
  this.events.addEventListener("adultText", "click", function() {if(document.getElementById("adult").checked==true) {document.getElementById("adult").checked=false;} else {document.getElementById("adult").checked=true;};}, false);
  this.events.addEventListener("broken", "click", function() {
   if(document.getElementById("broken")) {
    document.getElementById("proper").checked=false; 
	if(document.getElementById("like")){
		document.getElementById("dontlike").checked=false; 
		document.getElementById("like").checked=false; 
		document.getElementById("dontopinion").checked=true;
    };
   };
  }, false);
  this.events.addEventListener("brokenText", "click", function() {
   if(document.getElementById("broken").checked==true) {document.getElementById("broken").checked=false;}else{document.getElementById("broken").checked=true;};
   if(document.getElementById("broken")) {
    document.getElementById("proper").checked=false; 
	if(document.getElementById("like")){
		document.getElementById("dontlike").checked=false; 
		document.getElementById("like").checked=false; 
		document.getElementById("dontopinion").checked=true;
	};
   };
  }, false);
  this.events.addEventListener("dontlike", "click", function() {if(document.getElementById("dontlike")) {document.getElementById("dontlike").checked=true; document.getElementById("like").checked=false; document.getElementById("dontopinion").checked=false;};}, false);
  this.events.addEventListener("dontlikeText", "click", function() {if(document.getElementById("dontlike")) {document.getElementById("dontlike").checked=true; document.getElementById("like").checked=false; document.getElementById("dontopinion").checked=false;};}, false);
  this.events.addEventListener("dontopinion", "click", function() {if(document.getElementById("dontopinion")) {document.getElementById("dontopinion").checked=true; document.getElementById("like").checked=false; document.getElementById("dontlike").checked=false;};}, false);
  this.events.addEventListener("dontopinionText", "click", function() {if(document.getElementById("dontopinion")) {document.getElementById("dontopinion").checked=true; document.getElementById("like").checked=false; document.getElementById("dontlike").checked=false;};}, false);
  this.events.addEventListener("q", "keypress", function(e) {if(e.keyCode != 13 && e.which != 13){return -1;}; the.search(e);}, false);
  this.events.addEventListener("like", "click", function() {if(document.getElementById("like")) {document.getElementById("like").checked=true; document.getElementById("dontlike").checked=false; document.getElementById("dontopinion").checked=false;};}, false);
  this.events.addEventListener("likeText", "click", function() {if(document.getElementById("like")) {document.getElementById("like").checked=true; document.getElementById("dontlike").checked=false; document.getElementById("dontopinion").checked=false;};}, false);
  this.events.addEventListener("nextButton", "click", function(e) {the.vote(e);}, false);
  this.events.addEventListener("proper", "click", function() {document.getElementById("proper").checked=true; document.getElementById("broken").checked=false; document.getElementById("spam").checked=false;}, false);
  this.events.addEventListener("properText", "click", function() {document.getElementById("proper").checked=true; document.getElementById("broken").checked=false; document.getElementById("spam").checked=false;}, false);
  this.events.addEventListener("searchButton", "click", function(e) {the.search(e);}, false);
  this.events.addEventListener("spam", "click", function() {if(document.getElementById("spam")) {document.getElementById("proper").checked=false; if(document.getElementById("like")){document.getElementById("dontlike").checked=true; document.getElementById("like").checked=false; document.getElementById("dontopinion").checked=false;};};}, false);
  this.events.addEventListener("spamText", "click", function() {if(document.getElementById("spam").checked==true) {document.getElementById("spam").checked=false;}else{document.getElementById("spam").checked=true;};if(document.getElementById("spam")) {document.getElementById("proper").checked=false; if(document.getElementById("like")){document.getElementById("dontlike").checked=true; document.getElementById("like").checked=false; document.getElementById("dontopinion").checked=false;};};}, false);
  this.events.addEventListener("tags", "keypress", function(e) {if(e.keyCode != 13 && e.which != 13){return -1;};the.vote(e);}, false);
  this.events.addEventListener("uploadWebButton", "click", function(e) {the.uploadWeb(e);}, false);
  this.events.addEventListener("voteButton", "click", function(e) {the.vote(e);}, false);
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.search = function(loader) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.search is runing...");};
  var newUri = "http://www.pictureofthe.net/image/a/"+this.a+"/li/"+this.li+"/pt/ss/pn/"+encodeURIComponent(document.getElementById("q").value)+"/";
  window.location = newUri;
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb = function(e) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb is runing...");}; 
  this.dom.doHidden("errorValidWebSourceURI");
  this.dom.doHidden("errorUploadError");
  this.dom.doHidden("errorUploadMessage");
  this.dom.doHidden(this.errorcode);
  this.dom.doHidden("successUpload");
  this.dom.doHidden("successMessageHidden");
  var uploadWebSourceURI = document.getElementById("uploadWebSourceURI").value;
  if(uploadWebSourceURI == "") {
   this.dom.doVisible("errorValidWebSourceURI");
   return;
  };
  this.dom.doHidden("uploadWebButton");
  var uploadWebSourcePageURI = document.getElementById("uploadWebSourcePageURI").value;
  var uploadWebTags = document.getElementById("uploadWebTags").value;
  if(this.mustDebug()) {this.getLog().println("uploadWebTags:"+uploadWebTags);};
  var uploadWebAuthorName = document.getElementById("uploadWebAuthorName").value;
  var uploadWebAuthorEmail = document.getElementById("uploadWebAuthorEmail").value;
  var uploadWebAuthorHomePageURI = document.getElementById("uploadWebAuthorHomePageURI").value;
  var uploadWebAuthorWikiURI = document.getElementById("uploadWebAuthorWikiURI").value;
  var uploadWebSaved = document.getElementById("uploadWebSaved").checked;
  var uploadWebAult = document.getElementById("uploadWebAult").checked;
  var data = "li="+this.li
             +"&a="+this.a
             +"&adult="+this.adult
             +"&uploadWebSourceURI="+encodeURIComponent(uploadWebSourceURI)
             +"&uploadWebSourcePageURI="+encodeURIComponent(uploadWebSourcePageURI)
             +"&uploadWebTags="+encodeURIComponent(uploadWebTags)
             +"&uploadWebAuthorName="+encodeURIComponent(uploadWebAuthorName)
             +"&uploadWebAuthorEmail="+encodeURIComponent(uploadWebAuthorEmail)
             +"&uploadWebAuthorHomePageURI="+encodeURIComponent(uploadWebAuthorHomePageURI)
             +"&uploadWebAuthorWikiURI="+encodeURIComponent(uploadWebAuthorWikiURI)
             +"&uploadWebSaved="+uploadWebSaved
             +"&uploadWebAult="+uploadWebAult;              
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWeb data:"+data);};
  var loader = new com.oclib.javascript.util.Loader();
  loader.setDebugging(this.getDebugging()); loader.setLog(this.getLog()); loader.setTracing(this.getTracing());
  loader.setMethod("POST");
  var the = this;
  loader.setDoIfError(function() {the.uploadWebError(loader);});
  loader.setDoIfSuccess(function() {the.uploadWebSuccess(loader);});
  loader.makeRequest(this.method, this.urlUploadWeb, data); 
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWebError = function(loader) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWebError is runing...");};
  this.dom.doVisible("errorUploadError");
  this.dom.doVisible("uploadWebButton");
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWebSuccess = function(loader) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.uploadWebSuccess is runing...");}; 
  var responseXML = loader.xml;  
  if(responseXML.getElementsByTagName("status") && responseXML.getElementsByTagName("status").item(0) && responseXML.getElementsByTagName("status").item(0).firstChild) {
   var status = responseXML.getElementsByTagName("status").item(0).firstChild.data;
   if(this.mustDebug()) {this.getLog().println("Rating.createRatingSuccess: status="+status);};
   if(status == "success") {
    if(this.mustTrace()) {this.getLog().println("com.upmeter.javascript.Vote.addSuccess: success...");};
    this.dom.doVisible("successMessageHidden");
    this.dom.doVisible("successUpload");
    this.dom.doVisible("uploadWebButton");
    return;
   } else {
    if(this.mustTrace()) {this.getLog().println("com.upmeter.javascript.Vote.addSuccess: error...");};
    if(responseXML.getElementsByTagName("errorcode") && responseXML.getElementsByTagName("errorcode").item(0) && responseXML.getElementsByTagName("errorcode").item(0).firstChild) {
     this.errorcode = responseXML.getElementsByTagName("errorcode").item(0).firstChild.data;
     this.dom.doVisible("errorUploadMessage");
     this.dom.doVisible(this.errorcode);
    };
   };
  };
  this.uploadWebError(loader);
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.vote = function(e) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.vote is runing...");}; 
  var voteLike = 0;
  var voteDontlike = 0;
  var voteDontopinion = 0;
  var voteAdult = document.getElementById("adult").checked ? 1 : 0;
  var voteBroken = document.getElementById("broken").checked ? 1 : 0;
  var voteSpam = document.getElementById("spam").checked ? 1 : 0;
  var tags = document.getElementById("tags").value;
  if(this.actionType=="active") {
   voteLike = document.getElementById("like").checked ? 1 : 0;
   voteDontlike = document.getElementById("dontlike").checked ? 1 : 0;
   voteDontopinion = document.getElementById("dontopinion").checked ? 1 : 0;
   if(voteLike==0 && voteDontlike==0 && voteDontopinion==0) {return;};
  } else if(voteAdult==0 && voteBroken==0 && voteSpam==0 && tags=="") {
   return;
  };
  this.dom.doHidden("nextButton");
  this.voteStep++;
  var data = "li="+this.li
             +"&a="+this.a
             +"&actiontype="+this.actionType
             +"&adult="+this.adult
             +"&iid="+this.iid
             +"&step="+this.voteStep
             +"&adult="+voteAdult
             +"&broken="+voteBroken
             +"&spam="+voteSpam
             +"&like="+voteLike
             +"&dontlike="+voteDontlike
             +"&dontopinion="+voteDontopinion
             +"&tags="+encodeURIComponent(tags);              
  if(this.mustDebug()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.vote data:"+data);};
  var loader = new com.oclib.javascript.util.Loader();
  loader.setDebugging(this.getDebugging()); loader.setLog(this.getLog()); loader.setTracing(this.getTracing());
  loader.setMethod("POST");
  var the = this;
  loader.setDoIfError(function() {the.voteError(loader);});
  loader.setDoIfSuccess(function() {the.voteSuccess(loader);});
  loader.makeRequest(this.method, this.urlVote, data); 
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.voteError = function(loader) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.voteError is runing...");};
  this.dom.doVisible("nextButton");
 };
 
 net.pictureofthe.javascript.PictureOfTheClass.prototype.voteSuccess = function(loader) {
  if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.voteSuccess is runing...");}; 
  var responseXML = loader.xml;  
  //if(this.dom.getTextContent("pt")=="picture") {return;};
  if(this.actionType=="passive") {this.dom.doHidden("actionBlock");return;};
  if(responseXML.getElementsByTagName("status") && responseXML.getElementsByTagName("status").item(0) && responseXML.getElementsByTagName("status").item(0).firstChild) {
   var status = responseXML.getElementsByTagName("status").item(0).firstChild.data;
   if(this.mustDebug()) {this.getLog().println("Rating.createRatingSuccess: status="+status);};
   if(status == "success") {
    if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.voteSuccess: success...");};
    //var img = document.getElementById("mainImage");
    this.dom.doHidden("imageDiv");
    this.dom.doHidden("descriptionBlock");
    this.dom.doHidden("imgDiv");
    var src, width, height;
    if(responseXML.getElementsByTagName("src") && responseXML.getElementsByTagName("src").item(0) && responseXML.getElementsByTagName("src").item(0).firstChild) {
     src = responseXML.getElementsByTagName("src").item(0).firstChild.data;
    };
    if(responseXML.getElementsByTagName("width") && responseXML.getElementsByTagName("width").item(0) && responseXML.getElementsByTagName("width").item(0).firstChild) {
     width = responseXML.getElementsByTagName("width").item(0).firstChild.data;
    };
    if(responseXML.getElementsByTagName("height") && responseXML.getElementsByTagName("height").item(0) && responseXML.getElementsByTagName("height").item(0).firstChild) {
     height = responseXML.getElementsByTagName("height").item(0).firstChild.data;
    };
    var img = document.createElement("img");
    img.src = src;
    img.id = "mainImage";
    if(width != "auto" && height!="auto") {
     img.width = width;
     img.height = height;
    };
    this.dom.changeChilds("imgDiv", img);
    if(responseXML.getElementsByTagName("permalink") && responseXML.getElementsByTagName("permalink").item(0) && responseXML.getElementsByTagName("permalink").item(0).firstChild) {
     document.getElementById("permalink").href = responseXML.getElementsByTagName("permalink").item(0).firstChild.data;
    };
    if(responseXML.getElementsByTagName("newIid") && responseXML.getElementsByTagName("newIid").item(0) && responseXML.getElementsByTagName("newIid").item(0).firstChild) {
     this.iid = responseXML.getElementsByTagName("newIid").item(0).firstChild.data;
     this.dom.changeTextContent("iid", this.iid);
    };
    if(responseXML.getElementsByTagName("authorName") && responseXML.getElementsByTagName("authorName").item(0) && responseXML.getElementsByTagName("authorName").item(0).firstChild) {
     var authorName = responseXML.getElementsByTagName("authorName").item(0).firstChild.data;
     this.dom.changeTextContent("authorSpan", authorName);
     this.dom.doVisible("authorBlock");
     if(responseXML.getElementsByTagName("authorHomeURI") && responseXML.getElementsByTagName("authorHomeURI").item(0) && responseXML.getElementsByTagName("authorHomeURI").item(0).firstChild) {
      document.getElementById("authorHomeURI").href = responseXML.getElementsByTagName("authorHomeURI").item(0).firstChild.data;
      this.dom.changeTextContent("authorHome", authorName);
      this.dom.doVisible("authorHomeBlockLink");
     } else {
      this.dom.doHidden("authorHomeBlockLink");
     };
     if(responseXML.getElementsByTagName("authorWikiURI") && responseXML.getElementsByTagName("authorWikiURI").item(0) && responseXML.getElementsByTagName("authorWikiURI").item(0).firstChild) {
      document.getElementById("authorWikiURI").href = responseXML.getElementsByTagName("authorWikiURI").item(0).firstChild.data;
      this.dom.changeTextContent("authorWiki", authorName);
      this.dom.doVisible("authorWikiBlockLink");
     } else {
      this.dom.doHidden("authorWikiBlockLink");
     };
    } else {
     this.dom.doHidden("authorBlock");
     this.dom.doHidden("authorHomeBlockLink");
     this.dom.doHidden("authorWikiBlockLink");
    };
    if(responseXML.getElementsByTagName("source") && responseXML.getElementsByTagName("source").item(0) && responseXML.getElementsByTagName("source").item(0).firstChild) {
     document.getElementById("source").href = responseXML.getElementsByTagName("source").item(0).firstChild.data;
    };
    if(responseXML.getElementsByTagName("sourcePageURI") && responseXML.getElementsByTagName("sourcePageURI").item(0) && responseXML.getElementsByTagName("sourcePageURI").item(0).firstChild) {
     document.getElementById("sourcePageURI").href = responseXML.getElementsByTagName("sourcePageURI").item(0).firstChild.data;
     this.dom.doVisible("sourcePageBlockLink");
    } else {
     this.dom.doHidden("sourcePageBlockLink");
    };
    if(responseXML.getElementsByTagName("savedCopy") && responseXML.getElementsByTagName("savedCopy").item(0) && responseXML.getElementsByTagName("savedCopy").item(0).firstChild) {
     document.getElementById("savedCopy").href = responseXML.getElementsByTagName("savedCopy").item(0).firstChild.data;
    };
    if(responseXML.getElementsByTagName("pictureAdult") && responseXML.getElementsByTagName("pictureAdult").item(0) && responseXML.getElementsByTagName("pictureAdult").item(0).firstChild) {
     var pictureAdult = responseXML.getElementsByTagName("pictureAdult").item(0).firstChild.data;
     if(this.mustDebug()) {this.getLog().println("Rating.createRatingSuccess: pictureAdult="+pictureAdult);};
     if(pictureAdult=="a") {
      document.getElementById("adult").checked=true;
     } else {
      document.getElementById("adult").checked=false;
     };
    };
    var i = 0;
    var tags = document.createElement("span");
    var tagslinks = document.createElement("span");
    while(responseXML.getElementsByTagName("tag").item(i)) {
     if(responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("name")
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("name").item(0)
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("name").item(0).firstChild
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("size")
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("size").item(0)
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("size").item(0).firstChild
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("uri")
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("uri").item(0)
        && responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("uri").item(0).firstChild) {
      var name = responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("name").item(0).firstChild.data;      
      var size = responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("size").item(0).firstChild.data;
      size = "font-size:"+size+"px";      
      var uri = responseXML.getElementsByTagName("tag").item(i).getElementsByTagName("uri").item(0).firstChild.data;      
      
      var tagSpan = document.createElement("span");
      tagSpan.setAttribute("style", size);
      tagSpan.appendChild(document.createTextNode(name)); 
      tags.appendChild(tagSpan); 
      var nbspSpanTags = document.createElement("span");
      nbspSpanTags.appendChild(document.createTextNode(" "));
      tags.appendChild(nbspSpanTags); 
      
      var tagSpanLink = document.createElement("span");
      tagSpanLink.setAttribute("style", size);
      var link = document.createElement("a");
      link.appendChild(document.createTextNode(name)); 
      link.setAttribute("href", uri);
      tagSpanLink.appendChild(link);          
      tagslinks.appendChild(tagSpanLink); 
      var nbspSpanTagsLinks = document.createElement("span");
      nbspSpanTagsLinks.appendChild(document.createTextNode(" "));   
      tagslinks.appendChild(nbspSpanTagsLinks);
      
      i++;
     };
    };
    this.dom.changeChilds("similarTags", tags);
    this.dom.changeChilds("similarUrlTags", tagslinks);
    
    this.dom.doVisible("similarTags");
    this.dom.doVisible("similarUrlTags");
    this.dom.doVisible("descriptionBlock");
    this.dom.doVisible("imgDiv");
    this.dom.doVisible("imageDiv");
    document.getElementById("proper").checked=true;
    document.getElementById("broken").checked=false;
    //document.getElementById("repeat").checked=false;
    document.getElementById("spam").checked=false;
    document.getElementById("like").checked=false;
    document.getElementById("dontlike").checked=false;
    document.getElementById("dontopinion").checked=false;
    document.getElementById("tags").value="";
    this.dom.doVisible("nextButton");
    return;
   } else {
    if(this.mustTrace()) {this.getLog().println("net.pictureofthe.javascript.PictureOfTheClass.prototype.voteSuccess: error...");};
   };
  };
  this.voteError(loader);
 };
 
};
