Click here to Skip to main content
Click here to Skip to main content

fun with css part 1

By , 13 Jun 2005
 

Sample Image - fun_with_css_part_1.jpg

Introduction

Well, I don't know about you but I can't stand those plain html buttons. Fortunately though there is a solution ;-)
Just create a .css file like the following

.niceButton
{ 
    <FONT color=red>padding</FONT>: <FONT color=blue>0px 4px 4px 4px;</FONT>
    <FONT color=red>font-size</FONT>: <FONT color=blue>8pt;</FONT> 
    <FONT color=red>font-family</FONT>: <FONT color=blue>Verdana;</FONT> 
    <FONT color=red>height</FONT>: <FONT color=blue>19px;</FONT> 
    <FONT color=red>filter</FONT>: <FONT color=blue>progid:DXImageTransform.Microsoft.Gradient(GradientType=0, StartColorStr=#dcdcdc, EndColorStr=#ffffff);</FONT>
    <FONT color=red>border-right</FONT>: <FONT color=blue>#7b9ebd 1px solid;</FONT>
    <FONT color=red>border-top</FONT>: <FONT color=blue>#7b9ebd 1px ridge;</FONT> 
    <FONT color=red>border-left</FONT>: <FONT color=blue>#7b9ebd 1px ridge;</FONT>
    <FONT color=red>border-bottom</FONT>: <FONT color=blue>#7b9ebd 1px ridge;</FONT>
} 

set the <input /> control's class property to the .css class created above

<input type="submit" name="Button" value="this is nice" id="Button" class="niceButton" />

and enjoy.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

Daniel Walzenbach
Program Manager Microsoft
United States United States
Member
Program Manager Visual Studio

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
Hint: For improved responsiveness ensure Javascript is enabled and choose 'Normal' from the Layout dropdown and hit 'Update'.
You must Sign In to use this message board.
Search this forum  
    Spacing  Noise  Layout  Per page   
GeneralProblems in IEmemberDewang Mehta14 Jul '07 - 16:32 
GeneralUsabilitysitebuilderUwe Keim13 Jun '05 - 19:42 
QuestionWhat about the fox!?memberoykica13 Jun '05 - 12:21 
AnswerRe: What about the fox!?memberDaniel Walzenbach13 Jun '05 - 17:59 
GeneralRe: What about the fox!?memberoykica13 Jun '05 - 22:17 
GeneralRe: What about the fox!?memberDaniel Walzenbach14 Jun '05 - 0:19 
GeneralRe: What about the fox!?memberoykica14 Jun '05 - 3:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Permalink | Advertise | Privacy | Mobile
Web02 | 2.6.130516.1 | Last Updated 13 Jun 2005
Article Copyright 2005 by Daniel Walzenbach
Everything else Copyright © CodeProject, 1999-2013
Terms of Use
Layout: fixed | fluid