sforum
Active member
I have installed XenForo in a folder called xf in the root of my domain, just to maintain flexibility in case I want to use the domain for something else in the future.
At the moment, when you go to www.mydomain.com, I have the following simple index.php:
So, as you can see, when you go to www.mydomain.com you are immediately redirected to www.mydomain.com/xf and everything works just fine.
However, I'm guessing that this is pretty terrible from an SEO point of view; is that right? Should I have anything else in there? What about all the usual "DOCTYPE" and "meta" shenanigans that you normally see at the top of an HTML page; should I have some of that in there? If so, what?
TL;DR = Would anyone be kind enough to show a n00b like me exactly what code would be in an ideal index.php in order to redirect to the installation sub-folder, including any important "behind the scenes" gubbins?
Thanks
At the moment, when you go to www.mydomain.com, I have the following simple index.php:
PHP:
<?php
/* Redirect browser */
header("Location: http://www.mydomain.com/xf");
/* Make sure that code below does not get executed when we redirect. */
exit;
?>
However, I'm guessing that this is pretty terrible from an SEO point of view; is that right? Should I have anything else in there? What about all the usual "DOCTYPE" and "meta" shenanigans that you normally see at the top of an HTML page; should I have some of that in there? If so, what?
TL;DR = Would anyone be kind enough to show a n00b like me exactly what code would be in an ideal index.php in order to redirect to the installation sub-folder, including any important "behind the scenes" gubbins?
Thanks