Firefox 在浏览器的新选项卡中打开针对 iFrame 的链接
我发现了类似的问题,但它们是针对其他特定情况的。还没有找到我的答案,所以请帮助我。
我刚刚为 Facebook 页面设计了一个设计。它有两个针对 iFrame 的按钮。问题是,当我使用 Firefox 单击这些按钮时,链接将在新选项卡中打开,而不是在目标 iFrame 中打开。
我已经按照网上的一些说明进行操作,但它们不起作用。
这是代码(我不明白制作块的说明,抱歉,不是网络开发人员):
<iframe id="models" width="460" height="545" src="images/navidadm1.jpg"></iframe>
链接是:
<img src="images/navidad_09.jpg" width="50" height="25" alt=""></td>
<td><a href="http://www.grupogorila.com/fbpage/milagrosdeamaranto/navidadm1.html" target="models">
<img src="images/navidad_12.jpg" width="50" height="25" alt=""></td>
<td><a href="http://www.grupogorila.com/fbpage/milagrosdeamaranto/navidadm2.html" target="modelos">
...我希望我已经正确地显示了代码。如果没有,这是我的服务器中的实际页面。我真的很感激逐步的答案,因为我不是程序员:((如果添加javascript,确切地说是哪一行以及哪一行之间)。
http://grupogorila.com/fbpage/milagrosdeamaranto/ (按钮是“Ver Modelos 1 a 4”和“Ver Modelos 5 a 8”,位于篮子下方的下部)
非常非常非常感谢。
I've found similar issues like this, but they are addressed to other specific situations. Haven't found an answer to mine so please help me out.
I've just set up a design for a Facebook Page. It has two buttons targeted to an iFrame. the thing is that when I clic on these buttons using Firefox, the link will open in a new tab instead of the iFrame targeted.
I've followed several instructions over the net and they doesn't work.
Here is the code (I don't understand instructions to make blocks, sorry, not a web developer):
<iframe id="models" width="460" height="545" src="images/navidadm1.jpg"></iframe>
The links are:
<img src="images/navidad_09.jpg" width="50" height="25" alt=""></td>
<td><a href="http://www.grupogorila.com/fbpage/milagrosdeamaranto/navidadm1.html" target="models">
<img src="images/navidad_12.jpg" width="50" height="25" alt=""></td>
<td><a href="http://www.grupogorila.com/fbpage/milagrosdeamaranto/navidadm2.html" target="modelos">
... I hope I've showed the code correctly. If not, here is the actual page, in my server. I would really appreciate step-by-step answers since I am not a programmer :( (if adding javascript, exactly which line and between which lines).
http://grupogorila.com/fbpage/milagrosdeamaranto/
(the buttons are "Ver Modelos 1 a 4" and "Ver Modelos 5 a 8" in the lower part below the baskets)
Thank you, very, very, very much.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您始终可以使用 JavaScript:
JavaScript 代码(在 head 标签中):
链接代码:
这尚未经过测试,但应该可以工作! :)
You could always use JavaScript:
JavaScript code (in the head tags):
Code for the links:
This is not tested, but should work! :)
为您的 iframe 指定名称属性和 ID 属性,两者的值相同。
看一下这里:https://developer.mozilla.org/en/HTML/Element/ iframe
Give your iframe a name-attribute and an id-attribute, both the same value.
Take a look here: https://developer.mozilla.org/en/HTML/Element/iframe