Thank you for trying to help me clear up my cloud of confusion over this.
The user would not be entering any values. They would just be clicking on a menu selection.
Here is the current page I am re-designing: www.minisgallery.com
I have a hierarchical menu selection which consists of intermixed sub-menus and gallery selections (i.e. “Dungeons and Dragons” will take you to a sub-menu, where-as “Oriville Heroclix” will take you to the gallery since there are no other sets associate with this product line.
The routing is essentially handled by a pages table where I record the type of link (menu or site), the id# from the either the menu table or the sets table, the display order (if any), parent menu id# from the pages table.
I mainly want clean URL’s for SEO purposes. (Although I have read mixed opinions as to whether stripping the URL variable passing makes SEO better).
Ideally, the pretty URL would change, depending what I am trying to produce on the index page:
Menu example:
www.minisgallery.com/menu/dungeons-and-dragons-icons-of-the-realms
When the user clicks on a menu selection, then I want to detect that if the first “/” is followed by “menu”, to trigger the menu section of the index page, and build out a menu of the children from the pages table that are associated with the parent menu for “dungeons-and-dragons-icons-of-the-realms”.
Gallery example:
www.minisgallery.com/gallery/critical-role/monsters-of-taldorei
When a user clicks on a gallery selection (for a specific set), then I want to detect that the first “/” is followed by “gallery”, to trigger the gallery section of the index page, and build out the gallery for this set. From this URL I want to extract the middle element of “critical-role” as that will correspond to a value in the product line table, and to extract the last element of “monsters-of-taldorei” as that will correspond to the name of the set.
If the rewrite rule is changed to “RewriteRule . /index.php [L,QSA]”, then I’m not sure what I need to do next. Does this mean that any URL with a “/” in it is going to be referred back to the index.php page, and then I use coding on the index page to extract the elements between the slashes, to determine what gets displayed on the index page?