Business Advice and Help Forum for Businesses or Starting a Company in the UK - A1 Business Forums
corner image corner image
Member Box




corner image corner image
Our Advertisers

corner image corner image
Register FAQ Members List Today's Posts Search Today's Posts Mark Forums Read
A1 Business Blog Home
corner image corner image
A1businessforums.co.uk - The UK's Friendliest Online Business Community
Go Back   Business Forum UK - Advice Help and Questions - A1 Forums > Business Forums > Graphic Design, Web Design and Coding
Reload this Page

Overidding CSS

Designers Forum for Graphic, Logo or Print Design and Photography plus Website Design, Coding, Themes and Skins

Reply
corner image corner image
 
LinkBack Thread Tools Search this Thread Display Modes

corner image corner image
  #1 (permalink)  
Old 20-07-2008, 13:47
dragonfly dragonfly is online now
A1 is my Second Home!
 
Join Date: Jul 2008
Posts: 144
Thanks: 5
Thanked 11 Times in 5 Posts
Default Overidding CSS

Can anybody give me some quick pointers (or atleast tell me where to find the answer) I'm playing with some layouts on a web page that has CSS. All the links are defined so that when you hover over them they change to a set size\colour etc.

however I want to have a bigger link at the bottom of the page as a call to action. I'm using <h2> tags round it which get it to the right size, howver when you hover over it, it changes to the CSS size. How can I have it so that it still changes colour etc. but doesn't change size.
__________________
Same Day Courier
I want to give you MONEY
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on FacebookStumble this Post!Google Bookmark this Post!
Reply With Quote
corner image corner image
Sponsored Links

Register to remove these ads
dragonfly
View Public Profile
Send a private message to dragonfly
Find all posts by dragonfly
corner image corner image
  #2 (permalink)  
Old 20-07-2008, 14:18
UKSBD UKSBD is offline
A1 is my Second Home!
 
Join Date: Mar 2008
Location: Warwickshire
Posts: 287
Thanks: 2
Thanked 56 Times in 45 Posts
h2 {font-size:120%;}
h2 a:hover {font-size:120%;}
__________________
UK Small Business Directory
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on FacebookStumble this Post!Google Bookmark this Post!
Reply With Quote
UKSBD
View Public Profile
Send a private message to UKSBD
Visit UKSBD's homepage!
Find all posts by UKSBD
corner image corner image
  #3 (permalink)  
Old 20-07-2008, 15:11
dragonfly dragonfly is online now
A1 is my Second Home!
 
Join Date: Jul 2008
Posts: 144
Thanks: 5
Thanked 11 Times in 5 Posts
Is thier a way of doing that without editing the css?
__________________
Same Day Courier
I want to give you MONEY
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on FacebookStumble this Post!Google Bookmark this Post!
Reply With Quote
dragonfly
View Public Profile
Send a private message to dragonfly
Find all posts by dragonfly
corner image corner image
  #4 (permalink)  
Old 20-07-2008, 15:50
UKSBD UKSBD is offline
A1 is my Second Home!
 
Join Date: Mar 2008
Location: Warwickshire
Posts: 287
Thanks: 2
Thanked 56 Times in 45 Posts
<h2 style="font-size:120%;">
__________________
UK Small Business Directory
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on FacebookStumble this Post!Google Bookmark this Post!
Reply With Quote
UKSBD
View Public Profile
Send a private message to UKSBD
Visit UKSBD's homepage!
Find all posts by UKSBD
corner image corner image
  #5 (permalink)  
Old 20-07-2008, 16:10
dragonfly dragonfly is online now
A1 is my Second Home!
 
Join Date: Jul 2008
Posts: 144
Thanks: 5
Thanked 11 Times in 5 Posts
Thanks, using your points and a bit of google, I've worked out what I wanted. Basically I didn't want to hack around with the global CSS to achieve my result, as that could effect other pages.

So what I did was put the following in the body of the html

<style type="text/css">
h2 {color: #ffffff; font-family: Arial; font-weight:bold; font-size:18px }
h2 a:hover { color: red; font-family: Arial;font-weight:bold; font-size:19px;}
</style>

What I find strange and I can't explain is the fin-size is different in both settings to keep the resulting text the same. Strange

Thanks

Dave.
__________________
Same Day Courier
I want to give you MONEY
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on FacebookStumble this Post!Google Bookmark this Post!
Reply With Quote
dragonfly
View Public Profile
Send a private message to dragonfly
Find all posts by dragonfly
corner image corner image
  #6 (permalink)  
Old 26-07-2008, 00:33
nass nass is offline
A1 is my Second Home!
 
Join Date: Jul 2008
Posts: 139
Thanks: 10
Thanked 30 Times in 26 Posts
Try

Code:
<style type="text/css">
h2 a {color: #fff; font-family: Arial; font-weight:bold; font-size:19px; }
h2 a:hover { color: red; font-family: Arial;font-weight:bold; font-size:19px;}
</style>
or if you prefer 18px
Code:
<style type="text/css">
 h2 a {color: #fff; font-family: Arial; font-weight:bold; font-size:18px; }
 h2 a:hover { color: red; font-family: Arial;font-weight:bold; font-size:18px;}
 </style>
Not really strange - you'd missed out the a so it's inheriting it from elsewhere would be my guess
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Share on FacebookStumble this Post!Google Bookmark this Post!
Reply With Quote
nass
View Public Profile
Send a private message to nass
Find all posts by nass
Reply

« Dreamweaver - again!!! | Web Site design Flaws. »

corner image corner image
Thread Tools Search this Thread
Show Printable Version Show Printable Version
Email this Page Email this Page
Search this Thread:

Advanced Search
Display Modes
Linear Mode Linear Mode
Hybrid Mode Switch to Hybrid Mode
Threaded Mode Switch to Threaded Mode

corner image corner image
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are On


All times are GMT +1. The time now is 14:46.


Calendar - Contact Us - A1 Business Forum UK - Archive - Top

© A1 Business Forums 2008

Pixelcraze
Forum theme a Pixelcraze Creation





LinkBack
LinkBack URL LinkBack URL
About LinkBacks About LinkBacks
Bookmark & Share
Digg this Thread! Digg this Thread!
Add Thread to del.icio.us Add Thread to del.icio.us
Bookmark in Technorati Bookmark in Technorati
Furl this Thread! Furl this Thread!
Share on Facebook Share on Facebook
Stumble this Thread Stumble this Thread
Google Bookmark this Thread Google Bookmark this Thread