Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
Padding / margin problem with textfield in Safari, Chrome
Old 07-13-2010, 11:28 AM Padding / margin problem with textfield in Safari, Chrome
pealo86's Avatar
Super Spam Talker

Posts: 876
Name: Matt Pealing
Location: England, north west
Trades: 0
See the text fields on this page:
http://bit.ly/aJb439

Notice how the text inside them appears lower down in Safari and Chrome, whereas in other browsers it sits nicely in the centre (the vertical centre that is).

It's annoying because it's all down to IE too! Seeing as it can't add background images to textfields properly, I had to throw a lot of <div>'s in there and apply the background image to them.

The only way I can fix it in Chrome and Safari is by changing the top margin one the associated elements like so:

Code:
form div div input, form div div textarea {
-moz-background-clip:border;
-moz-background-inline-policy:continuous;
-moz-background-origin:padding;
background:transparent none repeat scroll 0 0;
color:#616261;
font-family:arial,helvetica,sans-serif;
font-size:18px;
height:30px;
margin:0 10px 0;
width:430px;


}
But then it messes up in the other browsers!

Is there a way I can fix this?

Cheers
__________________

Please login or register to view this content. Registration is FREE
pealo86 is offline
Reply With Quote
View Public Profile Visit pealo86's homepage!
 
 
Register now for full access!
Old 07-16-2010, 12:41 AM Re: Padding / margin problem with textfield in Safari, Chrome
shivaji's Avatar
Ultra Talker

Posts: 321
Trades: 0
Try to define line-height: 30px; (or less) to see what is happened.
__________________

Please login or register to view this content. Registration is FREE
- uncommon free scripts

Please login or register to view this content. Registration is FREE
- Städte, Sport, Party, Gourment, Apartments, Hotels
shivaji is offline
Reply With Quote
View Public Profile Visit shivaji's homepage!
 
Old 07-18-2010, 02:41 PM Re: Padding / margin problem with textfield in Safari, Chrome
pealo86's Avatar
Super Spam Talker

Posts: 876
Name: Matt Pealing
Location: England, north west
Trades: 0
I tried that but it didnt work

Luckily I've managed to figure it out! I simply removed the height property from the input field and moved it to 'form div div' instead.

thanks anyway
__________________

Please login or register to view this content. Registration is FREE
pealo86 is offline
Reply With Quote
View Public Profile Visit pealo86's homepage!
 
Reply     « Reply to Padding / margin problem with textfield in Safari, Chrome
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 2.27803 seconds with 12 queries