Hi everyone!
I have tried the code before and after some code WordPress automatically writes to my .htacces file in the virtual servers’s public_html directory, and it breaks the site.
Here is the WordPress code:
# 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>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
I have also tried
RewriteEngine ON
RewriteCond %{HTTP_HOST} ^url\.tlp$
RewriteRule (.*) http://www.url.tlp/$1 [R=301,L]
but these also broke the site infront and after the WordPress bits.
I have tried taking the constant [L] out of the code so Apache, when placing it in front of the WordPress bit so it is not the last directive it reads … and then I got a 301 Error with a link that loops.
# Moved Permanently
The document has moved [here](looping link).
Additionally, a 301 Moved Permanently error was encountered while trying to use an ErrorDocument to handle the request.
This I also tried just using:
Redirect 301 http://url.tlp http://www.url.tlp
and the browser just displays the url with no www in front.
I am also trying to understand the language of Apache directives … but I have read the language is just called Apache? And I have found this chart
Special Symbols:
Symbol Meaning
^ Start of the string
$ End of the String
Or [a b] – a or b
[a-z] Any of the letter between a to z
- One or more occurrence of previous letter
- Zero or more occurrence of previous letter
? Zero or one occurrence of previous letter
Constants and their meaning:
Constant |
Meaning |
NC |
No-case or case sensitive |
L |
Last rule – stop processing further rules |
R |
Temporary redirect to new URL |
R=301 |
Permanent redirect to new URL |
F |
Forbidden, send 403 header to the user |
P |
Proxy – grab remote content in substitution section and return it |
G |
Gone, no longer exists |
S=x |
Skip next x rules |
T=mime-type |
Force specified MIME type |
E=var:value |
Set environment variable var to value |
H=handler |
Set handler |
PT |
Pass through – in case of URL’s with additional headers. |
QSA |
Append query string from requested to substituted URL |
That helps understanding some of your code @DrCarsonBeckett, but I have no idea what the % or the ! do or what [HTTP_HOST] might be … I am so lost. 
I think it is very strange that the WordPress directives have to directives with the [L] constant.