ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have set all frames to be non scrolling, however I want to enable the browser to scroll the page as a whole, just like the LinuxQuestions page I'm typing in now.
I was reluctant to reveal my ignorance, and anticipated my approach may be unorthordox. Thank you for you deplomacy. I am looking at tutorials on boxmodels, but achieving the structure described above using css boxes eludes me so far.
I have set all frames to be non scrolling, however I want to enable the browser to scroll the page as a whole, just like the LinuxQuestions page I'm typing in now.
Firstly, ondoho is right, you probably don't want to use frames.
Even if you achieve the desired layout with frames, you make the website largely inaccessible to your visitors and kill your search engine ranking before it is born. The basic problem with frames is that they break the definition of the page and make the URL (Universal resource locator) no longer universal, nor useful as a locator.
So, since you must spend some time learning in any event, learn first Why Frames Suck and Why Frames Are So Evil, and search for many more explanations if these are not clear to you. Also note that frames are not supported at all by the XHTML Strict specification (requires special Frameset DTD as I recall).
But the short answer: If you want people to find and use your website - don't use frames.
Now, you can do your layout using html tables, but you are still much better off using non-table html block elements such as divs and corresponding CSS rules to get what you want.
I don't have a favorite link, but a quick search turned up this page which looks basic, complete yet easy to read.
Some suggested search terms would be "css multi-column layouts", "css tutorial", "html basics", etc.
And of course, once you have learned the basics but are still having trouble, ask here at LQ!
Thank you astrogeek for the link, very interesting. I had not found anything that usefull. Now, nothing I can find tells me how to add content to a box other than text and images. Can the box contain an html page? Using the code from the link in your reply, this does not work:
well that would be a frame, wouldn't it?
i think i know where you stand and i myself stood quite recently at the same point.
frames seem to be a good solution for beginners - but really they're not.
better to re-think the layout from the very beginning.
(i ended up using some php, it's not that hard)
but, it is possible to embed content in many ways.
you can always look at w3schools.com, and their html and css tutorials and tag references.
Your attempt to separate the page into separate HTML documents should be done server-side. PHP would work fine, and it's a very lightweight solution if that's all you want to do server-side. You just use the PHP include keyword to assemble your HTML fragments.
Well I have studied various HTML/CSS tutorials, and created a format without frames, but I have arrived at a road block. May be I'm on the wrong track again (and this might not be the right place to post, but I feel it's easier to follow my thread without need for elaboration.
I have a title bar along the top, a menu column on the left, with a main window under the title and right of the menu. How do I tell the menu to change the display in the main window, using separate html files? In other words how to specify the main window as the target. Below are my html and css files
The first frameset has 2 columns with * for dimension. It also has only 3 columns. (
If you remove the first * in <frameset cols="*,180,860,*" border="2"> you are likely to get everything in 1 page and solve the problem while waiting to see how to implement it through CSS.
Without server-side coding? You link to another HTML file where everything is the same except for the contents of the "main window."
this is exactly what i was talking about.
i guess everybody thinks: i don't want to rewrite the menubar into every page. let's use frames instead...
but:
- seperate html files with the same menu over and over again are actually pretty fast to load.
- if you have good css, the menu is just a list with links - no biggie.
- include the menu into your page with server-side coding (e.g. php) or javascript (look at w3schools.com/website) or...
about your CSS: use id's sparingly, use classes instead.
and one last time: boxmodel ftw!
'nuff said. the net is full of helpful tutorials.
include the menu into your page with server-side coding (e.g. php) or javascript (look at w3schools.com/website) or...
If you're using Javascript then you don't use it to load the menu (unless you're Google and you're loading the menu from a different physical location as a speed optimization). You use it to load the contents of "main".
i didn't look at op's code deeply, but it is possible to make a simple javascript navigation menu, see here: http://www.w3schools.com/website/web_spa_navigation.asp
(that way one would have to write the nav menu only once)
i don't understand why google should come into it?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.