Frames for the Compleat Idiot; or, Please Help!

[introductory rant]

I hate html! Hate hate hate hate hate it! Designing anything in html is like slicing cheese with a wooden knife!

[/introductory rant]

So…I need frames. I need to put some explanatory and instructional stuff, along with a couple buttons, in a narrow column to the left, while a different page (the one they came from, for purposes similar to the display of posts in a thread that are visible below the posting window when you add a post to a thread) is displayed in a separate frame to the right.

I’ve never put frames on my web site. They were disgustingly trendy for awhile, and usually used to truly vile effect, which turned me off to them. So I never learned how. Sort of assumed it would be easy enough–I’d just do it in PageMill, then look at the underlying HTML to see how one sets up a page like I needed, then reproduce that basic code in BBEdit.

Well, ummm…I, uh, it appears that I’m too stupid to set up frames in PageMill.

So I went to a site I knew that uses frames (one across the top=banner ad, most of page taken up by main page, narrow column at right serves as Subject index) and looked at their source code and it said:

<html>

<head>

<title>Site Title</title>
</head>

<frameset ROWS=“68,*” BORDER=YES FRAMEBORDER=1>

<frame SRC=“tfttop.html” NAME=“adbanner” MARGINWIDTH=5 BORDER=YES>
<frame SRC=“tft1001.html” NAME=“tftpage” MARGINWIDTH=3 BORDER=YES>

</frameset>
</html>

:confused:

Somehow that doesn’t help anywhere near as much as I thought it would.

Can anyone point me to (or write) a Frames For Dummies kind of primer for this?

I am not sure what help you want. That page defines the frames and points to the other html files which will be displayed in each frame. Fairly straightforward. where’s the problem?

I copied the source code to clipboard, pasted it into a blank BBEdit document, saved it as untitled.html; opened a new document, typed “This is tfttop frame”, saved it as tfttop.html; opened a third new document, typed “This is tft1001 frame”, saved it as tft1001.html.

Opened untitled.html in Netscape Navigator. I did NOT get a window divided up into a column on the left, a column on the top containing the words “This is tfttop frame”, and a main body section below tfttop and to the right of the empty left column containing the words “This is tft1001 frame”, which is what I was expecting.

No, I got a single undifferentiated window looking exactly like this:

(These are two separate frames, apparent if you try to select them both–you can only select one. But there are no dividers and they aren’t arrayed as they are on the page from which I stole the source code)

So I tried to add some main body text. If I added the string “This is the body” above the frameset tags, the page (when opened in Navigator) would say only and exactly:

If I add the same string BELOW the frameset tags, the page ignores it and displays the two frames only.

If I add the body string inside of <body> tags, whether before or after the frameset tags, or even envelop the frameset tags in <body> tags and include “This is the body”, I still don’t get three sections of page.

Hmm, maybe I could use this after all, although I’d really rather have the page separated into a narrow left column and the rest of the page on the right rather than top section and bottom section.

At any rate, feeling awfully clueless here.


<html>
<frameset COLS="100,*" FRAMEBORDER="1">
<frame SRC="leftcol.html" NAME="left"  BORDER=YES>
<frame SRC="content.html" NAME="content" BORDER=YES>
</frameset>
</html>

That should do basically what you mentioned. Now, in order to get from one frame to another in a link, you’ll want to do this:


<A HREF="newsite.html" TARGET="name_of_the_frame">my link</a>

put the HTML for the left frame in “leftcol.html” and the main stuff in “content.html”.

  • Rob

Try this

OK, now suppose I want a link, when clicked, to take away the frames and have the whole window be the target of the link?

(Thanks, by the way, I’m very close already)

I hate…I hate…I HATE frames! Thank Goddess I use netscape. I pity those that use IE.

I do hope you give them a button to break out of the frames.

Yeah, frames suck. I would not inflict them on my viewers without good reason, and I want to ditch them after one brief moment in the middle of a work-flow. My visitors will have clicked on a link indicating that they wish to respond to a thread. For the time being, I have no way of trapping for where the hell they were when they clicked any of two dozen or more possible copies of the same “go post a reply” button/link, so I need to take them to a page that has instructions on the left, shows the page of previous posts on the right, and says to them, “Please copy the subject line from the right hand frame, then come back over here and click the Continue button”.

(Well, I have a far better solution coming down the pike but that’s what I’m doing for now. Don’t hassle me for the string and baling wire characteristics of all this, please).

Now how the bloody hell do I get the “Continue” button to not merely take the visitor onwards to the next URL but also kill off the bloody frames? As it stands, only the frame with the Continue button is going onwards. I know how to change the target, but I don’t want the OTHER frame to go there instead, I want the frames to GO AWAY, how do I do that?

Seconding Reeder. Some well respected groups have put frames on their hit list for removal in the next html standards. More vice than virtue. There’s always a better way, one that one might actually enjoy.

See http://slashdot.org/article.pl?sid=99/11/22/2035202&mode=thread for some pointers about this issue.

OK, I’m closing in on it. I know it has to do with setting the “target” to “_top”.

Now all I gotta do is figure out how to use the “target” attribute.

God I hate HTML.

try

http://www.w3shcools.com

it explains everything decently.

It should be able to help

woo!

now the correct one

http://www.w3schools.com

they do NOT, help with your spelling, obviously.

::stomps across floor::

::throws coffee cup at wall::

::slams box of Zip cartridges to the floor::

::screams::

No, <a href="http://whateverthefuck.com/myfolder?target=_top> does NOT work.

and <a href="http://whateverthefuck.com/myfolder target=_top> does NOT work.

and do any of these damn clever tutorials bother to show an entire link string with the target attribute? Of COURSE NOT!!!

Did I mention how much I hate HTML?

HA!!!

Got it!!!

<a href=“http://whateverthefuck.com/myfolder” target="_top"> DOES work!!!
::picks up broken Zip cartridges from floor::

::sponges coffee stains off wall::

You just wait to you try debugging JavaScript layers for both Netscape and IE.

P.S. XML is your friend really :slight_smile:

Just wait till someone asks you to do those fancy drop down menus with javascript, and you’re making them on IE in 1024x768 on a 21 inch monitor, and they’re looking on Netscape 4.0 with a 640x480, 16 colour, 14 inch monitor.

That’s when you scream - not when you confuse a ROW with a COL.

I’ll go along with that, insofar as many applications can publish their data as XML and/or have their own built-in XML interpreters.

In other words, as long as I don’t have to write XML or write an interpreter module for it, I’m in favor of it.