Frame redirection works in Browsers, not Preview Pane

M

Michael Ash

Each of my pages has a simple script to rewrap itself in the correct frame
in case an indexer just addresses the content page:
function frameOpener()
{
if (parent == self)//no frameset
{
if (document.images)
top.location.replace('indexfr.htm?fa01');
else
window.location.href = 'indexfr.htm?fa01';
self.parent.contentloaded=1;
}
else // there is a frameset
{
....
}
}
This all works fine with browsers, but when I'm editing a page (like
fa01.htm above) and want to look at the results I always have to view it in
an external browser.
Can't use the Preview tab. When I do, the page momentairily appears, but
when it attempts to redirect it fails(or won't) to find the frame page.
Get the message:"The page cannot be displayed
The page you are looking for is currently unavailable "

Have tried this with the latest version of FP(2003) and it still does this.
Anyone know if there is a way around this?

Mike
 
K

Kevin Spencer

Anyone know if there is a way around this?

Don't use the Preview tab?

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Neither a follower
nor a lender be.
 
S

Steve Easton

This is because when you are editing a page, and then click Preview, you are actually previewing the
temporary copy located in the FrontPageTempDir.
Therefore the frame can't be found using the script because the page you're viewing isn't co-located
with the page the script is trying to find.

This is why you are prompted to save the page ( if you haven't already ) when you click "Preview in
Browser" because the browser preview uses the actual page from your web folder so that all links and
functions work properly.



--
Steve Easton
Microsoft MVP FrontPage
95isalive
This site is best viewed............
........................with a computer
 
M

Michael Ash

Thanks.
Kind of thought that.
I was hoping there was a way of previewing without saving first.
Mike
 
M

Murray

Don't use frames?

--
Murray

Kevin Spencer said:
Don't use the Preview tab?

--
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Neither a follower
nor a lender be.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top