What the codes above will do is to redirect all request to the index.php. index.php now will serve as the executor of our made-up function. I will also provide you the function later on.
Step TWo: Create another file called index.php, paste the codes below and save it in the example.com directory ( normally, this is in public_html).
$url_segments = array();
$url_request = $_SERVER['REQUEST_URI'];
$url_segments = explode("/", $url_request);
$file_name = pathinfo($url_segments, PATHINFO_FILENAME);
## now we define the actual page location
$actual_file_location = './mtfiles/2014/';
## we call the function above
$this_short_url = ((process_url($actual_file_location) != false)? include(process_url($actual_file_location)) : 'page not available');
I need to make some short explanation on what I just did above. The url segments array split the url into segments. So, for the uri request http://example.com/2014.html $url_segments, will approximately give us the script name which is 2014.html. We further process this information, so that we can include the actual document located in /mtfiles/2014/ directory. I used exploded and pathinfo PHP functions to do this.
The function will check if the file exists in the actual file directory and if it is, the function will return that as string.
Just below the function, I called the function process_url() and providing the actual file location as param.
Step Three: open the mtfiles/2014 directory and create a new 2014.php file. To test it put something like this
Honestly, the last time I have seen plesk parallel was 5 years ago. I can't even recall what is the httpd.conf and vhost equivalent for it. However, I am pretty sure there is some type of server configuration file that can enable rewrite_module.
Can you check with your host what modules are installed on your server as far as rewriting?
You've mentioned about the web.config file. Can you please let me know if you have PHP parser installed on your server? I just want to make sure.
Here is a very nice reference in working with web.config file as a url prettifier.
can you run this scripts on your server? save this as test.php
echo 'Server Request URI .'.$_SERVER['REQUEST_URI'];
Direct your browser to test.php. and let me know what did you see.
The reason I am making you test it like this, because I might be able to write something that don't even need .htaccess, but I cannot guarantee that it will work.