CSS - Monospace Vs. Proportional Fonts In Form Fields
Hello
I work with a lot of online forms, long, multi-page forms like applications and housing forms. We currently style all form fields to use monospaced fonts. Our biggest reason in the past for doing that was for consistency between browsers. Netscape 4.x was the biggest culprit. Our sites now check and kick out 4.x browsers. Some in our group want to stay with monospaced fonts, and some want to switch to allowing proportional fonts. Those in our group who are for monospace say: - It helps to separate (visually) what is the label and what is the question. - They think it looks bad when the question and the answer use the same exact style. - With monspace the size attribute and the maxlength attribute are in sync. They hate it when a text field scrolls just because you type in some upper-case "M" characters. - If you, for instance, use too many lowercase "l"s then your text ends halfway through the field. Those in our group who are for proportional say: - In cross-browser testing the differences in spacing (in page layout) for text, textarea, and select fields is minimal. - The form fields look better. - If you look around online most forms now use proportional fonts; it's accepted. Does anyone here have opinions about monospace vs. proportional fonts in long online forms? I happen to fall into the proportional group, myself, but, as you can see, the argument, "It looks better." is not very technically compelling. Thanks for your opinions. Similar TutorialsHi, I'm trying to build a modal box tool. Yes I know downloadable solutions exist, but wisely or not I'm building from scratch. And the javascript is fine, but on the CSS I feel I'm not quite doing it right. The HTML structure is pretty straightforward: PHP Code: <div id="PopUpBox" class="SinglePopUpBox" style="display:none"> <div class="TopBar"> <div class="CloseX"><a href="javascript:closePopUp()"><img src="Images/WindowCloseX.PNG" /></a></div> <div id="PopUpBoxTitle" class="Title"></div> </div> <div id="PopUpContainer" class="Container"><b style="color:#FFFF00">...Connectiing...</b></div> </div> and I just stick that on any underlying page with a button to make it appear. Ajax connects and injects the chosen content into PopUpContainer. Here's the issue. PopUpBox I want to be a percentage of the screen, to work on any size window. It appears in the middle via percentages. TopBar within that is a fixed height. And then PopUpContainer should fill the rest of the PopUpBox. So I set height=100% on PopUpContainer. But then it overflows the box by exactly the height of TopBar. At first I thought "hey, this sounds like a job for clearfloat" but that doesn't work. And it shouldn't, because floats aren't the issue. The problem I believe is going to 100% of a variable size. % of (% - x) to be more precise. So I "fix" this by giving PopUpBox enough padding-bottom to match the size of TopBar. This immediately feels bad, and I don't even know why. But it looks good, so I was prepared to shut up and accept it. However, IE7 (and probably 6, if I wanted to try it) don't play along. (Ditto IE8 in compatability mode, naturally.) They don't seem to respect that height=100% at all, and will make the Container shrink or bust out depending on what's inside. So what's the right approach to doing this? I'm quite willing to make moderate changes to my approach, but less happy to do stuff like add 12 pages of javascript to resize the box. CSS: PHP Code: div.SinglePopUpBox { color: #FFFFFF; border: 1px solid #CCCCCC; background-color: #000000; position:fixed; z-index: 100; left: 15%; top: 15%; right: 15%; bottom: 15%; padding:0px; padding-bottom:31px; /* Made to match height of TopBar + Container margin + Container Border + this border */ } div.SinglePopUpBox div.TopBar { background-color:#000000; background-image: url(Images/TopBar-Black.PNG); width:100%; height:26px; vertical-align:bottom; } div.SinglePopUpBox div.TopBar div.CloseX { float:right; margin-right:5px; } div.SinglePopUpBox div.TopBar div.Title { font-weight:bold; font-size:14px; padding-top:5px; padding-left:10px } div.SinglePopUpBox div.Container { background-image: url(Images/BackgroundBlue.JPG); overflow:auto; height:100%; padding-left:20px; padding-right:20px; margin-left:3px; margin-right:3px; border: 1px solid #CCCCCC; } Hi, I'm having difficult with learning forms and how to style them. I've gotten mostly what I am looking for just now I don't seem to be able to make adjustments: Adjusting the size of the text-window, wrapping the frame boarder around the fieldset. Those are my main issues, any help would be greatly appreciated. Hy- A pretty simple(?) question (I guess) Is there a way to format the look of radio buttons and checkboxes with css? e.g. to make it "fit" with this textfield style: style="font-size: 11px; font-family: Verdana; border-width: 1px; border-color: black;" regards Sheriff is there a way to disable the 3d shadowing effect on form fields? so i can just have a border. to start: this is my first post and i hope this forum is as helpful as the others i am a member of.. i have a basic text game i am working on and code is already layed out for me.. but i am looking to give the game my own style.. i have created the look i want in photoshop and sliced and sent over to dreamweaver but i am a noob and dont know how to get the things functioning.. at all pretty much everything can be set as the background except for the form but i want the blue gradient in input fields and images as buttons. i would like to have big font size in boxes and also have white letters.. also i want the whole centered x and y when viewer goes to page like i said: im a noob and just getting back into the web dev stuff and am pretty rusty so if anyone can help me out i will be SOOOOOO thankful!!! here is the link to the jpg.. let me know if you need the psd but i have 2 or 3 dif fonts in it that are not common fonts Code: http://i951.photobucket.com/albums/ad353/zac_exuro/Untitled-1-2.jpg Hi, I'm creating a form and for some reason I can't get rid of the space between each line of the fields. I've tried making the margin and padding 0 but no joy. Is it me or just browser bugs? Help appreciated PHP Addict Code: <div style="width: 350px; float: right;"> <div style="width: 100px; text-align: right; float: left; background: yellow;"> <label for="">field Name:</label> </div> <div style="width: 100px; float: left; background: orange;"> <input name="Address1" type="text" id="Ad1" value="$Address1" size="15" maxlength="25"> </div> <div style="width: 120px; float: right; background: blue;"> Error Message </div> <br /> <div style="width: 100px; text-align: right; float: left; clear: left; background: yellow;"> <label for="">field Name:</label> </div> <div style="width: 100px; float: left; background: orange;"> <input name="Address1" type="text" id="Ad1" value="$Address1" size="15" maxlength="25"> </div> <div style="width: 120px; float: right; background: blue;"> Error Message </div> <br /> <div style="width: 100px; text-align: right; float: left; clear: left; background: yellow;"> <label for="">field Name:</label> </div> <div style="width: 100px; float: left; background: orange;"> <input name="Address1" type="text" id="Ad1" value="$Address1" size="15" maxlength="25"> </div> <div style="width: 120px; float: right; background: blue;"> Error Message </div> </div> I've seen some text inputs with pretty snazzy styling, such as borders with rounded corners. How is this done? I have a form with several input and option fields, can I apply a separate background color to an individual input field possibly by name or id ? Code: #form1 INPUT, OPTION { background-color: #999999; } Is it possible to differentiate between various types of input field, e.g. assign a width to text inputs but leave buttons to find their own width based on content. I know I can do this by assigning certain elements a class but I'd prefer not to have to do this. Thanks Greetings! Maybe it's a newbie question, but I can't find out why form fields don't get vertically centered when rule height: 4em; line-height: 4em; is applied on them, they are inline elements, aren't they? In FF applied correctly, not so in IE. Please take a look at: http://147.32.113.143/biotest/Sourc..._LookUpTerm.php Hi, I am having trouble clearing labels and fields. I have set up my labels to float left and my fields to float left. When i have more than one set of label and field, they do not align underneath each other. Please could someone suggest the best way to clear the label and field so the next row will display correctly? Thanks Is it possible to expand a table with DIV's using CSS hidden/visible? If I select an option from a select field in one row, to have a hidden select field appear in the row directly below, moving the contents directly below down a row? Expanding the table when a hidden row becomes visible. Or should I just use DIV's and forget about using the table format? I'm stumped. Cannot find a solution here. Is it possible to vertically align a form field inside a DIV in IE6? It works fine everywhere else. (Big shock...) Thank you for any help you can give. I've resolved to using tables temporarily. Ughhh. Here's a snippet of the CSS: Code: body { background-color: #e2e4d7; background-image: url("../images/fade_top.gif"); background-repeat: repeat-x; margin: 0; padding: 0 } #wrapper { margin: 12px auto; width: 796px } #top { background-image: url("../images/main_top.gif"); background-repeat: no-repeat; width: 796px; height: 8px; overflow: hidden; vertical-align: bottom } #main { background-image: url("../images/main_back.gif"); background-repeat: repeat-y; width: 796px; overflow: hidden } #header { background-image: url("../images/header_back.gif"); background-repeat: no-repeat; width: 796px; height: 262px } #nav { margin-right: 8px; margin-left: 8px; width: 780px; height: 60px } #nav ul { list-style-type: none; margin: 0; padding: 0; width: 780px } #nav li { float: left } #nav li a { display: block; padding-top: 60px; height: 0; overflow: hidden } ... #banner { margin-right: 8px; margin-left: 8px; width: 780px; height: 202px; overflow: hidden } #bannerLeft { background-image: url("../images/banner_logo.gif"); background-repeat: no-repeat; position: relative; width: 316px; height: 202px; float: left } #searchBox { line-height: 53px; text-align: center; position: absolute; top: 149px; width: 316px; height: 53px } #searchField { margin: 0; padding: 0; width: 196px; vertical-align: middle } #searchButton { margin: 0 0 0 6px; padding: 0; vertical-align: middle } #bannerRight { background-image: url("../images/banner_photo.jpg"); background-repeat: no-repeat; width: 464px; height: 202px; float: right } ... And here's a snippet of the HTML: Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html lang="en" xml:lang="en" xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="content-type" content="text/html;charset=iso-8859-1" /> <title></title> <link href="css/stylesheet.css" rel="stylesheet" type="text/css" media="all"/> </head> <body> <div id="wrapper"> <div id="top"></div> <div id="main"> <div id="header"> <div id="nav"> <ul> ... </ul> </div> <div id="banner"> <div id="bannerLeft"> <form action="http://www.google.com/search" method="get"> <input type="hidden" name="ie" value="UTF-8"> <input type="hidden" name="oe" value="UTF-8"> <input type="hidden" name="domains" value="http://www.whmca.com"> <input type="hidden" name="sitesearch" value="http://www.whmca.com"> <div id="searchBox"> <input id="searchField" type="text" name="q"><input id="searchButton" name="btnG" type="image" src="images/search_bt.gif" alt="Search" height="14" width="42"> </div> </form> </div> <div id="bannerRight"></div> </div> </div> <div id="body"> ... </div> </div> <div id="bottom"></div> <div id="copyright"> ... </div> </div> </body> </html> is this possible with CSS? So when the carat is focused on a form field the field is highlighed maybe by changing the border color... or background color. very much like the macromedia support site. http://www.macromedia.com/support/ I have a feeling though... it might involve a bit of javascript? Cheers in advance Rob Is there a simple way of applying a CSS style to only the form fields that are empty? I searched online and found this but doesn't seem to work. Code: input[value=""] { background-color: #FFFF66; } any other ideas? Hi, Please see http://lbclibrary.org/addtoinquiry.php (scroll down a bit to see the form) What I want to do is, when the user selects "I am a member of ..." or "I want to become a member of..." the form fields in the OTHER cell should become readonly (i.e. should not allow input). Is it possible to make ALL the form elements in one <td> cell as readonly? Further, is it possible to change their background colors to say light grey? Then, when you select another radio option, that cell becomes writable and the other cell becomes readonly. Thanks a lot! can I load a special font to my server and then call to it through css? If I want to use the font Made_In_China.tff can I actualy load it to my server and then call to it through css? Nick I've been looking at some CSS templates over at the Yahoo Developer Network. Link: http://developer.yahoo.com/ypattern...hp?pattern=grid They define font sizes as percentages (13 pt. is about 100%), and I had never seen this. See he http://developer.yahoo.com/yui/fonts/index.html Is this common? Uncommon? Is there a reason I haven't seen it before, or am I blind? Also, in general, have anyone here used these templates as a basis for anything? Ive seen some sites using fonts i dont have on my computer how is this done and whats it called ? any help would be great. |