Hello fmSoftware. I have a script for turning phpbb3 statistics into tabs , but it's "ugly". Here are the codes..
Javascript:
CSS :
Javascript:
- Code:
$(function(e) {
('Copyright (c) 2012 - 2013 D World Oficial. All right reserved. Un script util pentru a da un nou aspect statisticilor pe versiunea phpbb3.');
$('.h3:contains("Cine este conectat?")').before('<li style="display: inline; margin: 10px 5px 0 0px; float: left;"><span onclick="whos()" style="background-color: #DDE7F0; clear: both; padding: 5px 10px;margin: 5px 0 -6px;border-radius: 3px 3px 0 0;">Who is online</span></li><div id="onlinestats"></div><li style="display: inline; position: relative; top: 10px;"><span onclick="stats()" style="background-color: #DDE7F0; clear: both; padding: 5px 10px; margin: 5px 5px -6px 0px; border-radius: 3px 3px 0 0;">Statistici</span></li><div id="laststats" style="float: right; display: none;"></div><li style="display: inline; position: relative; top: 10px;"><span onclick="chatbox()" style="background-color: #DDE7F0; clear: both; padding: 5px 10px;margin: 5px 5px 0 0px;border-radius: 3px 3px 0 0;">Chatbox</span></li><div id="chatstats" style="display: none;"></div><li style="display: inline; position: relative; top: 10px;"><span onclick="newtab()" style="background-color: #DDE7F0; clear: both; padding: 5px 10px;margin: 5px 0 -6px;border-radius: 3px 3px 0 0;">Newtab</span></li><div id="newtab" style="display: none;"></div>');
// Stats / Whosonline / Chatbox / Newtab
$('.h3:contains("Cine este conectat?"), #i_whosonline +p').prependTo('#onlinestats');
$('.h3:contains("Statistici"), p.page-bottom').appendTo('#laststats');
$('.h3:contains("Chatbox")').prependTo('#chatstats');
$('div.page-bottom, #chatbox_popup').remove();
});
// Function show/hide active element.
function whos() {
document.getElementById("onlinestats").style.display= 'inline';
$('#laststats, #chatstats, #newtab').hide();
}
// Function show/hide active element.
function stats() {
document.getElementById("laststats").style.display= 'inline';
$('#onlinestats, #chatstats, #newtab').hide();
}
// Function show/hide active element.
function chatbox() {
document.getElementById("chatstats").style.display= 'inline';
$('#onlinestats, #laststats, #newtab').hide();
}
// Function show/hide active element.
function newtab() {
document.getElementById("newtab").style.display= 'inline';
$('#onlinestats, #laststats, #chatstats').hide();
}
CSS :
- Code:
#onlinestats, #laststats, #chatstats, #newtab {[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
background-color: #DDE7F0;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
clear: both;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
padding: 3px 10px;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
width: 700px;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
margin: 5px 0;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
border-radius: 0 3px 3px 3px;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
float: left!important;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
}[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
#onlinestats .h3, #laststats .h3, #chatstats .h3 {[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
margin-top: 0;[color=#2e8b57][font=Courier, CourierNew, sans-serif][/font][/color]
}