My HTACCESS code is this
ErrorDocument 404 /404.php
It is working well. What I want is when some one types a bad URL like (www.website.com/sometest.html)
In the case that "sometest.html" page does not exit and it will re-direct to the 404 page. But how can I detect what URL they typed? I want to get this: www.website.com/sometest.html
I have tried $_SERVER['HTTP_REFERER']
and $_SERVER["REQUEST_URI"];
both can't get the output that I'm looking for.