israfil isler
israfil isler

Reputation: 45

How to disable or remove web pages from my web site

I want to block or delete some pages on my website. Maybe these pages can be used again in the future, so I don't want to delete them directly and I want to prevent users from accessing these pages via URL or my website. I searched a bit but couldn't find much detail.

Could you suggest me what I can do about it?

Upvotes: 1

Views: 811

Answers (2)

Bruce Zhang
Bruce Zhang

Reputation: 3042

I don't want to delete them directly and I want to prevent users from accessing these pages via URL or my website

If you want to set it in IIS, Request filtering is a great choice for you. You can add any URL in it to prevent others access it and don't need to delete physical file.

Now I can access it.

enter image description here

Add a deny sequence. enter image description here

Now I cannot access.(Same URL) enter image description here

Upvotes: 0

lolmhhh3
lolmhhh3

Reputation: 1

You could add a script element to the header for your HTML and have the script be,

location.href = "homepage.location/";

Upvotes: -1

Related Questions