Click to See Complete Forum and Search --> : Can I do this without 'pure CSS'?
jammer20002
10-02-2004, 06:08 PM
Can someone tell me if I can have a navigation on the right hand in the following link, WITHOUT using pure CSS:
http://www.t-2.at/index.html
When I mean 'pure CSS' I mean that I'm still learning...
I'm still reading up on floating etc.
I do know the basics.
I want to use tables.
Can I just have table and have a floating element?
I've tried without much success.
When I do it, there seems to be a big space left at the top of the page. :(
Any help would be appreciated.
Thanks.
Jam
Charles
10-02-2004, 07:10 PM
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Content-Script-Type" content="text/javascript">
<meta name="Content-Style-Type" content="text/css">
<title>Example</title>
<style type="text/css">
<!--
#content {margin-right:10em}
#navigation {
width:9em;
position:absolute;
top:0;right:0;
}
#navigation ul {
list-style-type:none;
margin:0;
padding:0;
}
#navigation ul li {margin:1em 0}
-->
</style>
</head>
<body>
<div id="content">
<h1>Amo ahiplam abresmat</h1>
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipitlobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Nam liber tempor *** soluta nobis eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. Typi non habent claritatem insitam; est usus legentis in iis qui facit eorum claritatem.</p>
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipitlobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Nam liber tempor *** soluta nobis eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. Typi non habent claritatem insitam; est usus legentis in iis qui facit eorum claritatem.</p>
</div>
<div id="navigation">
<ul>
<li>fee</li>
<li>fie</li>
<li>foe</li>
<li>fum</li>
</ul>
</div>
</body>
</html>
jammer20002
10-02-2004, 08:46 PM
THANKS for the reply. :)
I kinda managed to achieve what I wanted.
What I wanted was to have a box on the top right going over a table.
I thought that the effect looked really nice.
I've added a few bit to the code to give me what I want.
And it kinda works.
I added some code to make the 'navigation' class have a box round it and have made it be a certain number of pixels in.
This comes out OK on a 1024x768 screen.
I've tested on a 1280x1024 screen... and it's not how I want it to be.
I want the 'navigation' to stay over the table on the right hand side.
When I tried initially, I traide to make it so that the 'navigation' was part of the table and tried to make its placement relative.
I'm still a bit confused how I can make it so that the 'naviagtion' will be over the same place of the table, regardless of the monitor screen?
Any ideas?
Here's the ammended code I made from your posting:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Content-Script-Type" content="text/javascript">
<meta name="Content-Style-Type" content="text/css">
<title>Example</title>
<style type="text/css">
<!--
#content {margin-right:10em}
#navigation {
width:9em;
position:absolute;
top:0;
right:0;
border: 1px dashed #333333;
margin-right: 300px;
margin-top: 40px;
background-color: #FFFFFF;
}
#navigation ul {
list-style-type:none;
margin:0;
padding:0;
}
#navigation ul li {margin:0em 0}
.myTable {
border: 1px solid #CCCCCC;
}
-->
</style>
</head>
<body>
<div id="content">
<table width="500" align="center" class="myTable">
<tr>
<td>aab</td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
</table>
<h1> </h1>
</div>
<div id="navigation">
<ul>
<li>fee</li>
<li>fie</li>
<li>foe</li>
<li>fum</li>
</ul>
</div>
</body>
</html>
IncaWarrior
10-02-2004, 09:30 PM
It looks really nice now and it changes to fit the screen size (using opera) Don't do something stupid like put a useless table in there, nothing's tabular so you don't need a table
jammer20002
10-02-2004, 11:14 PM
Originally posted by IncaWarrior
It looks really nice now and it changes to fit the screen size (using opera) Don't do something stupid like put a useless table in there, nothing's tabular so you don't need a table
I'm confused as to what you're saying?
I'm still learning CSS.
And I'm working on a project that needs completing ASAP.
So, I don't really have any choice use tables.
Yes, I've read about the whole issue of using CSS... and I will do so when I learn. :)
Is there any feasible way that I can do what I want WITH using a table?
Charles
10-03-2004, 02:18 AM
Originally posted by jammer20002
Is there any feasible way that I can do what I want WITH using a table? No, because if you use a table you'll make your page not work on some Braille and audio browsers.
And don't be such a control freak. Your goal should be something that looks good as things move around on different sized screens,
PeOfEo
10-03-2004, 09:25 AM
CSS should not take that long to learn either. I can remember when I migrated from tables to css. It took me a little longer to do my projects because I sort of learned as went, but it did not take me long at all to get good with css.
jammer20002
10-03-2004, 09:43 AM
thanks for the feedback.
i do fully intend to migrate to css and leave the dark side.
but for now... i will have to stick to tables.
i need to do work to show a client by tomorrow.
and erm... so far... i haven't even started coding the first line. :)
IncaWarrior
10-03-2004, 10:24 AM
Well then your best bet would be CSS since it's faster and already there