...

View Full Version : How to make different layers in table cell?



kippie
07-07-2003, 05:49 PM
In the HTML below I made a table structure in order to get images in the center of the screen irrespective of the screen resolution of the user. Now I wonder if I could use different layers in the central table cell in order to get images and text above/under each other. For example I would like to have layer1 on top of layer2 instead of the two layers beside each other (as is in the HTML below). But I don't know how to do this. Can anyone help?

This is the HTML:
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=iso-8859-1">
<meta name="generator" content="Adobe GoLive 4">
<style type="text/css"><!--
#layer1 {z-index: 1 }
#layer2 {z-index: 2 }
-->
</style>
</head>

<body bgcolor="white" text="black">
<table border="1" bordercolor="blue" width="100%" height="100%">
<tr height="10%">
<td height="10%"> </td>
</tr>
<tr height="80%">
<td align="center" valign="middle" height="80%">
<table border="1" bordercolor="red" width="80%" height="100%" cellpadding="0" cellspacing="0">
<tr>
<td align="center">
<div id="layer1">
<img src="image1.jpg" width="100" height="100">
</div>
<div id="layer2">
<img src="image2.gif" width="150" height="150">
</div>
</td>
</tr>
</table>
</td></td>
</tr>
<tr height="10%">
<td height="10%"> </td>
</tr>
</table>
</body>
</html>

Kippie

Mr J
07-07-2003, 10:02 PM
I copied your code and image1 was above image2 ?

kippie
07-08-2003, 01:04 PM
Solved it already. thanks Mr. J.

Kippie



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum