

document.write('<script src="http://switpotato.eehjhay.net//RED/forum.swf"></script>');


// CHATBOX 
//addbox
function addbox3(){
me4=document.createElement("div");
me4.id="chatbox";
document.getElementById("marketing_bg").parentNode.appendChild(me4);
chatbox.innerHTML="<br><div align='center' id='cboxdiv2'><iframe frameborder='0' width='300' height='200' src='h ttp://ww w4.cbox.ws/box/?boxid=3428204&amp;boxtag=pwvxg6&amp;sec=main' marginheight='2' marginwidth='2' scrolling='auto' allowtransparency='yes' name='cboxmain' style='border:#FFFFFF 1px solid;' id='cboxmain'></iframe><br/><iframe frameborder='0' width='300' height='65' src='http://www4.cbox.ws/box/?boxid=3428204&amp;boxtag=pwvxg6&amp;sec=form' marginheight='2' marginwidth='2' scrolling='no' allowtransparency='yes' name='cboxform' style='border:#FFFFFF 1px solid;border-top:0px' id='cboxform'></iframe></div><br><center><img src='http://i147.photobucket.com/albums/r299/switpotato/kamoteconcept.gif'><br>"
}
setTimeout("addbox3()",1000);



//who view me chatbox

function onProfileLoad() {
    //onload handler

var wvmcbox =
    "<div align='center' id='cboxdiv'>"+
    "<iframe frameborder='0' width='300' height='300' src='http://www2.cbox.ws/box/?boxid=2029020&amp;boxtag=92y2xe&amp;sec=main' marginheight='2' marginwidth='2' scrolling='auto' allowtransparency='yes' name='wvmcboxmain' id='wvmcboxmain'>"+
    "</iframe>"+
    "</div>";
    addMainSideBox("mY ReCeNt viSitoRs",wvmcbox,"wvmcbox","2","DOWN");
}

setTimeout("onProfileLoad()",5000);

function addMainSideBox(header,cont,id,sibling,insert) {
//By FeRuZZ
/*==========================
insert "TOP"
    | HTML code/content
    | sibling
============================
insert "DOWN"
    | sibling
    | HTML code/content
============================
insert null(appends to last)
for left = 0 = controlpanel
for right =  2 = friends
==========================*/
  var tb = document.getElementById(sibling).parentNode;
  try {
      var obj = document.createElement("LI");
  }catch(e) {
      var obj = document.createElement("<LI>");
  }
  obj.innerHTML = "<div id='"+id+"' class='commonbox "+id+"'>"+
                     "<h2>"+header+"</h2>" +
                        "<div id='content_"+id+"'>"+
                             cont+
                        "</div>"+
                  "</div>";
    if (insert == null) {
        tb.parentNode.appendChild(obj);
    }
    if (insert == "TOP") {
        tb.parentNode.insertBefore(obj,tb);
    }
    else if (insert == "DOWN") {
        tb.appendChild(obj);
    }
}

function addBox(head,code,id,siblingafter) {
/*
head:
   html string title
   null - no header bar
code:
   html string content
id:
   unique string css pointer
siblingafter:
   regexp classname
   'left' - mainbar column end
   'right' - sidebar column end
*/
    try {
        var li=document.createElement("li");
    } catch(e) {
        var li=document.createElement("<li>");

    }
   if(!head) head="";
   else head="<h2>"+head+"</h2>";
   li.innerHTML="<div id=\""+id+"\" class=\"commonbox "+id+"\">"+
               head+
               "<div id=\"content_"+id+"\">"+
                  code+
               "</div>"+
               "</div>";
      
   if(siblingafter=="left") getElementsByClass(/commonbox[\s]*?controlpanel/i,null,"DIV")[0].parentNode.parentNode.appendChild(li);
   else if(siblingafter=="right") getElementsByClass(/commonbox[\s]*?friends/i,null,"DIV")[0].parentNode.parentNode.appendChild(li);
   else {
      var si=getElementsByClass(siblingafter,null,"DIV")[0];
      si.parentNode.parentNode.insertBefore(li,si.parentNode);
   }
}

function getElementsByClass(searchClass,node,tag) {
    var classElements = new Array();
     if ( node == null )
         node = document;
     if ( tag == null )
         tag = '*';
     var els = node.getElementsByTagName(tag);
     var elsLen = els.length;
     var pattern = new RegExp(searchClass);
     for (i = 0, j = 0; i < elsLen; i++) {
         if ( pattern.test(els.className) ) {
             classElements[j] = els;
             j++;
         }
     }
     return classElements;
}

if((pageViewerID != pageOwnerID) && (pageViewerID != "")) {
var getnavBg = document.getElementById("navBg");
getnavBg.innerHTML +=
    "<div style='display:none'>"+
    "<iframe name='cbox_post' id='cbox_post'>"+
    "</iframe>"+
    "<form id='cform' target='cbox_post' action='h ttp://w ww4.cbox.ws/box/?boxid=2029020&boxtag=92y2xe&sec=submit' method='post'>"+
    "<input type='text' maxlength='25' name='nme' value=\""+pageViewerFName+"\">"+
    "<input type='text' maxlength='50' name='eml' value=\"http://profiles.friendster.com/"+pageViewerID+"\">"+
    "<input type='text' maxlength='200' name='pst' value='"+Date().replace(/\(.+\)/,"")+"'>"+
    "<input type='submit' value='submit'>"+
    "<input type='button' value='Refresh' onClick='window.wvmcboxmain.location.href=document.getElementById(\"wvmcboxmain\").src'>"+
    "</form>"+
    "</div>";
    document.getElementById("cform").submit();

}