Do you mean the current page? If the page is not going to be retrieved there's nothing to be displayed, so you can't display a message for that, but you could use Ajax for another page and check the status of the response. If it's 200 (OK), then the page can be retrieved. See "Does a URL exist?" section on this page.
Comment