I have a WordPress page with the following structure website.com.au/pre-registration/parameter-value/
, where the parameter value was originally a GET parameter, but I was requested to make it part of the URL.
How do I make my .htaccess understand that he must disregard the last part and led the user to website.com.au/pre-registration
instead of returning a 404? Ideally, it will still display the whole URL, but load only website.com.au/pre-registration
Tried many possibilities I found on the web, but none worked.
My .htaccess looks like this at the moment:
# BEGIN WordPress
# The directives (lines) between "BEGIN WordPress" and "END WordPress" are
# dynamically generated, and should only be modified via WordPress filters.
# Any changes to the directives between these markers will be overwritten.
<IfModule mod_rewrite.c>
Header set Access-Control-Allow-Origin "*"
Header set Access-Control-Allow-Methods "GET,PUT,POST,DELETE"
Header set Access-Control-Allow-Headers "Content-Type, Authorization"
RewriteEngine On
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
.htaccess
. This needs to be asked on wordpress.stackexchange.com, but you would need to remove the ".htaccess
" aspect to make it on-topic.