Click here to Skip to main content
12,953,263 members (48,576 online)
Click here to Skip to main content
Add your own
alternative version


24 bookmarked
Posted 13 Jun 2005

fun with css part 1

, 13 Jun 2005 CPOL
Rate this:
Please Sign up or sign in to vote.
spice up your <input /> fields

Sample Image - fun_with_css_part_1.jpg


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

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

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.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

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

You may also be interested in...

Comments and Discussions

GeneralProblems in IE Pin
Dewang Mehta14-Jul-07 16:32
memberDewang Mehta14-Jul-07 16:32 
GeneralUsability Pin
Uwe Keim13-Jun-05 19:42
sitebuilderUwe Keim13-Jun-05 19:42 
QuestionWhat about the fox!? Pin
oykica13-Jun-05 12:21
memberoykica13-Jun-05 12:21 
AnswerRe: What about the fox!? Pin
Daniel Walzenbach13-Jun-05 17:59
memberDaniel Walzenbach13-Jun-05 17:59 
GeneralRe: What about the fox!? Pin
oykica13-Jun-05 22:17
memberoykica13-Jun-05 22:17 
GeneralRe: What about the fox!? Pin
Daniel Walzenbach14-Jun-05 0:19
memberDaniel Walzenbach14-Jun-05 0:19 
GeneralRe: What about the fox!? Pin
oykica14-Jun-05 3:27
memberoykica14-Jun-05 3:27 

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

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

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