INSTEAD of frames, what do you use?

  • DuffMan
  • Beginner
  • Beginner
  • User avatar
  • Posts: 60
  • Loc: Portland, OR

Post 3+ Months Ago

So it sounds like frames are old news. It also seems like they cause webmasters to become homicidal maniacs when reviewing pages. :wink:

Oh, and before I get to my question, why do you hate them? Is it the style you hate or the html hooba-joob load times and such?

Now, what do I do instead of frames? Take ozzu for example, how is it that you have all the buttons and ozzu logo up top on every page? Its so easy to just use a frame to keep it there... Do you just make a template html and create every page off of that, or is there newer way (maybe php :?: ??) to accomplish the exact same thing that frames do?
  • lostinbeta
  • Guru
  • Guru
  • User avatar
  • Posts: 1402
  • Loc: Philadelphia, PA

Post 3+ Months Ago

I don't hate frames, but I can say they are TOO OFTEN misused, which is the reason a lot of people dislike frames.

This forum is done via a template, change the title area in the template, and ALL the pages change with it, which is definitely more efficient and nicer looking than a frame.


Depending on what you are doing though you have some alternative to a frame.

You have an iframe, which is a seperate frame within the HTML document that does not have to be contained within a main frameset like a frame does. Many people use iframes for content now, because it allows you to section out an area of your HTML where you want to add a lot of content, but just don't have the space, so instead you can load in the external file into the iframe and voila, a scrollable area (great for news/updates areas)

Then there is the scrollable div tag. Which uses CSS to size a div tag and toggle whether or not you can scroll that div if the content inside exceeds the width and/or height of the div tag.
  • musik
  • Legend
  • Super Moderator
  • User avatar
  • Posts: 6893
  • Loc: up a tree

Post 3+ Months Ago

frames just look tacky most of the time and they also can look crap with the different size browsers, in a small browser you have to scroll down the frame menu - not a good thing. with the wide variety of menu's you can use these days there is no reason to use them.

I recently redesigned my work site to lose the frames I had on it. The javascript menu works on all browsers and is updatable in one file which changes across all of them, so I dont have to update each file.
http://www.flexispray.com.au
  • UNFLUX
  • Genius
  • Genius
  • User avatar
  • Posts: 6375
  • Loc: twitter.com/unflux

Post 3+ Months Ago

*sigh* this has been argued over many times here

I use frames in a lot of my designs as just that, designs. They're very
helpful and work very well, as with most things, when used PROPERLY.

here's 2 examples using frames correctly --

http://www.cloud9studios.com
http://www.benjaminfinancial.com
  • b_heyer
  • Web Master
  • Web Master
  • User avatar
  • Posts: 4581
  • Loc: Maryland

Post 3+ Months Ago

You can use tables and div tags with php includes pretty effectivly (basically a template).
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23460
  • Loc: Woodbridge VA

Post 3+ Months Ago

This discussion has occured many times already, just about anytime someone brings up frames, so I'll try to be a little different about it. First, the reasons, I don't like them.

1. Most framed sites I've seen just don't look good. That's the designer's fault.
2. Most frame pages I've seen screw up the navigation one place or another. That's also the designer's fault.
3. The one thing that has been pointed out most frequently is they don't do as well with search engines.



However, the thing that I like least about frames is bookmarking them. There are so many times that I don't want to bookmark the home page, but one of the internal pages instead. If I bookmark the site that I'm on in a frame environment, the bookmark is always going to take me to the home page, and not where I want to be. Sure I know how to work around it. Netscape makes it very easy, by giving you a right click option to open the frame in a new window. MSIE, however, doesn't have that option, and it's a pain to have to go to the frame I want, right click, view properties and copy the link into a new window, which is all I wanted to begin with.

In addition to that, printing framed pages can be tricky. If you don't click the Print frame option, you won't get what you thought you wanted printed - a waste of ink paper and time. Even though I know better, I've still printed the wrong frame page many times because the frame I wanted wasn't the active one.

Now in terms of this particular site, yes -- the top portion of the page is one template and it's called by the php script to show up on every page. So that script did not have to be copied over and over, and is called into play by one simple line of code. That makes it as easy or easier than frames to change the look of the entire site.

Server side languages such as php and asp offer this type of solution. For what it's worth there are multiple templates for this board. The footer is another example. The body of the pages are also templates. This allows a programmer to completely redesign a new type of page for this, but not have to necessarily rewrite HTML code all the time.

There, I hope I've provided new information that hasn't been stated already at one time or another.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23460
  • Loc: Woodbridge VA

Post 3+ Months Ago

UNFLUX wrote:
*sigh* this has been argued over many times here

I use frames in a lot of my designs as just that, designs. They're very
helpful and work very well, as with most things, when used PROPERLY.



Yep - and you've used both of those excellent examples, before as well. I'm surprised the entire membership here hasn't bookmarked those yet to study and learn from! :wink:
  • UNFLUX
  • Genius
  • Genius
  • User avatar
  • Posts: 6375
  • Loc: twitter.com/unflux

Post 3+ Months Ago

thanks for the kind words. I try not to let things get to me, but this is a
sore subject for me sometimes.
  • Johan007
  • Guru
  • Guru
  • User avatar
  • Posts: 1080
  • Loc: Aldershot, UK

Post 3+ Months Ago

Quote:
INSTEAD of frames, what do you use?


You will need a server side programming languages. Most free webhosts and ALL paid for hosting can give you PHP and so you can use simple server side includes.

These are easyier to set up than frames and a begginner can pick it up just as quickly. An include links to your navigation bar in a seprate file so if you add a new feature you can add it to your menu without changing every dam page (same goes for header, footer or banner!)

You sample.php page will have this code where you want your navigation in the HTML: (<tr><td> tags are just an example you will have to the simple html)


Code: [ Select ]

.... <tr><td>

<?php
include("/includes/menu.htm");
?>

</td></tr>
<tr><td>

<?php
include("/includes/header.htm");
?>

</td></tr>...
  1. .... <tr><td>
  2. <?php
  3. include("/includes/menu.htm");
  4. ?>
  5. </td></tr>
  6. <tr><td>
  7. <?php
  8. include("/includes/header.htm");
  9. ?>
  10. </td></tr>...


Now you do 1 page called menu.htm (or any extention it dont matter) and stick your menu html in there.

You also create 1 page for your header and do the same.

Also you can do banners in a inlcude where you change 1 file to update all your page!!!! and also the footer and anything you want really!!!!

Piss easy and it much better than frames :D

** Code Changes thanks to b_heyer , additional grammer changes made **
  • b_heyer
  • Web Master
  • Web Master
  • User avatar
  • Posts: 4581
  • Loc: Maryland

Post 3+ Months Ago

Code: [ Select ]
.... <tr><td>

<?php
include("/includes/menu.htm");
?>

</td></tr>
<tr><td>

<?php
include("/includes/header.htm");
?>

</td></tr>...
  1. .... <tr><td>
  2. <?php
  3. include("/includes/menu.htm");
  4. ?>
  5. </td></tr>
  6. <tr><td>
  7. <?php
  8. include("/includes/header.htm");
  9. ?>
  10. </td></tr>...


You need to remember your semicolons after each line :)
  • 360Varial
  • Graduate
  • Graduate
  • 360Varial
  • Posts: 163

Post 3+ Months Ago

Are iframes the best route to take if I want content to load in a certain area of my page. I want everything to stay intact except for this little box that all of my info is going to load when an option (profile, graphics, etc.) is clicked.

Does the latest version of Mozilla support iframes? What's the best alternative to iframes? Loading the movies with Flash?
  • joebert
  • Fart Bubbles
  • Genius
  • User avatar
  • Posts: 13504
  • Loc: Florida
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23460
  • Loc: Woodbridge VA

Post 3+ Months Ago

I merged this with the original discussion thread on it. I doubt there's too much more that can be added to be honest.
  • Carnix
  • Guru
  • Guru
  • User avatar
  • Posts: 1098

Post 3+ Months Ago

On a highly trafficed, professionally monitored (business-wise) site, frames of any kind are a very bad idea. Forget the technical issues, from a businees perspective, they make things more difficult. They increase, improperly, stats across the board, especially page views and hits.

Also, if you are trying to track, say, the top 5 most traffiked pages on your site, and you use a frameset, then the top three will ALWAYS* be just your homepage (index, main, nav, for example). If you have an iframe on your homepage, the same is true for that... index and the iframe document will always be the top two most viewed pages

If you then track over time, and happen to make changes to the file names, or remove the frameset altogether, your trend data is then thrown off, and you have to manually account for the loads of inaccurate data. This happened at my org... our site is heavily trafficked, and the site used to have a frameset (three pages). If I look at stats that include data older than 2 years or so (so that stats from the frameset is included), files like nav.asp and main.asp are right up there with index.asp, bumping down REAL pages like /newsroom/index.asp or /careers/index.asp for example to 4th and 5th, for example, which is just wrong. So when the SMT asked for a report, I had to manually go through and manipulate the data, since the data showed X page views for a given month, but really it was X - (views for nav.asp and main.asp)...

* unless you happen to have a site were the homepage isn't the most viewed page... substitute "homepage" with whatever your most viewed page is...
  • Bobbo171
  • Graduate
  • Graduate
  • Bobbo171
  • Posts: 174

Post 3+ Months Ago

I think frames are icky...i had to change my site completely to avoid using them. The best way to do something that would be like using frames is a SSI(server side include) I like using php includes with come variables. Basically what you do is create a layout, and have the menus and links on it, but leave the content area empty except for the php include, which is
Code: [ Select ]
<?php include('$id'); ?>

id is whatever variable you want, but that comes in later. Then you create pages with just the content in it, like so
Code: [ Select ]
<p><b>Main page</b></p>
<p>This is my main page, using php includes</p>
  1. <p><b>Main page</b></p>
  2. <p>This is my main page, using php includes</p>

and you would name that page something like main.html. The way to view your layout woulb be something like this http://www.site.com/layout.php, that would show the layout without any content, and then this: http://www.site.com/layout.php?id=main.html would show the layout, with main.html included whereever you put the php include.

I like using this becuase it cuts down on file size a bit and its a lot faster to change your layout with just one file change. There is a cleaner way, so that you dont need the nasty "?" and "=" which search engines dont like to much, but that bothers with dealing with htaccess

well I hope that was informative :)
  • Axe
  • Genius
  • Genius
  • User avatar
  • Posts: 5739
  • Loc: Sub-level 28

Post 3+ Months Ago

UNFLUX wrote:
I use frames in a lot of my designs as just that, designs. They're very
helpful and work very well, as with most things, when used PROPERLY.


From a visual aspect, like unflux says, design, they're great, a very handy & helpful tool.

For a primarily content-based site, where you're looking to get visitors from search-engines, they fail miserably 99% of the time. It can take some javascript and other things for it to really work between humans & SE's.
  • lioness
  • Mastermind
  • Mastermind
  • User avatar
  • Posts: 1615

Post 3+ Months Ago

Bobbo171 wrote:
Code: [ Select ]
<?php include('$id'); ?>

well I hope that was informative :)


Yes that was informative Bobbo - thanks!

In your post you gave an example of passing the $id variable through the address bar (i.e. http://www.site.com/layout.php?id=main.html).

Is there a way of assigning the $id variable from within a page, so that '?' and '=' are not present in the address bar? (and not using htaccess?)
  • Hazard
  • Graduate
  • Graduate
  • User avatar
  • Posts: 145
  • Loc: London, UK

Post 3+ Months Ago

frames? i dont really like using them as i don't know how to use them properly, so i dont...but as u can see at my site i use iframes (floating frames) i like iframes
  • multiosbrowser
  • Beginner
  • Beginner
  • User avatar
  • Posts: 62
  • Loc: Germany

Post 3+ Months Ago

ATNO/TW wrote:
UNFLUX wrote:
*sigh* this has been argued over many times here

I use frames in a lot of my designs as just that, designs. They're very
helpful and work very well, as with most things, when used PROPERLY.



Yep - and you've used both of those excellent examples, before as well. I'm surprised the entire membership here hasn't bookmarked those yet to study and learn from! :wink:



... excellent examples ? ... and learn from ?

I don't think so. When i use Amaya i get an empty page and i must
go to the top and click to an undescripted frame source.

In Opera, when Frames are disabled, i see nothing. I can't get
one of the frame sources. So only an empty page is displayed.

When i use Firefox and disable Java, JavaScript and images i only
see in the footbar where the links go, but on the page i see only
placeholders for the images.

So, is it an excellent example ? Can i learn from ?
  • thejustin
  • Born
  • Born
  • thejustin
  • Posts: 1

Post 3+ Months Ago

I read through this forum and didn't see any solutions for replacing the frames the way I use them. Others asked if there is a way to make a site without frames where the whole page doesn't reload when something is selected from a menu. Here's an example of how I use frames:

http://www.thejustin.com/photoshops/

Here's how it works (obiously): The user selects a thumbnail on the left and it changes the content in the main frame. The left frame doesn't change. Is there a way to get similar results by using divs or any other code? If so I'd love to learn how because i'd like to eventually incorporate my picture viewer inside another page and not have the whole page reload when a thumbnail is selected.

Thank you.
  • Mas Sehguh
  • Mastermind
  • Mastermind
  • User avatar
  • Posts: 1853

Post 3+ Months Ago

One huge problem with frames is not bookmarking (because browsers can cope with that, and some do. Others don't, but frames don't prevent browsers from bookmarking). What they do do is break the fundamental model of the Web -- which is hyperlinking.

It is not possible to link to a specific frame within a frameset, unless you run into the coincidence of two events: the page having javascript to recognize that it's not in a frame so that it loads the frameset around the document, and the user having javascript turned on. But even then, the person who wants to create the link has to go through a large amount of trouble just to figure out the address of the page to which he wants to link. And why would go through that trouble just to link to you?

Considering that the aspect of the Web that set it apart from other technologies such as Gopher and made it popular was hyperlinking, breaking that technology is a bad idea.

UNFLUX wrote:
here's 2 examples using frames correctly --

http://www.cloud9studios.com
http://www.benjaminfinancial.com


In both those examples, I can't create a hyperlink to an individual page within the website.

It is possible to invoke frames without breaking the fundamental model of the WWW, and that involves having a new frameset document for every page.

--------------

One usability issue associated with frames in which the navigation menu is in a separate frame (as well as many sites without frames) is hyperlinks that do nothing -- that point to the current page. This can cause many users to see nothing happen and try clicking again. Additionally, it can make people doubt themselves, wondering whether something did happen. It is a well-documented problem, and one of the many overlooked reasons for why frames are a bad idea.

Overall, the reason frames should be avoided is that there are a large number of problems that have to be worked around, and every author is going to miss a few of them (as shown in the two sites mentioned above).

Post Information

  • Total Posts in this topic: 21 posts
  • Users browsing this forum: No registered users and 26 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.