December 16, 2018, 02:53:46 pm
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to Revolution X, where Coding meets Graphics.
 
  Home Help Search Arcade Affiliates Staff List Calendar Members Login Register  

Floating Tabs

Pages: [1]   Go Down
  Print  
Author Topic: Floating Tabs  (Read 1352 times)
Agent Moose
Administrator
Adminitrator
Offline Offline

Gender: Male
Posts: 1,470



View Profile WWW
Badges: (View All)
« on: December 03, 2009, 07:43:41 am »

Footers:
Code:
<script type="text/javascript">
var tab = document.getElementsByTagName("table");
//Created by Agent Moose (www.revolution-x.org)
for(x=0;x<tab.length;x++){
if(tab[x].style.marginLeft == "10px" && tab[x].innerHTML.match(/action=(login|logout)/i)){
tab[x].id = "FloatingThingy";
tab[x].style.position = "fixed"
tab[x].style.opacity = 0.6;
tab[x].style.filter = "alpha(opacity=60)";
tab[x].onmouseover = function(){ this.style.opacity = 1; this.style.filter  = "alpha(opacity=100)"; };
tab[x].onmouseout = function(){ this.style.opacity = 0.6; this.style.filter  = "alpha(opacity=60)"; };
tab[x].style.top = document.documentElement.scrollTop;
document.write("<style>* html #FloatingThingy { left: expression( ( 20 + ( bloop = document.documentElement.scrollLeft ? document.documentElement.scrollLeft : document.body.scrollLeft ) ) + 'px' ); }; #FloatingThingy { position: fixed; };</style>");
};};
</script>

Simple code.  Makes the Tabs (Home, Help, Search, ect.) float at the top of the page.  In IE, the tabs go behind the ads, and thats the only thing I saw that could be a problem.

Enjoy Smiley
« Last Edit: January 13, 2010, 12:21:26 pm by Agent Moose » Report Spam   Logged


Andrew
Exclusive
Exclusive
Offline Offline

Gender: Male
Posts: 539



View Profile WWW
Badges: (View All)
« Reply #1 on: December 05, 2009, 07:43:13 pm »

ooo, I like this, great job Agent!

Looks like you're getting back into the swing of coding huh?
Report Spam   Logged

Agent Moose
Administrator
Adminitrator
Offline Offline

Gender: Male
Posts: 1,470



View Profile WWW
Badges: (View All)
« Reply #2 on: December 05, 2009, 08:31:52 pm »

I've created a bit of codes which you can find here(just look through the page source, and in the footers):
http://smctest.smfforfree3.com/

They are just different codes that I am not going to release because I am to lazy Tongue
Report Spam   Logged


Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by EzPortal
Bookmark this site! | Upgrade This Forum
SMF For Free - Create your own Forum | Buy traffic for your forum/website

Powered by SMF | SMF © 2016, Simple Machines
Privacy Policy