在iframe中显示mediawiki [英] Displaying a mediawiki within a iframe

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

问题描述

首先...我不想使用iframe,但我不认为我可以选择这种情况。

First off... I don't really want to use iframes but I don't think I have a choice in this situation.

一些帮助文档到一个已经建立的系统。我最容易让其他人写帮助的是向他们提供一个带有自定义样式的mediawiki,然后将其整合到系统中,我想在帮助标签中直接链接到mediawiki。

I'm integrating some help docs into an already built system. The easiest thing for me to let other people write the help is to provide them with a mediawiki with a custom style, then to integrate this into the system I wanted to put a direct link to the mediawiki in a help tab.

问题是,我的mediawiki似乎阻止iframe加载它(也许这是一个默认设置),但我想知道如何关闭它。我知道我的代码很好,因为它加载其他网站!

The problem is, my mediawiki appears to block iframes from loading it (maybe this is a default setting) but I was wondering how to turn it off. I know my code is fine as it loads other sites!

也可以做我想使用div标签吗?

Also can you do what I'm attempting to do with a div tag?

感谢

推荐答案

维基通常不允许你这样做,解决方法:

The wiki doesn't normally allow you to do it, but there is a workaround:

要在iframe中显示wiki,您必须找到文件mediawiki-1.xx \ skins \ common \ wikibits.js注释掉这两行:

To display the wiki in an iframe, you have to find the file "mediawiki-1.xx \ skins \ common \ wikibits.js "and comment out these two lines:

/ / A-trap us from framesets
if (window.top! = window)
window.top.location = window.location;

这是不允许wiki显示的代码。
此处查看。

This is the code that doesn't allow the wiki to show. Seen in here.

这篇关于在iframe中显示mediawiki的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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