Forum Moderators: open
Now, we all know that if I were to navigate to (http://example.com/about.htm) that the browser would open that page only, without the index page around it.
What I want to know is, how can I go to my index.htm page and choose what page to load in the iFrame? I want it to always open (home.htm) in the iFrame by default, but if I wanted to send a user to a specific page via a URL, how would I go about doing that?
[edited by: tedster at 4:55 am (utc) on June 17, 2005]
[edit reason] use example.com for domain name [/edit]
Any html document that is displayed within a frame or an iframe can (and should, IMO) also contain script that inserts it into its parent page in the event that someone comes there directly -- an "orphan"display of a page that is intended to have a "parent" . For example, search engines index the framed documents and then send people directly to the orphan page all the time.
This can be done with javascript. We have an example of how to do this with a regular frame page - but you can adapt the idea for an iframe page with just a few changes:
See Message #21 on:
[webmasterworld.com...]
- Chad
<SNIP>
[edited by: BlobFisk at 8:41 am (utc) on June 17, 2005]
[edit reason] No URLs please! See TOS [webmasterworld.com] [/edit]