Please tell if anyone has working SMF tabs mod
Here i have got a code and have seen this working but i don't know where to add it please tell me if you know
<style>
.tabBorder{
border-left: 1px solid #3A5197;
padding: 5px;
margin-right: 1px;
};
</style>
<script type="text/javascript">
/*
Created by Agent Moose
-zbcode.com
-revolutionx.smfforfree3.com
You may not redistribute or edit without permission
*/
if(location.href == main_url + "index/"){
var Tabs = "";
var Forumz = "";
var FirstView = $("div.category:first").find("h2 a").parent().parent().parent().parent().parent().next().html();
$("div.category[id!='Tabby']").find("h2 a").each(function(){
var startID = this.href.split("/forum/")[1];
var forumID = startID.split("/")[0];
Tabs += "<a id='tab_" + forumID + "' href='javascript:void(0);' onclick='ShowCat(" + forumID + ");' class='tabBorder'>" + this.innerHTML + "</a>";
});
if(readCookie("ShowForum")){
var CurrentCookie = $("div.category").find("h2 a[href*='forum/" + readCookie("ShowForum") + "/']").parent().parent().parent().parent().parent().next().html();
$("div#main div.category:first").before("<div class='category' id='Tabby'><table class='cat_head'><tr><td><h2><span style='float: right;'><a href='javascript:void(0);' onclick='ShowAll(this);' id='ShoeMe'>(Show all Forums)</a></span>Tabs: " + Tabs + "<span class='tabBorder'> </span></h2></td></tr></table><table id='TheTable'>" + CurrentCookie + "</table></div>");
}else{
$("div#main div.category:first").before("<div class='category' id='Tabby'><table class='cat_head'><tr><td><h2><span style='float: right;'><a href='javascript:void(0);' onclick='ShowAll(this);' id='ShoeMe'>(Show all Forums)</a></span>Tabs: " + Tabs + "<span class='tabBorder'> </span></h2></td></tr></table><table id='TheTable'>" + FirstView + "</table></div>");
};
$("div.category[id*='cat-']").hide();
};
function ShowCat(forum){
$("div.category").find("h2 a").each(function(){
if(this.href.match("/forum/" + forum + "/")){
createCookie("ShowForum",forum,365);
Forumz = $(this).parent().parent().parent().parent().parent().next().html();
$("#TheTable").html(Forumz);
};});
};
function ShowAll(){
$("#Tabby").slideToggle();
$("div.category[id*='cat-']").show("normal");
};
function createCookie(name,value,days) {
if (days) {
var date = new Date();
date.setTime(date.getTime()+(days*24*60*60*1000));
var expires = "; expires="+date.toGMTString();
}
else var expires = "";
document.cookie = name+"="+value+expires+"; path=/";
}
function readCookie(name) {
var nameEQ = name + "=";
var ca = document.cookie.split(';');
for(var i=0;i < ca.length;i++) {
var c = ca;
while (c.charAt(0)==' ') c = c.substring(1,c.length);
if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
}
return null;
}
function eraseCookie(name) {
createCookie(name,"",-1);
}
</script>