Pages: 1..123456789101112..12

  2007-12-02 10:00:05

frolickfriendster
» FTalkAddict
FTalk Level: zero
310
0
1969-12-31

Re: the codes are possibly obselete [spoiler][quote][b][color=red]For educational purposes only.[/color][/b][/quote] An alternative code for customize header names I made a [b]simple code[/b] & now the co

[quote=feruzz]An alternative code for customize header names I made a [b]simple code[/b] & now the code will easily manipulate the headers DOM structure instead using [b]('h2')[0], ('h2')[1][/b] & so on.... :wasted: Use onload event the code to be execute for friends, fanof or groups [quote]if ( ! attachOnLoadHandler(function () { cHeaders();})) window.onload = function () { cHeaders();}; function cHeaders() { REPLACEIT.init(); } if (typeof REPLACEIT == "undefined") { REPLACEIT = {}; } REPLACEIT = { head: [], init: function() { this.head = this.getModuleByClassName(/controlpanel/i)[0].getElementsByTagName("h1")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/photos/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/blogs/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/reviews/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/moreabout/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/publiccomments/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/scrapbook/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/friends/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/fanof/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; this.head = this.getModuleByClassName(/groups/i)[0].getElementsByTagName("h2")[0]; this.head.innerHTML = "[b]YOUR TITLE NAME[/b]"; }, 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] save into js extension[/quote] The old script (which used to work for me) as well as this new updated one doesnt work anymore. I tried to delete the ones I do not use (for example, the blogs and reviews), but still only the control panel header shows. :(

Pages: 1..123456789101112..12

Board footer

© 2024 F Talk

Current time is 07:12

[ 12 queries - 0.017 second ]
Privacy Policy