473,396 Members | 1,676 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

why doesn't vertikal-align work with <h1> in css?

hello guys,
my problem is, that the haedline in my table-cell goes on the top and
not in the middle. in my css the vertikal-align: middle doesn't work
with <h1>. is this normal. what can i do? please help!

F. Engel
Jul 20 '05 #1
3 6729
F. Engel wrote:
hello guys,
my problem is, that the haedline in my table-cell goes on the top and
not in the middle. in my css the vertikal-align: middle doesn't work
with <h1>. is this normal. what can i do? please help!

F. Engel

<style type="text/css">
@media screen{
h1{
line-height:4em;
vertical-align:middle;
font:2em Arial,Helvetica,sans-serif;
}
}
</style>

--
Anne van Kesteren
http://www.annevankesteren.nl/
Jul 20 '05 #2
"F. Engel" wrote:
hello guys,
my problem is, that the haedline in my table-cell goes on the top and
not in the middle. in my css the vertikal-align: middle doesn't work
with <h1>. is this normal. what can i do? please help!


Could it be a spelling problem? vertikal should be vertical

--
Klaus Johannes Rusch
Kl********@atmedia.net
http://www.atmedia.net/KlausRusch/
Jul 20 '05 #3
fl***@comictrash.de (F. Engel) wrote:
my problem is, that the haedline in my table-cell goes on the top and
not in the middle. in my css the vertikal-align: middle doesn't work
with <h1>. is this normal. what can i do? please help!


Does your CSS actually say vertikal-align? The correct property is
vertical-align.

Have you applied the property to the <h1> or to the <td>?
vertical-align only applies to inline elements or to table-cell
elements. <h1> is a block level element and so it does not apply.
Apply it to the <td> to affect the contents, including the <h1>.

However, what's a <h1> doing inside a table cell anyway? That's pretty
funny data. Sounds like your using a table for layout.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>
Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: KubixKiller | last post by:
Hello, I use the following XML-file to store some useless facts I want to display using PHP. I wrote some PHP code to generate HTML, because I do not have any knowledge of stylesheets etc etc. ...
37
by: Prisoner at War | last post by:
Actually, it doesn't have to be a blockquote...but I'm at my wits' end: I want to make bold several lines of text which have a pair of <br /tags between them...seems like the <b></bdo not "carry...
13
by: daniam | last post by:
I am working on write a program that reads and writes from the barcode my problem when writing (send command to barcode) I read in pdf manufacturer barcode that the command of capturing the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.