HTML Tutorial


 Forum HomeForum Home   FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
RegisterRegister - Not registered yet? Got something to say? Join HTML Code Tutorial!
Opening a page inside a table..
Goto page 1, 2  Next
Post new topic   Reply to topic    HTML Help Forum Index -> HTML Table
View previous topic :: View next topic  
Author Message
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Sun Oct 16, 2005 7:37 am     Opening a page inside a table.. Reply with quote

I have a basic website layout created. A Nagivation bar on the left side and a main content area in which content from the selected option in the Navbar will be displayed. I am using HTML tables to create the site and need to know what procedures I need to take to achieve opening the selected option in the main content area.

I have some questions here:

- Do I need to create a seperate .htm file for each area of the website e.g: one for the navigation, one for the content area. At present I only have the index.htm page.

- If so, can someone give me the basic coding used for the areas in the above question?

- Finally the code for opening a page in a perticular table.

Thank you for your help! Very Happy
Corey Bryant
Site Admin


Joined: 15 May 2004
Posts: 8305
Location: Castle Pines North, CO USA

PostPosted: Sun Oct 16, 2005 7:57 am     Reply with quote



Are you wanting to use frames? It seems that is what you are trying to allude to - but frames are not all that great, especially for search engines, etc
jdrasq



Joined: 24 Apr 2005
Posts: 38
Location: UK

PostPosted: Sun Oct 16, 2005 8:04 am     Reply with quote

Yes, it would be best for you to create new pages. This way, you know where everything is and it is quicker loading,
One way to open the new page within the original is to use iframes, then when a user presses on one of the links then it will open the new page within the original page, the code you would need for this is as follows

In the <body> section, where you want the iframe to be positioned

Code:
 <iframe name="iframe1" height="500" width="500" frameborder="1"></iframe>


Then, on your button

Code:
 <a href="page url" target="iframe1"> </a>


OK?
JDRasq
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Sun Oct 16, 2005 8:05 am     Reply with quote

Hey Corey. Thanks for getting back. What would you suggest to use? This the site that I have at the moment http://www.freewebs.com/fulhamish/ The layout was not created by me, however I am able to create layouts. I just didnt know where to start with all the coding. Any tutional sites would help greating with the proposed new method of coding you may have.

Thank you once again

Amir
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Sun Oct 16, 2005 8:07 am     Reply with quote

Thanks JD. I can understand the coding you have given me and about the positioning. However, would i need to start over all my code creating iframes for each part of the layout.. E.g the Navigation/content area.

http://www.freewebs.com/fulhamish/ Thats what I have at the moment, feel free to look at the code. (The original code was created by the layout maker, I have adjusted slightly, adding my banner in etc)
Corey Bryant
Site Admin


Joined: 15 May 2004
Posts: 8305
Location: Castle Pines North, CO USA

PostPosted: Sun Oct 16, 2005 8:13 am     Reply with quote

Well if you just copy your code - you will have a new page. And then you just place your content in there.

Tutorials - besides this site - there is the W3 Schools
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Sun Oct 16, 2005 8:26 am     Reply with quote

Thanks for the help guys. One final question. Inside the first code that JD gave me above, how would I change the background colour and also position the iframe correctly on the page?

Thank you.. Amir
Corey Bryant
Site Admin


Joined: 15 May 2004
Posts: 8305
Location: Castle Pines North, CO USA

PostPosted: Sun Oct 16, 2005 8:47 am     Reply with quote

Well the code would be more like
Code:
<iframe name="contents" src="main.html" height="500" width="500">
and the you would change the body background on main.html
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Sun Oct 16, 2005 8:59 am     Reply with quote

Thanks corey. How would I position the iframe correctly and make it transparent? Cheers for the help mate.
Superpetauction



Joined: 07 Oct 2005
Posts: 47
Location: Logansport, Indiana

PostPosted: Sun Oct 16, 2005 9:02 am     Reply with quote

enjoy

Code:
<iframe name="contents" src="main.html" height="500" width="500" align="center">
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Sun Oct 16, 2005 9:10 am     Reply with quote

Is there anymore I can do other than centering it? I need the iFrame to cover exactly over my layouts given content box. Cant i specify a pixel length from the top of the page, and so on with from the side of the page? If so please help.

Cheers Superpetauction!
Superpetauction



Joined: 07 Oct 2005
Posts: 47
Location: Logansport, Indiana

PostPosted: Sun Oct 16, 2005 10:15 am     Reply with quote

is this what you are looking for
Code:
<iframe name="contents" src="main.html" WIDTH="500"HEIGHT="500"MARGINWIDTH="0" MARGINHEIGHT="0" FRAMEBORDER="yes"SCROLLING="YES">
jdrasq



Joined: 24 Apr 2005
Posts: 38
Location: UK

PostPosted: Mon Oct 17, 2005 7:00 am     Reply with quote

Hi,
Is everything sorted now?
JDRasq
amirtavoussi



Joined: 13 Oct 2005
Posts: 8
Location: London, UK

PostPosted: Tue Oct 18, 2005 10:21 am     Reply with quote

Its all great now mate. [url]Take alook www.freewebs.com/fulhamish[/url]
Corey Bryant
Site Admin


Joined: 15 May 2004
Posts: 8305
Location: Castle Pines North, CO USA

PostPosted: Tue Oct 18, 2005 10:33 am     Reply with quote

Sorry I mised this response for some reason, but check your DOCTYPE since you are using frames now and also check some of your font tags - they are still opened.

Once you get used to HTML, consider switching to CSS to control your fonts since the font tag is deprecated
Display posts from previous:   
Post new topic   Reply to topic    HTML Help Forum Index -> HTML Table All times are GMT - 8 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
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 vote in polls in this forum
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
HTML Help topic RSS feed 

 
HOSTING / DESIGN
MAKE MONEY

Home
  |   Tutorials   |   Forum   |   Quick List   |   Link Directory   |   About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial