框架问题 [英] Frame problem

查看:62
本文介绍了框架问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我的网页有问题。它使用两个框架,左边一个用于

内容列表,右边一个用于正文内容。

现在,当我查找例如google的页面时,然后它总是选择

身体(右框架),这样人们只能在没有左框架的情况下获得

问题中的请求页面。我想找到一种方法,如果这样的页面是

请求,它总是请求左框架。

我是否需要使用一些Javascript或其他东西为了这?我想在没有服务器端脚本语言的情况下尝试使用




看看我的意思:当我试图找到一个页面时谷歌关于我得到

示例此页面的结果:
http://metafysica.nl/crystal.html

但我需要它在正确的框架中像这样 http://metafysica.nl

Jurgen

解决方案

Blurg写道:

< snip>


< http://www.cs.tut。 fi / ~jkorpela / usenet / xpost.html>

< news:JJ ********************* @ amsnews03.chello。 com>


-

David Dorward http://dorward.me.uk/


希望这有助于


< body ONLOAD =" InFrame()">


< SCRIPT LANGUAGE =" JavaScript">


<! -

// Reloader MK3

//如果需要重新定位,要调用的页面或站点的名称

var mainsite =" http ://www.yoursite.com/index.htm" ;;

//设置消息

var msgQ ="您正在查看的页面是框架的一部分 - 基于

site. \ n单击确定以加载缺少的导航框架。\ n \\ n如果您单击

取消,您可以通过重新加载此页面再次访问此框。;

//从onload调用

函数InFrame(){

if(parent.frames.length == 0){

//我们在框架集之外加载,可能来自搜索引擎

//等待3秒后再询问

setTimeout(" InFrameQ) ()",3000);

}

}


函数InFrameQ(){

如果(确认(msgQ)){

//加载主站点

location.replace(mainsite);

}

} // - >


< ; / SCRIPT>

David Dorward< do ***** @ yahoo.com>在消息中写道

news:bl ******************* @ news.demon.co.uk ...

Blurg写道:
< snip>

< http://www.cs.tut.fi/~jkorpela/usenet/xpost.html>
<新闻:JJ ********************* @ amsnews03.chello.com>

-
David Dorward http://dorward.me.uk/



Tricia写道:

希望这有助于


也许你应该阅读 http://www.allmyfaqs.com/faq.pl?How_to_post

< body ONLOAD =" InFrame()">


< snip JavaScript>


Javascript与多站点有什么关系?[1]

David Dorward< do ***** @ yahoo.com>写了

Blurg写道:
< snip>
< http://www.cs.tut.fi/~jkorpela/usenet/xpost.html>
< news:JJ ************** *******@amsnews03.chello.com>




[1]提示:确保标题声称您的邮件是回复

是您实际重播的信息。


-

David Dorward http://dorward.me.uk/


Hi,
I have a problem with my webpage. It uses two frames, the left one for the
contents list and the right one for the body content.
Now, when I look up a page in for example google, then it''s always choosing
the body (right frame) and this way people only get the requested page in
question without the left frame. I like to find a way that if such a page is
requested, it''s always requesting the left frame too.
do I need to use some Javascript or something for this? I''d like
to try this without a server-side scripting language.

to see what I mean: when I try to find a page in google about I get for
example this page as a result:
http://metafysica.nl/crystal.html
But I need it to have it in the right frame like this http://metafysica.nl

Jurgen

解决方案

Blurg wrote:
<snip>

<http://www.cs.tut.fi/~jkorpela/usenet/xpost.html>
<news:JJ*********************@amsnews03.chello.com >

--
David Dorward http://dorward.me.uk/


Hope this helps

<body ONLOAD="InFrame()">

<SCRIPT LANGUAGE="JavaScript">

<!--
// Reloader MK3
// name of page or site to be called if relocate is required
var mainsite = "http://www.yoursite.com/index.htm";
// setup messages
var msgQ = "The page you are viewing is part of a frames-based
site.\nClick OK to load the missing navigation frames.\n\n If you click
CANCEL you can access this box again by reloading this page.";
// called from onload
function InFrame() {
if (parent.frames.length ==0) {
// We loaded outside of our frameset, probably from a search engine
// wait 3 secs before asking
setTimeout("InFrameQ()",3000);
}
}

function InFrameQ() {
if (confirm(msgQ)) {
// load the main site
location.replace(mainsite);
}
}//-->

</SCRIPT>
David Dorward <do*****@yahoo.com> wrote in message
news:bl*******************@news.demon.co.uk...

Blurg wrote:
<snip>

<http://www.cs.tut.fi/~jkorpela/usenet/xpost.html>
<news:JJ*********************@amsnews03.chello.com >

--
David Dorward http://dorward.me.uk/



Tricia wrote:

Hope this helps
Maybe you should read http://www.allmyfaqs.com/faq.pl?How_to_post
<body ONLOAD="InFrame()">
<snip JavaScript>

What does that Javascript have to do with multiposting?[1]
David Dorward <do*****@yahoo.com> wrote

Blurg wrote:
<snip> <http://www.cs.tut.fi/~jkorpela/usenet/xpost.html>
<news:JJ*********************@amsnews03.chello.com >



[1] Tip: Make sure that the message your headers claim you are replying to
is the message you are actually replaying to.

--
David Dorward http://dorward.me.uk/


这篇关于框架问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆