Web Design Forums

General Web Design Discussion

Have general questions about web design? Need help figuring out how to lay your site out, what style to use or how to make an image? Need help picking between photos for your homepage? Post your question here!

Frames: Good or Bad?



Site of the Month Nominations
ENTER YOUR SITE NOW!

Reply
 
LinkBack Thread Tools
Old June 1 '10, 12:54 AM (#1)
phillid is offline
New Member!
 
phillid's Avatar
 
Join Date: May 2010
Posts: 2
phillid is an unknown quantity at this point
Frames: Good or Bad?

Hello all. I already know that frames aren't the best thing to use on web pages (search engine troubles, compatibility issues etc.) but I need to have a common navigation bar between all of my pages. I've had problems before with needing to change a link for a 1 day offer or something and having to change each page, just to change it back again. My solution was to have a 'header.htm' in the root of my web directory and put an iframe on each page that's source is set to "/header.htm" The rest of the page is done with tables. Is is okay to have this one frame on each page???


Cheers,
Phillid
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old June 1 '10, 08:52 AM (#2)
mlseim is offline
WDF Staff
 
mlseim's Avatar
 
Join Date: April 2004
Location: Cottage Grove, Minnesota
Posts: 3,405
mlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud of
That's why you use PHP.

Either change the extensions of your files from .htm to .php,
or command the server to process .htm files as PHP (using .htaccess).

You then have a single file (script) that is your navigation menu.
It only contains the menu part. Perhaps you call it "menu.php".

On every other page, you "include" that script ... where it becomes inserted
into the place where you have included it. Example, your menu is called "menu.php" ...

You then put this line where you want it to appear ...
<?php include("menu.php");?>

Here's the interesting part though ... within "menu.php", you can also do normal
PHP scripting, so you could have the links change depending on which page they
were included. Maybe the current link becomes highlighted? Or you display some
special sub-links for a certain page?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old June 1 '10, 08:33 PM (#3)
phillid is offline
New Member!
 
phillid's Avatar
 
Join Date: May 2010
Posts: 2
phillid is an unknown quantity at this point
Can I just put HTML in the PHP file??? I presume so. Do I only need to rename the menu file to PHP or the whole site??

Thanks!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old June 1 '10, 10:15 PM (#4)
mlseim is offline
WDF Staff
 
mlseim's Avatar
 
Join Date: April 2004
Location: Cottage Grove, Minnesota
Posts: 3,405
mlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud ofmlseim has much to be proud of
You can include any file, .txt .html or .php

The file that contains <?php include("menu.htm")?> must be a PHP script
or a mix of HTML and PHP. The file extension has to be .php

If you feel like messing with .htaccess, you can command your webhost to
process all of your .htm files as PHP. Use Google to find out about .htaccess
That means you can put PHP scripting in your .htm files without changing the
file extension.

Your website could actually be one web page if you wanted it ... "index.php".
PHP would simply change the content for each "page". There are in fact, no other
pages, only the content changes. All of the content, images, etc. for each "page"
is stored in text files or a database.

For example, see this site: To view the link you have to Register
Scroll down the links on the left. Notice each link has a code .. ie. ?explore=4
Those codes tell the PHP script which text to insert into the content area and
which banners to use on the top. There is basically only one file, not separate HTML pages.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old June 1 '10, 10:15 PM (#5)
aeroweb99 is offline
<div id="learn"></div>
 
aeroweb99's Avatar
 
Join Date: February 2008
Location: Port Huron, Michigan
Posts: 988
aeroweb99 is just really niceaeroweb99 is just really niceaeroweb99 is just really niceaeroweb99 is just really niceaeroweb99 is just really nice
Yes, the menu.php will actually be html code. No doctype or anything, just the code for your menu. Of course using divs for your code is almost a must.

Yes to your other question too. Any page that uses an "include" file needs to have the php extension.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old June 3 '10, 10:06 AM (#6)
andr104 is offline
WDF Regular
 
andr104's Avatar
 
Join Date: November 2008
Posts: 411
andr104 is an unknown quantity at this point
I don't like frames because it is difficult for me to modify them.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 3 '10, 07:17 PM (#7)
rickzwebz is offline
WDF Member
 
rickzwebz's Avatar
 
Join Date: July 2010
Location: Winnipeg
Posts: 25
rickzwebz is on a distinguished road
Frames are bad. Use a menu.inc.php. I use for my menu

<?php
if($page == "about") {
echo '<li><a href="about.php" id="current">about us</a></li>';
}
else {
echo '<li><a href="about.php">about us</a></li>';
}
?>

Its very easy to add, remove, change the link, change the title of the button, and it affects all pages
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 6 '10, 06:08 PM (#8)
UNCCheezy is offline
WDF Member
 
UNCCheezy's Avatar
 
Join Date: July 2010
Posts: 27
UNCCheezy is an unknown quantity at this point
Sounds like you need to head over to w3school.org and check out the php learning page.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 8 '10, 01:38 PM (#9)
manugarhoyos is offline
New Member!
 
manugarhoyos's Avatar
 
Join Date: July 2010
Posts: 6
manugarhoyos is an unknown quantity at this point
I think that Frames are too old... It was good when Internet was too slow, but now, I think that they are inneccesary and looks old
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 10 '10, 02:52 AM (#10)
mwanted is offline
New Member!
 
mwanted's Avatar
 
Join Date: July 2010
Posts: 4
mwanted is an unknown quantity at this point
Well I think that frames are bad as far as search engine optimization is concerned. Regarding user experience I think its bad too.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 14 '10, 04:17 PM (#11)
dustout is offline
New Member!
 
dustout's Avatar
 
Join Date: December 2008
Posts: 5
dustout is an unknown quantity at this point
bad for sure, frames are lame
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 14 '10, 04:19 PM (#12)
jaxstax is offline
New Member!
 
jaxstax's Avatar
 
Join Date: April 2003
Location: Raleigh-Durham, NC
Posts: 7
jaxstax
Frames have been deprecated and should not be used under any circumstances. Try using includes- better yet try using a clean CMS.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 16 '10, 01:48 AM (#13)
tsurender is offline
New Member!
 
tsurender's Avatar
 
Join Date: July 2010
Posts: 3
tsurender is an unknown quantity at this point
Yes, most of them are not preffered frames generally, ofCourse the use of frames doesn't know properly indepth.. will discuss later... but here you can also incorporate your navigation buttons [header page]without using frames and without using any php script.

You can use Javascript component by using 'getElementByTagName' with in the javascript page for each tags.

or

You can simply use dreamweaver template is the best, incase you know much about dreamweaver software.

Cheers
soori
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 18 '10, 04:47 AM (#14)
byronc is offline
WDF Member
 
byronc's Avatar
 
Join Date: July 2010
Posts: 62
byronc is an unknown quantity at this point
Quote:
Originally Posted by manugarhoyos View Post
I think that Frames are too old... It was good when Internet was too slow, but now, I think that they are inneccesary and looks old
its not about age, its about SEO and frames are a nono as google has does not index then properly
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 19 '10, 04:31 AM (#15)
yousaysomething is offline
WDF Member
 
yousaysomething's Avatar
 
Join Date: June 2010
Location: California
Posts: 37
yousaysomething is on a distinguished road
You can use javascript if you would like the page to be interactive. When you click on a link, it may only change a portion of the website without reloading the page (almost like changing the frames.)

But you should avoid using frames for the reasons you've mentioned and there is usually a substitute that will work a lot better.

Take a look at AJAX.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 20 '10, 03:49 AM (#16)
kurumurthy is offline
New Member!
 
kurumurthy's Avatar
 
Join Date: July 2010
Location: hyderabad
Posts: 11
kurumurthy is an unknown quantity at this point
Search engines have a hard time indexing a Web site that is stuck in a frameset
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 22 '10, 04:40 AM (#17)
golfsalestore is offline
New Member!
 
golfsalestore's Avatar
 
Join Date: July 2010
Posts: 3
golfsalestore is an unknown quantity at this point
frames are always bad.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 30 '10, 03:50 AM (#18)
Perth Web is offline
New Member!
 
Perth Web's Avatar
 
Join Date: July 2010
Location: perth
Posts: 11
Perth Web is an unknown quantity at this point
frames are soo 90's.. as the smart kids have already said, just use include techniques..
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old July 30 '10, 06:36 AM (#19)
crazydanceXL is offline
New Member!
 
crazydanceXL's Avatar
 
Join Date: July 2010
Posts: 13
crazydanceXL is an unknown quantity at this point
Ask yourself what you want to do with the data... PHP includes are dynamic, but you can use AJAX for a WAY more effective website. Furthermore, does your hosting support PHP... if not, use AJAX... you could use PHP for including more advanced things like classes, and database communication... other than that i would use AJAX to refresh protions of a website.

Example. You have a basic website with a menu, and a DIV displaying the content... with PHP includes you would have te refresh the whole page, thus loading images and code into your memory all over again. with AJAX you just reload the content inside the DIV, making loading a whole lot faster.

If you want to take an even easier road, look into jQuery. that's javascript too, but it's a insanely easy and versatile library for making your website do all sorts of stuff.

So my advice, at least dump the frames, and look into AJAX/jQuery for the most effective solution.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old August 2 '10, 08:28 AM (#20)
mithunsingh is offline
New Member!
 
mithunsingh's Avatar
 
Join Date: August 2010
Posts: 2
mithunsingh is an unknown quantity at this point
Frame is not good for SEO friendly. Mostly Experts are using frames bcoz it's have different address from live web page.

Thanks
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old August 2 '10, 09:31 AM (#21)
Justteen is offline
WDF Member
 
Justteen's Avatar
 
Join Date: July 2010
Posts: 22
Justteen is an unknown quantity at this point
Don't use Frames, it is really awful, use php as mlseim told you
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old August 4 '10, 05:30 AM (#22)
diddy is offline
[insert witty comment here]
 
diddy's Avatar
 
Join Date: June 2008
Location: Sydney, Australia
Posts: 500
diddy will become famous soon enoughdiddy will become famous soon enough
A while ago I designed a site for my uncle, To view the link you have to Register. I know it's simple, but that's not the point. The five 'pages' are actually all just the index.html. Javascript and AJAX was used to switch the tabbed content. The script turns <h1> into the header for a particular tab. If you don't have a mega amount of content and a few pages, it's a cool idea. It works well and is really fast to switch the tabs.
But I did that before I knew about php includes. I think includes is a better way to go, but the javascript tabber idea is pretty cool as well IMO.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old August 4 '10, 01:54 PM (#23)
7HillsIT is offline
New Member!
 
7HillsIT's Avatar
 
Join Date: August 2010
Location: Sheffield, UK
Posts: 3
7HillsIT is an unknown quantity at this point
AJAX and CSS all the way. As has been stated search engines can't index a frames based index page very easily so bad SEO. Frames also limit you in terms of design and layout whereas a well written CSS based site will allow dynamic areas of your page that can be controlled and manipulated in terms of layout and style / design.
Dave
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old August 5 '10, 01:33 AM (#24)
seopiper is offline
WDF Member
 
seopiper's Avatar
 
Join Date: June 2010
Posts: 27
seopiper is an unknown quantity at this point
frames are old school. there are better codings and ways right now for websites.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

  Web Design Forums » Web Design Help » General Web Design Discussion

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
XML sitemaps for Ecommerce? good or bad for SEO ABSSolutons Search Engine Optimization / SEO 5 November 12 '08 05:15 AM
Help! Newbie...Site is bad on IE but looks good on FF and Safari??? kimn27 HTML and CSS Help 3 May 9 '08 08:40 AM
the good and bad samp Website Ratings and Reviews 3 November 7 '07 01:19 PM
Need a good Graphic Designer mmilano Adobe Photoshop Help 0 January 19 '05 09:49 PM
Beginner looking for good photoshop/image program john1529 General Web Design Discussion 27 August 31 '04 02:21 PM

 
User Infomation
Your Avatar

Site Of The Month

Ticket Cake
Ticket Cake

Ticket Cake is a drupal based event ticketing platform. It features that ability to browse events and share them.

Nominate Your Site Now!

Advertisement
WolfCMS.org

Latest Articles
- by RickM
- by bfsog

Advertisement

Partner Links



All times are GMT -4. The time now is 02:56 AM.


WebDesignForums.net is Copyright © 2010 RikeMedia.

SEO by vBSEO

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163