Ask your WordPress questions! Pay money and get answers fast! (more info)

iPhone CSS

  • SOLVED

Hello!

I need some help with how the 3 boxes on the second part of the home page (the ones that have the tan icons above them) are laying out.

I want them to all line up underneath of eachother, on the iphone. Can someone help?

Thanks!

http://www.counselinginchapelhill.com/

Answers (2)

2012-07-13

webGP answers:

Hello!

Try to add this code:


@media only screen and (max-width: 480px) {
.thumbs {
margin: 0 auto;
width: 250px !important;
}
}


above the line 198 ("#homeBanner h2 {") of your header.php file.


ohlivia13 comments:

You want me to add CSS in a php file?


webGP comments:

I don't know where exactly you should put my code, maybe you have a function which print CSS in <head> section, but if you open a source of your home page, you can see, that between lines 42 and 388 you have a piece of CSS code, add a piece of my code above the line "#homeBanner h2 {", whenever it's prin't. If you provide me an access, or files I can find the right place.

2012-07-14

Hai Bui answers:

Try adding this in your css:

@media only screen and (max-width: 480px) {
#featuredPages .thumbs {
margin: 0 auto !important;
width: 250px !important;
}
#featuredPages .thumbs .page.small {
width: 100% !important;
margin: 0 !important;
}
}


I don't know why you have a lot of css in html code, that's why we have to use so many "!important" here to override them.


ohlivia13 comments:

Worked like a charm!

I'm entering most of my edited CSS into a box for Custom CSS within the Theme Options. Would this be why there is CSS in the HTML?

Could you point me somewhere where I can read more about this?

Thanks so much!