[b]Credits goes to all Friendstertalk Members who create these wonderful scripts[/b]
[quote][color=red][b]PERHATIAN :[/b][/color] Bagi para FTI'ers yg linker JS dan CSS extensionnya masih berjalan, jangan edit profile dalam FS kalian secara langsung OK. Kalau pun tangan kalian gatal utk utak-atik scriptnya, edit dari source scriptnya langsung (dari accout script hosting kalian)
[/quote]
[quote][color=red][b]UPDATE :[/b][/color]
1. Kombinasi JS dengan WVM versi 3.1 host by Kherminator + script addBox yang sudah diperbaharui.
2. Penempatan WVMCBOX dan No Right Click CBOX.
3. Update CSS Injection.
4. Update Force Log In.
5. Update WVMCBOX versi 2.1.
6. Update No Right Click CBOX versi 2.1.
7. Tutorial Tambahan Yang Berhubungan Dengan WVM.[/quote]
Browser yg aku gunakan adalah [b]IE6[/b], [b]FF 2.0.0.12[/b] dan [b]Opera 9.26[/b]
Mungkin thread ini pernah aku posting dulu banget ketika FS masih menggunakan script addsidebar dan bukan addBox
Mohon maaf buat Moderator kalau thread aku kali ini mungkin bisa dibilang double posting. Thread ini aku posting karena ada beberapa orang FTI'ers yang masih bingung dan sering bertanya tentang bagaimana cara mengkombinasikan variabel JS baik itu sebagai stand alone addbox atau mengkombinasikannya dengan WVM (tracker)
[b]1. Stand alone addBox (membuat tampilan box baru baik itu di kiri/kanan profile FS kalian). Ini berlaku bagi mereka yang tidak menggunakan WVM[/b]
Pertama kita harus menggunakan script addBox dari [b]Marfillaster[/b]. Disini aku sudah buatkan 3 bagian yaitu ; A, B, C. Itu adalah posisi dimana kalian bisa menempatkan semua JS kalian (apabila kalian menggunakan JS lain). Ini dia scriptnya :
[quote][color=blue][b]BAGIAN A[/b][/color]
//onload handler
function onProfileLoad() {
//addboxes here
[color=red][b]BAGIAN B[/b][/color]
}
if (!attachOnLoadHandler(function(){onProfileLoad()})) window.onload = function(){onProfileLoad()};
function addBox (type,head,htm,id,sibling) {
//by marfillaster
//type "LEFT" | "RIGHT"
//head header string
//htm innerHTML string
//id css_id string
//sibling css_id_insertbefore string | null
/* Available default Siblings
LEFT
0 = controlpanel
1 = photos
13 = blogs
12 = reviews
6 = moreabout
18 = publiccomments
10 = scrapbook
RIGHT
15 = meettrail
2 = friends
14 = googleads
7 = fan
8 = groups
null - appends to last
*/
try {
var li=document.createElement("li");
} catch(e) {
var li=document.createElement("<li>");
}
if(type=="LEFT") {
var ul=document.getElementById("0").parentNode.parentNode;
htm="<div class='boxcontent'>"+htm+"</div>";
}
else var ul=document.getElementById("2").parentNode.parentNode;
li.innerHTML="<div id='"+id+"' class='commonbox "+id+"'>"+
"<h2>"+head+"</h2>"+
"<div id='content_"+id+"'>"+
htm+
"</div>"+
"</div>";
if(sibling==null) ul.appendChild(li);
else {
sibling=document.getElementById(sibling).parentNode;
ul.insertBefore(li,sibling);
}
}
[color=green][b]BAGIAN C[/b][/color][/quote]
[b]Bagian A[/b] adalah tempat dimana kalian bisa menempatkan beberapa JS seperti :
JS Injection
CSS Injection (baik itu separate CSS ataupun randomize CSS)
Force Log In
YM Status
Loading Page
Block Viewer Script
Welcome and Goodbye Alert
[b]Bagian B[/b] atau disebut juga onloader/onload handler adalah dimana kalian bisa menempatkan semua variabel JS ataupun variabel addBox kalian seperti :
Marquee variabel
CBOX
More Friends
Flash MP3, Imeem, dst
Slide Photo Gallery
Flash Clock, Flash Slide, Flash Guestbook
Search Box
Navigation Box
[b]Bagian C[/b] adalah dimana kalian bisa menempatkan beberapa JS seperti :
Silent No Right Click
Main Nav Flash
CP Buttons Flash
Main Pic Flash or .gif
Marquee status bar (atas dan bawah)
Customized Header Names
Customized Profile Data
Mini Viewer
Misalnya kita ingin memasukkan beberapa script JS seperti :
1. Force Log In
2. Enter Page (linker JS aku yg sekarang tidak mendukung Enter Page jadi tidak aku gunakan)
3. JS Injection
4. CSS Injection
5. Slide Photo Gallery
6. More Friends
7. Flash MP3
8. CBOX
9. Main Nav Flash
10. Main Pin Flash
11. Marquee Status Bar (atas dan bawah)
12. Mini Viewer (yg aku gunakan disini adalah mini viewer di atas kolom friends)
Perlu diperhatikan, ada beberapa script yang bisa dimasukkan ke bagian A, B atau C. Kita jangan takut mengkombinasikan JS lho karena kalau mau utak-atik script, kita harus berani trial and error alias coba-coba
Contohnya script slide photo gallery :
[quote]if (!attachOnLoadHandler(function(){embed()})) window.onload = function(){embed()};
function embed(){
var slodde = "<embed src=\"http://widget-e7.slide.com/widgets/slideticker.swf\" type=\"application/x-shockwave-flash\" quality=\"high\" scale=\"noscale\" salign=\"l\" wmode=\"transparent\" flashvars=\"cy=fr&il=1&channel=YOUR SLIDE SLIDING CODE NUMBER&site=widget-e7.slide.com\" style=\"width:100%;height:125px\" name=\"flashticker\" align=\"middle\"/><div style=\"width:100%;text-align:center;\"><a href=\"http://www.friendster.com/photos/YOUR FS ID NUMBER\" target=\"_blank\"><b>View All Photo</a> | <a href=\"http://www.friendster.com/friendphotoupload.php?uid=YOUR FS ID NUMBER\" target=\"_blank\">Upload Photo Fo Me</b></a></div>";
document.getElementById('content_1').style.height='100%';
document.getElementById('content_1').style.overflowY='hidden';
document.getElementById('content_1').innerHTML = "<table width='100%'><tr><td align='center'>"+slodde+"</td></tr></table>";
[b]}setTimeout("embed()",10000);[/b][/quote]
Script diatas itu bisa dimasukkan ke bagian A, B atau C. Tapi yang perlu diingat, apabila kita ingin memasukkannya ke bagian B, lihat bagian yang tebal diatas. Bagian tebal itu harus dihapus. Itu berlaku juga buat semua script terutama script marquee yang menggunakan command [b]setTimeout[/b]
Kembali ke point mengkombinasikan beberapa JS tersebut di atas, maka hasil akhirnya adalah seperti ini :
[quote][b]//js injection[/b]
var myjs = document.createElement("script");
myjs.type = "text/javascript";
myjs.src = "URL JS KAMU";
document.getElementsByTagName("head")[0].appendChild(myjs);
[b]//css injection[/b]
var css;
try {
css = document.createElement("link");
}catch(e) {
css = document.createElement("<link>");
}
css.setAttribute("type","text/css");
css.setAttribute("rel","stylesheet");
css.setAttribute("href","URL CSS KAMU");
css.setAttribute("media","screen, print");
document.getElementsByTagName("head")[0].appendChild(css);
[b]//force log in[/b]
if(pageViewerID==""){
alert("YOUR TEXT HERE");
top.location.href="http://www.friendster.com/login.php?next=/user.php?uid=uID FS MU";
}
//onload handler
function onProfileLoad() {
//addboxes here
[b]//slide photo gallery[/b]
var slodde = "<embed src=\"http://widget-e7.slide.com/widgets/slideticker.swf\" type=\"application/x-shockwave-flash\" quality=\"high\" scale=\"noscale\" salign=\"l\" wmode=\"transparent\" flashvars=\"cy=fr&il=1&channel=YOUR SLIDE SLIDING CODE NUMBER&site=widget-e7.slide.com\" style=\"width:100%;height:125px\" name=\"flashticker\" align=\"middle\"/><div style=\"width:100%;text-align:center;\"><a href=\"http://www.friendster.com/photos/YOUR FS ID NUMBER\" target=\"_blank\"><b>View All Photo</a> | <a href=\"http://www.friendster.com/friendphotoupload.php?uid=YOUR FS ID NUMBER\" target=\"_blank\">Upload Photo Fo Me</b></a></div>";
document.getElementById('content_1').style.height='100%';
document.getElementById('content_1').style.overflowY='hidden';
document.getElementById('content_1').innerHTML = "<table width='100%'><tr><td align='center'>"+slodde+"</td></tr></table>";
[b]//more friends[/b]
var kawanku = "<div><div class='boxcontent'><div class='flogrid75'><div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div><br>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div><br>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div><br>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div>"+
"<div class='flogriditem'><div class='ir'><a href='USERID'><img src='PHOTOURL'></a></div><div class='dr'><a href='USERID'>NAME</a></div></div></div></div><br></div></div><div class='viewall'><a href='/friends/YOUROWNUSERID'>VIEW ALL</a></div>";
addBox("RIGHT","MORE FRIENDS",kawanku,"siputbox","7");
[b]//flash mp3[/b]
var mp3 ="<div align='center'><embed allowScriptAccess=\"never\" src=\"URL SWF KAMU\" menu=\"false\" quality=\"high\" width=\"265px\" height=\"270px\" name=\"index\" type=\"application/x-shockwave-flash\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" flashvars=\"playList=URL XML KAMU\" wmode=\"transparent\"/></embed><br /><a href=\"http://www.myspaceprodesigns.com\"></a></div></div>";
addBox("RIGHT",pageOwnerFName+"'s Flash MP3",mp3,"music","7");
[b]//cbox[/b]
var cbox="<div align='center' id='cboxdiv'>"+
"<iframe frameborder='0' width='100%' height='305' src='YOUR CBOX MAIN SRC' marginheight='2' marginwidth='2' scrolling='auto' allowtransparency='yes' name='cboxmain' style='border:#DBE2ED 0px solid;' id='cboxmain'></iframe><br/>"+
"<iframe frameborder='0' width='100%' height='75' src='YOUR CBOX FORM SRC' marginheight='2' marginwidth='2' scrolling='no' allowtransparency='yes' name='cboxform' style='border:#DBE2ED 0px solid;border-top:0px' id='cboxform'></iframe>"+
"</div>";
addBox("RIGHT",pageOwnerFName+"'s Shoutbox",cbox,"cboxbox","7");
}
if (!attachOnLoadHandler(function(){onProfileLoad()})) window.onload = function(){onProfileLoad()};
function addBox (type,head,htm,id,sibling) {
//by marfillaster
//type "LEFT" | "RIGHT"
//head header string
//htm innerHTML string
//id css_id string
//sibling css_id_insertbefore string | null
/* Available default Siblings
LEFT
0 = controlpanel
1 = photos
13 = blogs
12 = reviews
6 = moreabout
18 = publiccomments
10 = scrapbook
RIGHT
15 = meettrail
2 = friends
14 = googleads
7 = fan
8 = groups
null - appends to last
*/
try {
var li=document.createElement("li");
} catch(e) {
var li=document.createElement("<li>");
}
if(type=="LEFT") {
var ul=document.getElementById("0").parentNode.parentNode;
htm="<div class='boxcontent'>"+htm+"</div>";
}
else var ul=document.getElementById("2").parentNode.parentNode;
li.innerHTML="<div id='"+id+"' class='commonbox "+id+"'>"+
"<h2>"+head+"</h2>"+
"<div id='content_"+id+"'>"+
htm+
"</div>"+
"</div>";
if(sibling==null) ul.appendChild(li);
else {
sibling=document.getElementById(sibling).parentNode;
ul.insertBefore(li,sibling);
}
}
[b]//main nav flash[/b]
document.getElementById("mainnav").getElementsByTagName("ul")["treemenu1"].innerHTML=
"<li id='annamainmenu'><div>KODE OBJEK PENGGANTI MENU</div></li>";
[b]//main pic flash[/b]
if (!attachOnLoadHandler(function() { primaryImg();})) window.onload = function() { primaryImg();};
function primaryImg() {
PRIMARYIMAGE.init();
}
if (typeof PRIMARYIMAGE == "undefined") { PRIMARYIMAGE = {}; }
PRIMARYIMAGE = {
HTML: [], sibling: [],
init: function() {
this.HTML = document.createElement("DIV");
this.HTML.innerHTML = "PUT ANY HTML CODE HERE";
this.sibling = this.getModuleByClassName(/imgblock200/i)[0];
this.sibling.parentNode.replaceChild(this.HTML,this.sibling);
},
getModuleByClassName: function(sClass) {
var elm = [];
var els = document.getElementsByTagName("*") || document.all;
for (var j=0,k=els.length;j<k;j++) {
if (new RegExp(sClass).test(els[j].className))elm.push(els[j]);
}
return elm;
}
};
[b]//marquee status bar atas[/b]
<!--//
function tb10_makeArray(n){
this.length = n;
return this.length;
}
tb10_messages = new tb10_makeArray(1);
tb10_messages[0] = "YOUR TEXT HERE";
tb10_rptType = 'infinite';
tb10_rptNbr = 5;
tb10_speed = 100;
tb10_delay = 2000;
var tb10_wiper
var tb10_space="_"
var tb10_currMsg=0;
var tb10_counter=1;
var tb10_index=0
tb10_main()
function tb10_main()
{
document.title=tb10_messages[tb10_currMsg].substring(0,tb10_index)
tb10_index++
if(tb10_index==(tb10_messages[tb10_currMsg].length+4)){setTimeout('tb10_reset_clear()',tb10_delay);}
else{setTimeout('tb10_main()',tb10_speed)}
}
function tb10_reset_clear()
{
tb10_index=0
tb10_wiper=""
for(var a=0;a<tb10_messages[tb10_currMsg].length;a++){tb10_wiper+=tb10_space}
tb10_clearem()
}
function tb10_clearem()
{
document.title=tb10_wiper.substring(0,tb10_index) + "->" + tb10_messages[tb10_currMsg].substring(tb10_index+2,tb10_messages[tb10_currMsg].length)
tb10_index++
if(tb10_index==(tb10_messages[tb10_currMsg].length+4)){
if (tb10_currMsg == tb10_messages.length-1){
if ((tb10_rptType == 'finite') && (tb10_counter==tb10_rptNbr)){
document.title="";
return;
}
tb10_counter++;
tb10_currMsg = 0;
}
else tb10_currMsg++;
tb10_index=0
tb10_main()
}
else{setTimeout('tb10_clearem()',250)}
}
// -->
[b]//marquee status bar bawah[/b]
<!--//
function doClock() {
window.setTimeout( "doClock()", 1000 );
today = new Date();
self.status = today.toString();
}
doClock()
// -->
[b]//mini viewer[/b]
if ( ! attachOnLoadHandler(function (){mainVpic();})) window.onload = function (){ mainVpic();};
function mainVpic() {
if(pageViewerID!="") SPAWNPIC.init();
}
function getRegExpDetails(mypic) {
if(!mypic) {
SPAWNPIC.getCode();
return;
}else {
for (val in SPAWNPIC.info) {
try {
SPAWNPIC.info[val] = new RegExp(SPAWNPIC.regexp[val]).exec(mypic)[1].replace(/(\d)+?/i,"$1");
}catch(e) {
SPAWNPIC.info[val] = "";
}
}
if(pageViewerID != "") SPAWNPIC.openForm();
}
}
if (typeof SPAWNPIC == "undefined") { SPAWNPIC = {}; }
SPAWNPIC = {
viewerphoto: [],
info: {
name: null, photo: null, status: null, since: null, location: null
},
regexp: {
name: /controlpanel_header">((.|\s)+?)<a\s*name="controlpanel/,
photo: /imgblock200"><a.*?>((.|\s)+?)<\/a><\/div>/,
status: /data">((.|\s)+?)<\/span><\/li>/,
since: /Since\:\s*<\/span>((.|\s)+?)<\/li>/,
location: /Location\:\s*<\/span>((.|\s)+?)<\/li>/
},
content: {
id: "viewerphoto",
sibling: "15"
},
init: function() {
this.ajaxRequest("viewerPic","/user.php?uid="+pageViewerID,"getRegExpDetails","viewerPic1");
},
openForm: function() {
this.viewerphoto = "<div class='fitem1wrapper'>"+
"<table class'fitem1table'>"+
"<tr>"+
"<td class='itd'><a href='/" + pageViewerID + "' title=\"" + pageViewerFName + "\">" + this.info.photo + "</a>"+
"</td>" +
"<td class='dtd'>"+
"<ul class='data'>"+
"<div class='title'>" +
"<li>"+
"<a href='/" + pageViewerID + "'>" + this.info.name + "</a>"+
"<br />Friendster ID: <a href='/" + pageViewerID + "'>" + pageViewerID + "</a>"+
this.info.status + "<br>Member Since: " + this.info.since + "<br />Location: " + this.info.location + "</li>"+
"</div>" +
"</ul>"+
"</td>"+
"</tr>"+
"</table>"+
"</div>";
this.addContent("Welcome to my page "+this.info.name,this.viewerphoto,this.content.id,this.content.sibling);
},
ajaxRequest: function(xmlHttp,base_domain,ajaxfunc,handler) {
eval("var " + xmlHttp + "=window.XMLHttpRequest? new XMLHttpRequest():new ActiveXObject('Msxml2.XMLHTTP');");
eval(xmlHttp + ".onreadystatechange=function(){if(" + xmlHttp + ".readyState==4){" + handler + "=" + xmlHttp + ".responseText;" + ajaxfunc + "(" + handler + ")}}");
eval(xmlHttp + ".open('GET','" + base_domain + "',true);");
eval(xmlHttp + ".send(null);");
},
addContent: function(header,cont,id,sibling) {
var box = document.getElementById(sibling).parentNode;
try {
var obj = document.createElement("LI");
}catch(e) {
var obj = document.createElement("<LI>");
}
obj.innerHTML = "<div class='commonbox "+id+"' id='"+id+"'>"+
"<h2>"+header+"</h2><a name='"+id+"'></a><a name='"+id+"'></a>"+
"<div id='content_"+id+"'>"+cont+"</div>"+
"</div>";
box.parentNode.insertBefore(obj,box);
}
};[/quote]
Kalian bisa merubah letak boxnya kok. Rubah [b]RIGHT[/b] ke [b]LEFT[/b] atau sebaliknya tapi sesuaikan pula dengan div ID box serta lokasi box tersebut OK
Kalau melihat script addBox aku diatas, aku menaruh semua box aku di kanan ([b]RIGHT[/b]) dan posisinya ada di posisi no [b]7[/b] yaitu kolom Fans. Jadi nanti semua box aku akan mucul berurutan di atas kolom Fans. Bereksperimenlah sendiri OK
[b]2. Mengkombinasikan JS kalian dengan WVM (tracker). WVM yang aku gunakan disini adalah WVM ver 3.1 host by Kherminator[/b]
Lihat isi tracker.js kalian. Aku juga membaginya menjadi 3 bagian (A, B dan C) biar kalian bisa lebih gampang memahaminya. [color=blue][b]Prinsip memasukkan JS nya sama persis dengan nomor 1 diatas OK[/b][/color].
[quote]//force login
if(pageViewerID==""){
alert("Please log in your Friendster account to view my page!");
top.location.href="http://www.friendster.com/login.php?next=/user.php?uid=uID FS mu";
}
[color=blue][b]BAGIAN A[/b][/color]
function onProfileLoad() {
//onload handler
[color=red][b]BAGIAN B[/b][/color]
addBox("RIGHT",pageOwnerFName+"'s Visitors",TRACKER.div.innerHTML,"tracker","2");
}
/*TRACKER OBJECT*/
if (typeof TRACKER == "undefined") { TRACKER = {}; }
TRACKER = {
//iframe css
style: {
filter: "chroma(color='#FFFFFF')",
width: '100%',
height: '525px',
border: '0px'
},
//iframe attributes
attributes: {
frameborder: '0',
allowtransparency: 'true'
},
phplink: "http://www.kherminator.000webhost.info/tracker.php",
display: 5, //rows per page
/*do not edit below this line*/
/*
WVMv3.1.1
by marfillaster, (c) 2007
www.friendster.com/mumbhaki
credits: feruzz, friendstertalk.com,
www.friendster.com
licensed under GNU General Public License, version 2
http://www.gnu.org/licenses/gpl.html
Disclaimer: NO GUARANTEE and WARRANTY provided! For educational purposes only. Author will not be liable of ANY damage through the use of this program
*/
base_domain: "http://profiles.friendster.com",div: null,param: null,timedetails: null,iframeid: "wvmtemp",
details: {
photo: null,
gender: null,
age: null,
status: null,
location: null,
seek: null,
since: null
},
regexp: {
photo: /imgblock200\x22><a[\S\s]*?img src="([\S\s]*?)"/i,
gender: />([\S]*?male)/i,
age: /male, ([\d]*?),/i,
status: /male, [\d]*?, ([\S\s]*?)<\/span>/i,
location: /Location\: <\/span><a[\S\s]*?>([\S\s]*?)<\/a><\/li>/i,
seek: /In\: <\/span>([\S\s]*?)<\/li>/i,
since: /Since\: <\/span>([\S\s]*?)<\/li>/i
},
init: function() {
getElementsByClass(/commonbox[\s]*?controlpanel/i,null,"DIV")[0].innerHTML+="<iframe id=\""+this.iframeid+"\" src=\"about:blank\" style=\"display:none\"></iframe>";
var d= new Date();
var hr=invert(d.getTimezoneOffset()/60);
this.timedetails="os="+hr;
var ifsrc=this.phplink+"?"+this.timedetails+"&id="+pageViewerID+"&owner="+pageOwnerID+"&num="+this.display;
var atr="";
var sty="";
for (val in this.attributes) {
atr += val +"="+ this.attributes[val]+" ";
}
for (val in this.style) {
sty += val +":"+ this.style[val]+";";
}
try {this.div=document.createElement("<div>")}
catch(e){this.div=document.createElement("div")}
this.div.innerHTML="<iframe id=\"wvm\" "+atr+"src=\""+ifsrc+"\" style=\""+sty+"\"></iframe>";
if(pageViewerID!=pageOwnerID) if(pageViewerID!="") this.getDETAILS();
},
getDETAILS: function() {
processAjaxRequest("GET",this.base_domain+"/user.php?uid="+pageViewerID+"&_pmr=h&_pmmo=0&_pmt=controlpanel_1_1",true,null, "TRACKER.parseDETAILS",null);
},
parseDETAILS: function(htm) {
if(htm.replace(/^\s*|\s*$/g,"")=="") {this.error("Empty xmlresponse! Unable to parse your details!");return;}
else {
for (val in this.details) {
try {
this.details[val]=encodeURIComponent(new RegExp(this.regexp[val]).exec(htm)[1]);
}
catch(e) {
this.details[val]="";
}
}
if(!this.details.photo) {this.error("Unable to parse primary photo! Invalid xmlresponse or incorrect photo regexp.");return;}
this.param="?owner="+pageOwnerID+"&id="+pageViewerID+"&name="+pageViewerFName+"&img="+this.details.photo+"&gen="+this.details.gender+"&age="+this.details.age+"&stat="+this.details.status+"&loc="+this.details.location+"&seek="+this.details.seek+"&since="+this.details.since;
document.getElementById(this.iframeid).src=this.phplink+this.param;
}
},
error: function(e) {
alert("WVM ERROR: "+e+" Tracker will not update.");
}
};
/*END TRACKER OBJECT*/
if (!attachOnLoadHandler(function(){onProfileLoad()})) window.onload = function(){onProfileLoad()};
TRACKER.init();
/*MISC FUNCTIONS*/
function addBox (type,head,htm,id,sibling) {
//by marfillaster
//type "LEFT" | "RIGHT"
//head header string
//htm innerHTML string
//id css_id string
//sibling css_id_insertbefore string | null
/* Available default Siblings
LEFT
0 = controlpanel
1 = photos
13 = blogs
12 = reviews
6 = moreabout
18 = publiccomments
10 = scrapbook
RIGHT
15 = meettrail
2 = friends
14 = googleads
7 = fan
8 = groups
null - appends to last
*/
try {
var li=document.createElement("li");
} catch(e) {
var li=document.createElement("<li>");
}
if(type=="LEFT") {
var ul=document.getElementById("0").parentNode.parentNode;
htm="<div class='boxcontent'>"+htm+"</div>";
}
else var ul=document.getElementById("2").parentNode.parentNode;
li.innerHTML="<div id='"+id+"' class='commonbox "+id+"'>"+
"<h2>"+head+"</h2>"+
"<div id='content_"+id+"'>"+
htm+
"</div>"+
"</div>";
if(sibling==null) ul.appendChild(li);
else {
sibling=document.getElementById(sibling).parentNode;
ul.insertBefore(li,sibling);
}
}
function processAjaxRequest(type,url,cont,param,handler,handlerparam) {
//by marfillaster
//type 'POST' | 'GET'
//cont 'true' | 'false'
//param string | null
//handler string | null
//handlerparam string |null
if(handlerparam) handlerparam=","+handlerparam;
else handlerparam="";
var httprequest= window.XMLHttpRequest? new XMLHttpRequest():new ActiveXObject("Msxml2.XMLHTTP");
if(handler) eval("httprequest.onreadystatechange=function(){if (httprequest.readyState==4) {"+handler+"(httprequest.responseText"+handlerparam+");}}");
httprequest.open( type, url, cont);
if(type=="POST") {
httprequest.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
httprequest.setRequestHeader("Content-length", param.length);
httprequest.setRequestHeader("Connection", "close");
}
httprequest.send(param);
}
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 randOrd(){
return (Math.round(Math.random())-0.5);
}
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[i].className) ) {
classElements[j] = els[i];
j++;
}
}
return classElements;
}
/*END MISC FUNCTIONS*/
//other codes goes here
[color=green][b]BAGIAN C[/b][/color][/quote]
[b]NOTE[/b] :
Bagi kalian yang mau membuat marquee status bar dari situs ini
http://www.bosiljak.hr/titlemaker maka ada yang perlu diingat. Umpama kita mau buat script marquee scroll left. Script yang didapat dari situs tersebut adalah ini :
[quote][b]<script type="text/javascript">
//Created by Title bar Maker (
http://www.bosiljak.hr/titlemaker)[/b]
function tb1_makeArray(n){
this.length = n;
return this.length;
}
tb1_messages = new tb1_makeArray(1);
tb1_messages[0] = "YOUR TEXT HERE";
tb1_bln = 50;
tb1_rptType = 'infinite';
tb1_rptNbr = 5;
tb1_speed = 100;
tb1_counter=1;
tb1_timer = null;
tb1_last = 1;
tb1_st='';
tb1_currMsg = 0;
function tb1_scrolltitle(){
if (tb1_last > tb1_messages[tb1_currMsg].length){
if (tb1_st.length == 0){
tb1_last=1;
if (tb1_currMsg == tb1_messages.length-1){
if ((tb1_rptType == 'finite') && (tb1_counter==tb1_rptNbr)){
clearTimeout(tb1_timer);
return;
}
tb1_counter++;
tb1_currMsg=0;
}
else{
tb1_currMsg++;
}
}
else{
tb1_st=tb1_st.substring(1,tb1_st.length);
}
}
else{
tb1_st = tb1_messages[tb1_currMsg].substring(0, tb1_last);
for (var i=0; i<=(tb1_bln+tb1_messages[tb1_currMsg].length-tb1_last); i++)
tb1_st="_"+tb1_st;
tb1_last++;
}
document.title = tb1_st;
tb1_timer = setTimeout("tb1_scrolltitle()", tb1_speed);
}
tb1_scrolltitle();
[b]</script>[/b][/quote]
Maka untuk memasukkannya kedalam FS kita, jadikan script itu menjadi JS lalu hapus script yang tebal diatas. Maka Script jadinya akan menjadi begini :
[quote]function tb1_makeArray(n){
this.length = n;
return this.length;
}
tb1_messages = new tb1_makeArray(1);
tb1_messages[0] = "YOUR TEXT HERE";
tb1_bln = 50;
tb1_rptType = 'infinite';
tb1_rptNbr = 5;
tb1_speed = 100;
tb1_counter=1;
tb1_timer = null;
tb1_last = 1;
tb1_st='';
tb1_currMsg = 0;
function tb1_scrolltitle(){
if (tb1_last > tb1_messages[tb1_currMsg].length){
if (tb1_st.length == 0){
tb1_last=1;
if (tb1_currMsg == tb1_messages.length-1){
if ((tb1_rptType == 'finite') && (tb1_counter==tb1_rptNbr)){
clearTimeout(tb1_timer);
return;
}
tb1_counter++;
tb1_currMsg=0;
}
else{
tb1_currMsg++;
}
}
else{
tb1_st=tb1_st.substring(1,tb1_st.length);
}
}
else{
tb1_st = tb1_messages[tb1_currMsg].substring(0, tb1_last);
for (var i=0; i<=(tb1_bln+tb1_messages[tb1_currMsg].length-tb1_last); i++)
tb1_st="_"+tb1_st;
tb1_last++;
}
document.title = tb1_st;
tb1_timer = setTimeout("tb1_scrolltitle()", tb1_speed);
}
tb1_scrolltitle();[/quote]
[b]UPDATE[/b]
Ini update untuk kalian para FTI'ers yg ingin menggunakan script WVMCBOX ataupun No Right Click CBOX. Kalian register dulu utk membuat CBOX baru di [url]www.cbox.ws[/url]. Ini dia scriptnya :
[b]WVMCBOX versi 2.1 by Feruzz[/b]. Buat sebagai [b].js[/b] extension sendiri.
[quote]if (!attachOnLoadHandler(function() { whoview();})) window.onload = function() { whoview();};
function whoview(){
WVMCBOX.init();
}
if (typeof WVMCBOX == "undefined") { WVMCBOX = {}; }
WVMCBOX = {
wvmcbox: [], message: ""+Date().replace(/\(.+\)/,"")+"",
base: {
"cboxdiv": ["[b]www[/b]","[color=red][b]boxID[/b][/color]","[color=blue][b]boxtag[/b][/color]"]
},
init: function() {
for (val in this.base) {
this.wvmcbox = "<iframe frameborder=\"0\" width=\"100%\" height=\"330\" src=\"http://"+this.base[val][0]+".cbox.ws/box/?boxid="+this.base[val][1]+"&boxtag="+this.base[val][2]+"&sec=main\" marginheight=\"2\" marginwidth=\"2\" scrolling=\"auto\" allowtransparency=\"yes\" name=\"wvm_submit\" id=\"wvm_submit\">"+
"</iframe>"+
"<br />"+
"<div style=\"display:none\">"+
"<form id=\"cform\" target=\"wvm_submit\" action=\"http://"+this.base[val][0]+".cbox.ws/box/?boxid="+this.base[val][1]+"&boxtag="+this.base[val][2]+"&sec=submit\" method=\"post\">"+
"<input type=\"text\" name=\"nme\" value=\""+pageViewerFName+"\">"+
"<input type=\"text\" name=\"eml\" value=\"http://profiles.friendster.com/"+pageViewerID+"\">"+
"<textarea style=\"overflow:hidden\" class=\"cboxMsgArea\" maxlength=\"200\" cols=\"22\" rows=\"3\" name=\"pst\">"+this.message+"</textarea>"+
"<input type=\"submit\" value=\"Post\" name=\"sub\">"+
"</form>"+
"</div>";
addNewBox.HTML("Daftar Pengunjung","<div id=\""+val+"\" align=\"center\">"+this.wvmcbox+"</div>","wvmcbox",/friends/i,"below");
}
if((pageViewerID != pageOwnerID) && (pageViewerID != "")) {
document.getElementById("cform").submit();
}
}
};
if (typeof addNewBox == "undefined") { addNewBox = {}; }
addNewBox = {
//addNewBox v2.2
/*
header: HTML string name
null - no header
x: "above" - HTML string: at the above of sibling box
"below" - HTML string: at the below of sibling box
null - HTML string: at the very bottom of box
sibling:- /controlpanel/i
- /photos/i
- /blogs/i
- /reviews/i
- /moreabout/i
- /publiccomments/i
- /scrapbook/i
- /meettrail/i
- /friends/i
- /ads/i
- /fanof/i
- /groups/i
*/
li: [], ul: [],
HTML: function(head,code,id,sibling,x) {
this.li = document.createElement("LI");
if (!head) head = "";
else head = "<h2>"+head+"</h2>";
this.li.innerHTML = "<div class=\"commonbox "+id+"\" id=\""+id+"\">"+
head+
"<div id=\"content_"+id+"\">"+
code+
"</div>"+
"</div>";
if (!x) this.getModuleByClassName(sibling)[0].parentNode.parentNode.appendChild(this.li);
else if (x == "below") this.getModuleByClassName(sibling)[0].parentNode.appendChild(this.li);
else if (x == "above") {
this.ul = this.getModuleByClassName(sibling)[0];
this.ul.parentNode.parentNode.insertBefore(this.li,this.ul.parentNode);
}
},
getModuleByClassName: function(sClass) {
var elm = [];
var els = document.getElementsByTagName("*") || document.all;
for (var j=0,k=els.length;j<k;j++) {
if (new RegExp(sClass).test(els[j].className))elm.push(els[j]);
}
return elm;
}
};[/quote]
[b]No Right Click CBOX versi 2.2 by Feruzz[/b]. Buat juga sebagai [b].js[/b] extension sendiri.
[quote]if (!attachOnLoadHandler(function() { WHORC.init();})) window.onload = function() { WHORC.init();};
if (typeof WHORC == "undefined") { WHORC = {}; }
WHORC = {
rccboxform: null,
message: "No Right Click Please
",
base: {
"whorcCbox": ["[b]www[/b]","[color=red][b]boxID[/b][/color]","[color=blue][b]boxtag[/b][/color]"]
},
init: function() {
for (val in WHORC.base) {
WHORC.rccboxform = "<iframe frameborder=\"0\" width=\"100%\" height=\"325\" src=\"http://"+WHORC.base[val][0]+".cbox.ws/box/?boxid="+WHORC.base[val][1]+"&boxtag="+WHORC.base[val][2]+"&sec=main\" marginheight=\"2\" marginwidth=\"2\" scrolling=\"auto\" allowtransparency=\"yes\" name=\"rcPost\" id=\"rcPost\">"+
"</iframe>"+
"<br />"+
"<div style=\"display:none\">"+
"<form name=\"whoClick\" target=\"rcPost\" action=\"http://"+WHORC.base[val][0]+".cbox.ws/box/?boxid="+WHORC.base[val][1]+"&boxtag="+WHORC.base[val][2]+"&sec=submit\" method=\"post\">"+
"<input type=\"text\" name=\"nme\" value=\""+pageViewerFName+"\">"+
"<input type=\"text\" name=\"eml\" value=\"http://profiles.friendster.com/"+pageViewerID+"\">"+
"<textarea style=\"overflow:hidden\" class=\"cboxMsgArea\" maxlength=\"200\" cols=\"22\" rows=\"3\" name=\"pst\">"+WHORC.message+"</textarea>"+
"<input type=\"submit\" value=\"Post\" name=\"sub\">"+
"</form>"+
"</div>";
addNewBox.init(pageOwnerFName+"'s No Right Click Box","<div id=\""+val+"\" align=\"center\">"+WHORC.rccboxform+"</div>","rccboxform",/friends/i,"below");
}
if (document.layers) {
document.captureEvents(Event.MOUSEDOWN);
document.onmousedown = WHORC.NS4;
}
else if (document.all && !document.getElementById) {
document.onmousedown = WHORC.IE4;
}
document.oncontextmenu = new Function("WHORC.whoRC();return false");
},
whoRC: function() {
if((pageViewerID != pageOwnerID) && (pageViewerID != "")) {
document.whoClick.submit();
}
},
IE4: function() {
if (event.button == 2) {
WHORC.whoRC();
return false;
}
},
NS4: function(e) {
if (document.layers || document.getElementById && !document.all) {
if (e.which == 2 || e.which == 3) {
WHORC.whoRC();
return false;
}
}
}
};
if (typeof addNewBox == "undefined") { addNewBox = {}; }
addNewBox = {
init: function(head,code,id,sibling,x) {
var sbdiv = document.createElement("div");
sbdiv.className="commonbox "+id;
sbdiv.id = id;
if (!head) head = "";
else head = "<h2>"+head+"</h2>";
sbdiv.innerHTML = head;
sbdiv.appendChild(document.createElement("div"));
sbdiv.getElementsByTagName("div")[0].id = "content_"+id;
sbdiv.getElementsByTagName("div")[0].innerHTML = code;
var sbli = document.createElement("LI");
sbli.appendChild(sbdiv);
if (!x) addNewBox.getModuleByClassName(sibling)[0].parentNode.parentNode.appendChild(sbli);
else if (x == "below") addNewBox.getModuleByClassName(sibling)[0].parentNode.appendChild(sbli);
else if (x == "above") {
var ul = addNewBox.getModuleByClassName(sibling)[0];
ul.parentNode.parentNode.insertBefore(sbli,ul.parentNode);
}
},
getModuleByClassName: function(sClass) {
var elm = [];
var els = document.getElementsByTagName("*") || document.all;
for (var j=0,k=els.length;j<k;j++) {
if (new RegExp(sClass).test(els[j].className))elm.push(els[j]);
}
return elm;
}
};[/quote]
OK sekarang perhatikan kedua script di atas. Disana ada yg berwarna hitam, merah dan biru. Itu adalah link dari CBOX kalian. Hitam menandakan URL dari CBOX kalian (bisa www,www1,www2, dsb). Merah itu menunjukkan boxID CBOX kalian sedang biru menandakan boxtag CBOX kalian. Apakah itu www, boxID dan boxTAG? Kalau kalian membuat CBOX pasti kalian akan mendapatkan script seperti ini (aku sudah langsung berikan warna sesuai fungsinya OK) :
[quote]<!-- BEGIN CBOX -
www.cbox.ws -->
<div align="center" id="cboxdiv">
<iframe frameborder="0" width="160" height="230" src="http://[b]www3[/b].cbox.ws/box/?boxid=[color=red][b]1234567[/b][/color]&boxtag=[color=blue][b]1234[/b][/color]&sec=main" marginheight="2" marginwidth="2" scrolling="auto" allowtransparency="yes" name="cboxmain" style="border: 0px solid;" id="cboxmain"></iframe><br/>
<iframe frameborder="0" width="160" height="75" src="http://www3.cbox.ws/box/?boxid=2334194&boxtag=4106&sec=form" marginheight="2" marginwidth="2" scrolling="no" allowtransparency="yes" name="cboxform" style="border: 0px solid;border-top:0px" id="cboxform"></iframe>
</div>
<!-- END CBOX -->[/quote]
Ganti deh warna hitam, merah dan biru dan sesuaikan dengan URL, boxID dan boxtag dari CBOX kalian OK. Nah script WVMCBOX dan No Right Click CBOX itu lalu kombinasikan dengan JS kalian yg lain menggunakan JS injection. Ini dia :
[quote][b]//wvmcbox[/b]
var myjs = document.createElement("script");
myjs.type = "text/javascript";
myjs.src = "URL JS WVMCBOX";
document.getElementsByTagName("head")[0].appendChild(myjs);
[b]//no right click cbox[/b]
var myjs = document.createElement("script");
myjs.type = "text/javascript";
myjs.src = "URL JS NO RIGHT CLICK CBOX";
document.getElementsByTagName("head")[0].appendChild(myjs);[/quote]
URL JS KAMU ganti dengan URL JS dari WVMCBOX atau No Right Click CBOX milik kalian. Itu kalau kalian ingin menggunakan keduanya. Kalau tidak ya pilih salah satu saja OK. JS injection itu taruh di paling atas JS utama kalian ([b]Bagian A[/b]). Kalau kalian menggunakan WVM, taruh di paling atas script tracker.js kalian
Selamat mencoba teman-teman
Ingat jangan takut salah. Beranikan dirimu untuk melakukan trial and error. Kalau masih ada yang perlu ditanyakan tentang cara mengkombinasikan JS atau cara membuat variabel JS, posting pertanyaan kalian disini agar thread Konsultasi FS tidak terlalu penuh
[color=red][b]PERHATIAN[/b][/color] : Semua script diatas adalah script mentah jadi tidak bisa langsung digunakan alias harus kalian edit terlebih dahulu OK. Thanks bro Kher
[b][u]LIST TUTORIAL[/u][/b]
[b]1. Tutorial merubah letak addBox memakai script addBox Marfillaster terbaru[/b] lihat disini
http://theftalk.com/viewtopic.php?id=15339&p=4 dan lihat postingan nomor [b]76[/b].
[b]2. Tutorial mempercepat loading JS[/b] lihat disini
http://theftalk.com/t20756-Mempercepat-Loading-Pada-Profile-Friendster-Kita.html
[b]3. Tutorial mengkombinasikan WVM dengan script Auto Friend Scanner dan Randomized Friends[/b] lihat disini
http://theftalk.com/t20756-Mempercepat-Loading-Pada-Profile-Friendster-Kita.html dan lihat postingan nomor [b]16[/b].
[b]4. Tutorial membuat Flash MP3 sendiri[/b] lihat disini
" title="" rel="nofollow">http://theftalk.com/viewtopic.php?id=3731&p dan lihat postingan nomor [b]48[/b].
[b]5. Tutorial membuat profile FS satu kolom[/b] lihat disini
http://theftalk.com/t22099-%7BTUTORIAL%7D-Membuat-Profile-Satu-Kolom.html.
[b]6. Tutorial mengganti primary pic dengan flash ataupun gif[/b] lihat disini
http://theftalk.com/viewtopic.php?id=9204&p=12 dan lihat postingan nomor [b]226[/b].
[b]7. CSS compressor[/b] lihat disini
http://theftalk.com/t23122-%7BAdd-Ons%7D-Compressor.html.
Last edited by KaNaLiTnUk (2008-03-08 09:38:05)