hello can someone help me please? I'm building a website and I want to know if one can use tables instead of frames? how is it possible (using tables) to make the links in the "left menu" "left row or cell" to load into the "right row or cell" and also how to make commands inside the table? like I put <.center> and it didn't work..of course w/o the .
and last but not least Is it true that tables are better to navigate with then frames?
I would really appreciate some answers
Below is a sample (very alterable) of a "mouseover-like" menu that is compact and simple.
The <style> below can be cut from the code and placed in a linked external CSS file (and referenced on every page - which is only 1 line of code), while the <div> can be unifromly positioned on every page in your site.
Even if you don't use this.... please don't use Frames! (the worst!).
and that will palce a table with three columns on your site andthen you can put more tables inside of each cell but DONT. I dont reccomend that because now everything is moving to css. I used to be big on tables myself but I dont think I will use them for layout anymore because they are a thing of the past and are not very professional.
Well all of you guys have been bombarding me with css-ism that I think I am starting to see how affective it can be,.I have not used it yet for layout ( I have not started any sites for a long time) but I would like to get some css practice for layout because I already use it for just about everything else. I mean I use it on links scroll bars borders etc.
Hey khaki, I was looking through you code and saw that line. You can just use "padding: 4px;" and the 4px padding will be used on all sides. I also don't know why you used "background-color: transparent;" See if it makes a difference with it taken out in both of the places you have it. I haven't really used transparent yet, so I might not be the best to point it out either.
1. Ah, the sound of a person who uses nested tables.
2. Tables are good for what they are intended for which is tabular data. Tables for layout is bad. Why? Because they lead to things like nested tables. Tables screw over browsers for people with disabilities. Tables were used before CSS came along and made life a whole lot easier. As an example, create a large website without using CSS for layout. Now, go and change around your website even a little bit, ie background colors, link colors, the position of your menu. Was that a pain? You bet it was. Now create the same site using CSS and then make the same changes. If done correctly, all you have to do is change your external CSS file and you are done. This is what is meant by seperating style from content, and it makes your web page code a whole lot easier to weed through.
3. Adding the DOCTYPE tells the browser what version of HTML/XHTML you are using so it knows how to understand your code. What happens if you leave it out? Your browser then goes, "this person doesn't know what they are doing so I am going to assume certain things." This also means that it may try to read your code based on older versions of HTML than what you are using. Putting it another way. Let's say I code in a programming language like Java. I create some variables, but don't initialize them. Does this mean my program won't work? No, but there is a chance that something funky might happen, hence it's always good it initialize variables and it's always a good thing to add a DOCTYPE. Plus, you can't validate your page against W3C standards without one.
4. I figure I'll handle the validation question before you ask it. Why do it? Because it is what the web is moving towards and not away from. It helps teach you proper coding. It also make a browser's life easier. Plus, it helps in creating fewer cross browser issues.
but i really want to know is HOW TO GET THE LINKS ON THE LEFT SIDE OF THE MENU TO WORK...TO LOAD ON THE RIGHT SIDE OF THE PAGE?? HOW CAN I DO THAT..THESE ARE JUST MENUS AND CELLS .STYLES AND STUFF I WANT TO KNOW HOW TO MAKE THE LINKS IN THE MENU WORK...SO THEY CAN LOAD ON THE RIGHT SIDE ..OR THE MAIN PAGE?? HOW DO i DO THAT?
I WANT TO KNOW HOW TO MAKE THE LINKS IN THE MENU WORK...SO THEY CAN LOAD ON THE RIGHT SIDE ..OR THE MAIN PAGE?
The reply was already posted
Other people's replies give you a way to have navigation links on the same page as you contents. Of course you will have to make changes to all pages on your website to include this.
For example, if you had a webpage (mypage.html)
and navigation page (body of which is
<p><a href="...">Link 1</a></p>
<p><a href="...">Link 2</a></p>
<p><a href="...">Link 3</a></p>
actually... it's not better.... because it relies on tables for laying-out navigational links.
The example I provided (with it's missing elements... i know... i know... it was stripped-down for space considerations. sorry. but thanks for clarifying all of the ommitted/messy stuff nkaisare and spufi!)...
Anyway, that solution can have the background change as well.
Just change: background-color: transparent;
to background-color: green;
Like I originally said... this is "very alterable".
(and does not rely on tables!)
As to mararies5's concern about how this doesn't change the right side of the page:
If you don't use Frames pages (and you really shouldn't), then you have the options of using iframes or putting this very compact and small menu on every page (which will always mean that it will require the creation of at least one less page than if you had used Frames in the first place).
Personally, I'd suggest placing the <style> in an external file, write specific <div> coordinates for the menu, and just place it on every page along with each page's unique content.
If you have ASP capabiltity, just stick it all in one include file and reference it with just one line on every page: <!-- #include file="entireMenu.inc" -->
and any changes that need to be made to the menu and/or style (site-wide!) can be done from the single include file.
That's one opinion (and how I have been writing (and re-writing) my pages to-date).