How can I create a URL that doesn't really exist? For example, https://twitter.com/i/notifications - works. When you remove the /notifications from the link you get https://twitter.com/i/ - Does not work. but this URL /i/ doesn't really exist.
How do I make something like that?
You can create an .htaccess file that routes ALL requests through a single PHP file and then use the logic in that PHP file to determine whether the url exists or not. For example, you could use my CodeIgniter .htaccess file:
This lets you still specify images, css, js, etc. that doesn't get remapped but any urls that don't start with those strings will be routed to index.php. Within index.php, you can inspect the query string to determine how to handle the urls and decide if they exist or not.