Solved

CSS Inline vs Block Problem

Posted on 2009-05-06
5
96 Views
Last Modified: 2013-07-30
I cannot get my buttons to display as anything but as a block. Any idea why this won't display as an inline element? Thanks!
#buttonAccounting, #buttonFood, #buttonEquipment, #buttonGalley, #buttonCabinSys,

#buttonPassenger, #buttonDisability, #buttonCoats, #buttonIFE, #buttonConnectingInfo

{

	display:inline;

	height: 175px;

	width: 175px;

}
 

#buttonAccounting

{

	background: url(../images/e4button_money_regular.png) no-repeat;

}
 

#buttonAccounting:active

{

	background: url(../images/e4button_money_pressed.png) no-repeat;

}
 

/************************************************** HTML ****************************************************/
 

<a href="pages/accounting.aspx" id="buttonAccounting" onmousedown="javascript:PageMethods.downClick(5, 0);" onmouseup="javascript:PageMethods.upClick(5, 0);"></a>

Open in new window

0
Comment
Question by:ckehoe
  • 2
5 Comments
 
LVL 13

Expert Comment

by:Brian Withun
Comment Utility
It's inline for me.  I don't think I did anything particular to it...
<html>

<head>

<style>
 

#buttonAccounting, #buttonFood, #buttonEquipment, #buttonGalley, #buttonCabinSys,

#buttonPassenger, #buttonDisability, #buttonCoats, #buttonIFE, #buttonConnectingInfo

{

	display:inline;

	height: 175px;

	width: 175px;

    border: 1px solid #333;

}

 

#buttonAccounting

{

	background: url(EE_Badge.gif) no-repeat;

}

 

#buttonAccounting:active

{

	background: url(EE_Badge.gif) no-repeat;

}
 

</style>

</head>

<body>
 

<p> this is my 

<a href="pages/accounting.aspx" id="buttonAccounting" onmousedown="javascript:PageMethods.downClick(5, 0);" onmouseup="javascript:PageMethods.upClick(5, 0);">my link</a> button inline </p>
 

</body>

</html>

Open in new window

inline.jpg
0
 
LVL 42

Accepted Solution

by:
David S. earned 500 total points
Comment Utility
0
 
LVL 42

Expert Comment

by:David S.
Comment Utility
@bhwithun

In quirks mode, IE wrongly applies the width and height properties to inline elements.
0
 
LVL 58

Expert Comment

by:Gary
Comment Utility
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Creating a CSS block that only applies to printing By default, all of your CSS applies to every possible view of your page - whether on screen, printed, landscape, touch-screen, or whatever.  You can, however, add CSS that only applies under certai…
So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…

744 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

8 Experts available now in Live!

Get 1:1 Help Now