If you are seeing this message, it is possible the page did not load properly. Please hit reload/refresh on your browser.
If you still see this message, you probably do not have a browser that supports
web standards, although its content is accessible to any browser or Internet device.
Here's a cool CSS trick that I used in the links table in the top of the forum. This code turns your link into a button that depresses when you click it. The code actually uses a table and utilizes borders to make the buttons look like buttons. Then, the code splits the link into the a:link, a:visited, a:active, and a:hover parts so that you can create a different link color for the buttons than the rest of your site.
Standard buttons housed within forms are generally not as customizable as this button and standard ones are generally associated with form submittal or script activation. Buttons used for other purposes require images and with too many images can reduce page loading time. Also, you can make additional code with the a:hover portion of the CSS script to change the link text as your mouse hovers over it just like any other link.
Installation
First, add this stylesheet to the head of your document:
Posted: 8/23/03 5:58 pm Re: CSS Tip-Colored Buttons
Nice tut Q-T although i have a couple of improvements
Instead of giving each TD the class of mybutton, why dont you give the table the class, each TD (and links within them) will enherit that class anyways. It may only shave a nanosecond off the loading time ... but speed is everything
You should consider using lists and pure CSS for link buttons such as this. Not only will you be future proofing yourself with XHTML, its also a better way to do things, In my opinion. Soon (well probably not) ezboard will be porting over to XHTML for message boards, and hopefully table less layouts aswell .. so this will prepare you for when that happens
Posted: 8/24/03 8:15 am Re: CSS Tip-Colored Buttons
"Instead of giving each TD the class of mybutton, why dont you give the table the class, each TD (and links within them) will enherit that class anyways. It may only shave a nanosecond off the loading time ... but speed is everything"--A J
Good point, and for most situations this would probably be better. However, if you wanted to apply perhaps different colors onto certain buttons then giving each td the class would make it easier to transfer certain buttons with a new class with different color properties.
Then again, I'm pretty new at web design myself (so I should be using your methods anyway), but when I discovered this code through trying to improve certain elements of my board, I thought that the effect was pretty cool .