I have a website/server where I would like the following to happen.
- If a person types the URL: http://mydomain.com/apple it should go to: http://mydomain.com/pickfruit.php?a=apple
- And if they enter: http://mydomain.com/pear it goes to: pickfruit.php?a=pear
- I also have the need for the ability of legit sub-directories to exist. For example, http://mydomain.com/admin would to take you into that sub-directory and would NOT redirect to pickfruit.php?a=admin.
So what I am looking for is a solution where I do not have to create all of the individual fruit directories and then put a header redirect in each directory.
I assume this can be done with the .htaccess file or something like that? Any insight would be appreciated. I can use .php if that helps as well.