Joomla!, Wordpress tips for building your site

How to disallow by iframe tag

Published on| January 14th, 2010 | No Comment.

If your site is very famous site, it might be copied by the bad.
In addition, the bad might quote your site by iframe tag without copying it.

I found the script that the bad can not quote your site.
Following content might help you.

java script

You should set the following codes after body tag.

<script type="text/javascript">
if (window.top !== window.self) {
	document.write = "";
	window.top.location = window.self.location;
	setTimeout(function() {
		document.body.innerHTML='';
		}, 1);
	window.self.onload = function(evt) {
		document.body.innerHTML='';
	}
}
</script>

OK.
This code will redirect to your page URL if your page URL do not equal request URL.

You must see that you will get good result only access from users that enabled java script by this way.
Another way will use ‘.htaccess’ file.
So, it will control that allow of access to directory.






Comments

Leave a Reply








Transrator

Recent Posts

Categories

Tag Cloud

execute remove フロントページ 投稿ページ トップページ install WIndows Note Convert META generator 日付 donwload file manage multibyte utf-8 unicode shiftjis euc console サイトマップ 問題 ParmaLink Redirect パーマリンク はみ出る pre テンプレート テーマ タグクラウド マルチランゲージ リダイレクト PHP(タグ) タグ table control HTML(タグ) コマンド 国際化(翻訳) SQLite(タグ) MySQL(タグ) qTranslate プラグイン(タグ) Wordpress(タグ)

Links

Site Description

Joomla!, Wordpress as CMS using a site building, site management, software usage to describe the development tips.

  • はてなブックマークへ追加する
  • Facebookでシェアする
  • twitter でつぶやく
  • Google Plusでシェアする
  • Pocketでシェアする
ページトップへ