开发者

Embedding an edit page from mediawiki using iframe

开发者 https://www.devze.com 2023-04-01 03:22 出处:网络
I 开发者_JAVA百科tried to embed an edit page in a MediaWiki-powered site, but the problem is that a blank page is given.

I 开发者_JAVA百科tried to embed an edit page in a MediaWiki-powered site, but the problem is that a blank page is given.

Note: the same thing occurs when I try to embed a sign in page.

For example:

 <iframe src="http://www.wikilogia.net/w/index.php?title=IT_for_Masses&action=edit">
 </iframe>


I've been scratching my head with the same problem. Viewing pages worked fine but when I tried to do any editing or use login forms etc, I would just get a blank response. To fix it, just add the following lines to your LocalSettings.php:

$wgBreakFrames = false;
$wgEditPageFrameOptions = 'SAMEORIGIN';

For more, see the manual: https://www.mediawiki.org/wiki/Manual:$wgEditPageFrameOptions


Some sites prevent you from putting them in an iframe.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号