1

I am setting up a new Plesk account and want to add a custom error document, 404, specifying a URL to a PHP file.

In another account, which uses an earlier version of Plesk (v10, if not mistaken), the following method works, just not in Plesk 11.

  1. Go to Websites & Domains | Virtual Directories
  2. [Manage] for domain
  3. Select 'Error Documents' tab
  4. Click on All | click on 404
  5. Select Url as the Type
  6. Type in '/Index.php' as the Location
  7. List item

Note, file is in root of the selected domain.

Received error:

Error: Wrong URL format. Please enter an absolute URL within the virtual host (site).
Location is highlighted

In previous versions of Plesk, or at least in the other account, specifying "/Index.php" worked.

If I were using ASP.Net, I could probably modify the web.config file, however I am using PHP here, not ASP.Net.

Thoughts?

mate64
  • 1,641
  • 4
  • 18
  • 29
Sarah Weinberger
  • 421
  • 2
  • 9
  • 23

1 Answers1

1

Well, it looks like behaviour was changed. What about add permanent redirect in not_found.html file or use absolute URL to index.php?

Oleg Neumyvakin
  • 599
  • 4
  • 15
  • I was able to add in an absolute path in the form, http://www./Index.php, however I have a couple of URLs that use the same domain name and I was hoping to keep a relative path. using the http://www.domain1.com/Index.php will redirect users from http://www.domain2.com. I thought of this answer yesterday, but did not try it. I added that in for now. – Sarah Weinberger Jun 12 '13 at 17:50