Problem styling image to fit in DIV for mobile devices

Posted on 2012-08-22
Last Modified: 2012-09-04
This URL:

Click any of the orange names on that screen. Then close the width of your browser to less than 35em to flip it into "mobile mode". The logo is too tall. Here is the non-mobile CSS:


Here is the mobile CSS:


I don't understand why the container DIV is not expanded along with the logo. Here is the HTML:

<div id="cemeterylogo">
<a href="default.asp"><img id="cemeterylogoimg" src="15/cemetery-logo.jpg" border="0" /></a>

Would appreciate any advice. Thank you!
Question by:bbdesign
    LVL 53

    Expert Comment

    When I click on the orange names all I get is a fatal server error.

    LVL 53

    Expert Comment

    The other thing is, if you are going to use modern mobile technology, you might want to upgrade the 20th century code to something a little closer to current standards.

    LVL 11

    Expert Comment

    Well on my firefox everything is fine. Maybe you tell us what browser you're using, please.

    Accepted Solution

    In the meantime, I was able to solve this. My styling was a bit off, I had some styles on the DIV that should have been on the IMG and vice-versa. Thank you for checking, you probably loaded it after I had already fixed it.

    Author Closing Comment

    Found solution on my own by analyzing CSS code.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    Suggested Solutions

    Most web designers often experience crossbrowser issues during interface design / development.  On common problem is with Internet Explorer due to its rendering discrepancies between previous versions.  Here are some techniques I use to help avoid c…
    Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
    In this tutorial viewers will learn how to define a gradient in CSS. Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Gradient. Define the background as "linear-gradient(to right, #ee3668, black)". Ensure you …
    In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…

    754 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now