How would I do this in Dreamweaver....

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Alright, so I have a site title, and a navigation bar down the left side of the main page. There's several options that can be selected from that navigation bar. How do I make it so that if the user clicks one of those options they're taken to that page, but the navigation bar stays on the left, and the site title stays at the top of the screen????


Something like Anandtech...where the Categories navigation bar stays, as does the Anandtech logo along the top, but if you click say, Off Topic from the navigation bar, the Off Topic forum loads in the main 'pane' of the site.


Is that just a CSS style? It seems like a pain in the ass and awfully inefficient to have to have the logo for my site and the navigation bar copied onto every single page of the site I'm making.
 

blackllotus

Golden Member
May 30, 2005
1,875
0
0
I think you can do this by creating multiple frames. Put the logo/menu/etc in one frame and have the links target the other frame where you want the information to load
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
well yes, but I'm not sure how to do that exactly...I have the frames set up, I'm just vexed by the step of actually having the different buttons link to different .html files, but having those files load in the main 'pane' of the site where I want them to.
 

blackllotus

Golden Member
May 30, 2005
1,875
0
0
Originally posted by: Accipiter22
well yes, but I'm not sure how to do that exactly...I have the frames set up, I'm just vexed by the step of actually having the different buttons link to different .html files, but having those files load in the main 'pane' of the site where I want them to.

I haven't used Dreamweaver in a while but I think there's a box where you can set a target frame for a link. Beyond that I can't help you because I don't use it anymore.
 

Munky

Diamond Member
Feb 5, 2005
9,372
0
76
In the html page that has your navigation links, use the <base target="..."> tag, and set it to your "main" frame. That way all your navigation links from one frame will open up in the other frame.
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Originally posted by: blackllotus
Originally posted by: Accipiter22
well yes, but I'm not sure how to do that exactly...I have the frames set up, I'm just vexed by the step of actually having the different buttons link to different .html files, but having those files load in the main 'pane' of the site where I want them to.

I haven't used Dreamweaver in a while but I think there's a box where you can set a target frame for a link. Beyond that I can't help you because I don't use it anymore.

that sounds like exactly what I need, I just can't figure out where it is...thank you though
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Originally posted by: munky
In the html page that has your navigation links, use the <base target="..."> tag, and set it to your "main" frame. That way all your navigation links from one frame will open up in the other frame.

I think I see the way to do that, but I have no idea how to name the frame of the table so that I can set it as the target...

here's what dreamweaver's help says:

"Select a frame by doing one of the following:
Alt-click (Windows) or Shift-Option-click (Macintosh) a frame in the Document window?s Design view.

Click a frame in the Frames panel (Window > Frames).

In the Property inspector (Window > Properties), click the expander arrow in the lower-right corner to see all of the frame properties.

Set the frame Property inspector options.

Frame Name The name used by a link?s target attribute or by a script to refer to the frame.
A frame name must be a single word; underscores (_) are allowed, but hyphens (-), periods (.), and spaces are not. A frame name must start with a letter (as opposed to a numeral). Frame names are case-sensitive. Don?t use terms that are reserved words in JavaScript (such as top or navigator) as frame names. "

The only problem is, there is NO frame name property where they're saying it is. That's what's holding me up here
 

troytime

Golden Member
Jan 3, 2006
1,996
1
0
the proper (standard, professional) way to accomplish this is by using includes.

You can use SSI, if your server allows it, or php/asp/.net/coldfusion includes.
if none of the above are available on your server, find a new host.
 

blackllotus

Golden Member
May 30, 2005
1,875
0
0
Originally posted by: troytime
the proper (standard, professional) way to accomplish this is by using includes.

You can use SSI, if your server allows it, or php/asp/.net/coldfusion includes.
if none of the above are available on your server, find a new host.

Thats overkill for what Accipiter wants to do and could only make his site slower.
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Originally posted by: blackllotus
Originally posted by: troytime
the proper (standard, professional) way to accomplish this is by using includes.

You can use SSI, if your server allows it, or php/asp/.net/coldfusion includes.
if none of the above are available on your server, find a new host.

Thats overkill for what Accipiter wants to do and could only make his site slower.

yah, I'm not doing anything heavy duty here...


also I think I'm just going to use html to name the frame rather than look for the shortcut in the properties menu. I've spent more time looking for the shortcut than I would have needed to name 50 damn frames with html
 

Unheard

Diamond Member
Jan 5, 2003
3,774
9
81
Seriously, use SSI, and avoid frames at all costs. The development time will actually be quicker by using SSI then it would with frames (especially if you are having to learn how to do either method).
 

troytime

Golden Member
Jan 3, 2006
1,996
1
0
Originally posted by: blackllotus
Originally posted by: troytime
the proper (standard, professional) way to accomplish this is by using includes.

You can use SSI, if your server allows it, or php/asp/.net/coldfusion includes.
if none of the above are available on your server, find a new host.

Thats overkill for what Accipiter wants to do and could only make his site slower.

Do you ANY experience with server performance?
If includes (from any of the above technologies) make a dent in performance, there is something severely wrong.

Frames are rarely used nowadays, and there's lots of reasons behind it.
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
I've never even heard of SSI....anyone have links to tutorials on how to use it?



edit: Ok, looked it up...doesn't look like Dreamweaver makes it easy to use. I don't have time to learn a completely new programming language either...this SSI thing looks like garbage at first glance.
 

Unheard

Diamond Member
Jan 5, 2003
3,774
9
81
Originally posted by: Accipiter22
I've never even heard of SSI....anyone have links to tutorials on how to use it?



edit: Ok, looked it up...doesn't look like Dreamweaver makes it easy to use. I don't have time to learn a completely new programming language either...this SSI thing looks like garbage at first glance.

SSI (Server Side Includes) Tutorial

That is done through Apache. If you have PHP or another scripting server on your web host you could use its built in include function. For PHP the syntax is:

<?php
include("blah.php");
?>

A simple way to get your site up and running would be to use something like this (CSS Layout Generator) to produce the tableless layout for your site, and then inside of each <div> container, add your include (weather it be SSI, PHP, etc).
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Originally posted by: Unheard
Originally posted by: Accipiter22
I've never even heard of SSI....anyone have links to tutorials on how to use it?



edit: Ok, looked it up...doesn't look like Dreamweaver makes it easy to use. I don't have time to learn a completely new programming language either...this SSI thing looks like garbage at first glance.

SSI (Server Side Includes) Tutorial

hmm that does look interesting, but it doesn't really do what I need....I just want a menu bar on the left, a site graphic at the top, and a main 'browser' pane for the site...it doesn't look like SSI is capable of doing that really...

edit: Honestly I can't see why anyone doing a simple site would use SSI.....more complex sites I would understand, but something that would take maybe 5 minutes with frames would take what? hours of programming with this SSI gimmick?
 

jjones

Lifer
Oct 9, 2001
15,424
2
0
The standard use to include a file would be

<!--#include virtual="menu.shtml"-->

This goes in your html in the location you want the file included, so for example, in the div tag where you want to include your side menu, that's what you would place instead of the menu itself. In the menu shtml file you would write the actual html code for the menu.

To use includes on an apache server you'll need the mod_include installed (check with your web host) and then in an .htaccess file located in the directory of the files calling the includes you should put:

Options +Includes
AddType text/html .shtml
AddHandler server-parsed .shtml

I think I got that right, but it's been a long time since I used any SSI, so anyone, please correct me if I'm wrong.

Try using google with the search term "server side includes" and you'll turn up plenty of info.
 

jjones

Lifer
Oct 9, 2001
15,424
2
0
Originally posted by: Accipiter22

edit: Honestly I can't see why anyone doing a simple site would use SSI.....more complex sites I would understand, but something that would take maybe 5 minutes with frames would take what? hours of programming with this SSI gimmick?

Because frames suck and should be avoided at all costs. Seriously. Your best bet, not having to use any programming language, is using SSI. SSI is not a gimmick at all. It's specifically for this type of thing and was quite popular in the earlier days of sites being mostly coded in html.

 

Munky

Diamond Member
Feb 5, 2005
9,372
0
76
I would also recommend doing SSI, but you need a host that supports server side scripting, either PHP, JSP, or some other language. Without such suport, you're basically stuck with frames, unless you "write out" the menu using javascript, but that's not good practice either.

Getting back to the frame version, in your frameset page you need to give each frame a name, like this example:

<frame name="menu" ...>
<frame name="main" ... >

Then in your navigation page you would put this tag, referencing your "main" frame by name:

<base target="main">

That way your navigation links would open in the main frame.
 

jjones

Lifer
Oct 9, 2001
15,424
2
0
Originally posted by: munky
I would also recommend doing SSI, but you need a host that supports server side scripting, either PHP, JSP, or some other language. Without such suport, you're basically stuck with frames...
Apache supports SSI (most likely what his server is running) and there's no need at all to use PHP, JSP or any other scripting language other than good old html.

 

troytime

Golden Member
Jan 3, 2006
1,996
1
0
Originally posted by: Accipiter22
Originally posted by: Unheard
Originally posted by: Accipiter22
I've never even heard of SSI....anyone have links to tutorials on how to use it?



edit: Ok, looked it up...doesn't look like Dreamweaver makes it easy to use. I don't have time to learn a completely new programming language either...this SSI thing looks like garbage at first glance.

SSI (Server Side Includes) Tutorial

hmm that does look interesting, but it doesn't really do what I need....I just want a menu bar on the left, a site graphic at the top, and a main 'browser' pane for the site...it doesn't look like SSI is capable of doing that really...

edit: Honestly I can't see why anyone doing a simple site would use SSI.....more complex sites I would understand, but something that would take maybe 5 minutes with frames would take what? hours of programming with this SSI gimmick?

it should take LESS time than doing frames.
its a single line of code, and you don't have to worry about all the target attributes

 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Originally posted by: jjones
The standard use to include a file would be

<!--#include virtual="menu.shtml"-->

This goes in your html in the location you want the file included, so for example, in the div tag where you want to include your side menu, that's what you would place instead of the menu itself. In the menu shtml file you would write the actual html code for the menu.

To use includes on an apache server you'll need the mod_include installed (check with your web host) and then in an .htaccess file located in the directory of the files calling the includes you should put:

Options +Includes
AddType text/html .shtml
AddHandler server-parsed .shtml

I think I got that right, but it's been a long time since I used any SSI, so anyone, please correct me if I'm wrong.

Try using google with the search term "server side includes" and you'll turn up plenty of info.



So basically draw out a table with boxes where the menu bar and site title graphic would go, and put those lines in the html for those sections of the table?
 

Accipiter22

Banned
Feb 11, 2005
7,942
2
0
Originally posted by: Unheard
Originally posted by: Accipiter22
I've never even heard of SSI....anyone have links to tutorials on how to use it?



edit: Ok, looked it up...doesn't look like Dreamweaver makes it easy to use. I don't have time to learn a completely new programming language either...this SSI thing looks like garbage at first glance.

SSI (Server Side Includes) Tutorial

That is done through Apache. If you have PHP or another scripting server on your web host you could use its built in include function. For PHP the syntax is:

<?php
include("blah.php");
?>

A simple way to get your site up and running would be to use something like this (CSS Layout Generator) to produce the tableless layout for your site, and then inside of each <div> container, add your include (weather it be SSI, PHP, etc).

thank you for the update!