# Webdesign: frames/css help

1. Sep 8, 2005

### neurocomp2003

sup, does anyone know if you can stick frame styles in a css file?
best
neurocomp2003

2. Sep 8, 2005

### honestrosewater

Do you mean borders? I know how to do borders.

3. Sep 8, 2005

### neurocomp2003

no i'm talking about frames. and placing their attributes in a css file like you would any other attribute.

4. Sep 8, 2005

### dduardo

Staff Emeritus
Ek, frames :yuck:

I don't think you can stick multiple frame styles into one css file. The reason being is that your dealing with multiple DOM stuctures.

5. Sep 8, 2005

### neurocomp2003

dduardo. quick question.
i have 5 frames on my main page..wchih i will be constantly switching the contents of 3 of them(say over 100-1000pages). The reason I stuck with frames is because its easier and i don't have to repaste alot of organization structure to maintain it.

ooooooooooooo
ooooooooooooo
xx...............xx
xx...............xx
xx...............xx
---------------
ooooooooooooo
ooooooooooooo

Thats the gist of what it looks like.
Now if i really wanted to move to tables...will it be easy? will the basica layout be easy to manipulate as a table(because the first time i tried, i really messed things up with the alignment. Note that the title/end will be the same page but the TOC/main/nav bar will change. IF your willing to take a look at the basic structure. I can email it to you if you can provide your remail.

6. Sep 8, 2005

### dduardo

Staff Emeritus
Ek, tables for layout :yuck:

You should do something like this:

Code (Text):

<div id="content">
<div id="leftContent"></div>
<div id="centerContent"></div>
<div id="rightContent"></div>
</div>
<div id="footer"></div>

See this example:

Then stick all your content inside the div blocks.

Last edited: Sep 8, 2005
7. Sep 8, 2005

### neurocomp2003

thanks fro the example but i don't think its waht i'm looking for.
Because looking at the source code for that: If i wanted to swap images/code/formula..constantly...i'd have to duplicate the same page with the rest of the contents being the same and only one line changed for image...because i'm unfamiliar with coding in javascript....i don't even know if you can do that put a place marker on a region where the contents is determined by what the user is looking at and not have to duplicate teh contents.

8. Sep 8, 2005

### dduardo

Staff Emeritus
You can follow this code to do client-side includes:

http://www.boutell.com/newfaq/creating/include.html

But the prefered way is to use server-side includes.

Who is hosting your website? If they support php then it is just a matter of doing something like this:

Code (Text):

9. Sep 8, 2005

### neurocomp2003

yeah i think i'm a long way from learning php =] but i'll look into it.
thanks for the advice though. Its much appreciated. As for hosting either a friend or rogers. Oh yeah and thanks for the above link on clientside stuff.

oh one more question...what would i use to put math symbols on a website?
Latex/mathematica/mathxhtml(i think its called)?

Last edited: Sep 8, 2005
10. Sep 8, 2005

### dduardo

Staff Emeritus
You'll want to use MathML if your doing pure client based webpages. Unfortunetly, the code looks nasty:

[/code]
$<mrow> <mi>x</mi> <mo>=</mo> <mfrac> <mrow> <mrow> <mo>-</mo> <mi>b</mi> </mrow> <mo>&PlusMinus;</mo> <msqrt> <mrow> <msup> <mi>b</mi> <mn>2</mn> </msup> <mo>-</mo> <mrow> <mn>4</mn> <mo>&InvisibleTimes;</mo> <mi>a</mi> <mo>&InvisibleTimes;</mo> <mi>c</mi> </mrow> </mrow> </msqrt> </mrow> <mrow> <mn>2</mn> <mo>&InvisibleTimes;</mo> <mi>a</mi> </mrow> </mfrac> </mrow>$
[/code]

It is much nicer to do using latex:

x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}

$$x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}$$

But you'll need to do the parsing server-side.

11. Sep 8, 2005

### neurocomp2003

dduardo: do you know of any book that teachs that stuff you listed.
Again thank you for all the help

12. Sep 8, 2005

### dduardo

Staff Emeritus
13. Sep 8, 2005

### exequor

neurocomp2003, I seriously recommend that you use one of the scripting languages out there (preferably php). Frames? I really hate frames, they do have their purpose though.... but 5 on a page...

14. Sep 8, 2005

### neurocomp2003

yes...unfortunately i'm a novice at this so frames is easiest...i haven't learned the include style that dduardo referenced to above. And i'm not ready to learn becuase there is quite a bit more fundamentals you gotta learn before you reach tthat point.

With frames...i can just easily remove a webpage and replace it with the one demanded on by a click. And its going to be a website of maybe 100-1000 pages of content with maybe 4-5 colours schemes. and different subject TOC.

15. Sep 10, 2005

### neurocomp2003

DDuardo: just wanted to thank you again. The link above with teh clientside
includes works like a charm...its a bit more hassle(quite a bit of tweaking) then frames but hopefully i won't have any issues with mozilla using includes like i did using frames(mozilla screwed up my dir. tree or IE has defaults that auto link perfectly). Now i have both to work with, but will eventually choose one and can go show my buddy whose suppose to be working on thise with me and let him choose.

The only problem i have with client side is that for every page of content I want I need a duplicate page to hose the structure of the layout unless of course I dump the content into the same page which i don't really want...but meh.

EDIT: bah ran into a second problem...if you have a directory tree and are including files from different folders. The links of those files are not relative to them but to the host page that has the includes... guess i'll have to restructure the folders

EDIT: argh is there a reference that tells you what not to use in IE becasue of other browsers like mozilla. My scrollbar technique doesn't work in mozill.a
again i'm grateful for your help.
Best

Last edited: Sep 10, 2005