XF 1.2 Robots.txt file/page and mod rewrite

BuildBridges

Active member
Under Robots.txt Options in XENFORO control panel, this appears on top of the page.
You can have XenForo generate the robots.txt file for you. Please note for this to work, you need to do a mod rewrite that goes: robots.txt => index.php?xfa-robots/index

Does this mean that this goes into the .HTACCESS file in the forums' root folder?

And if so, what exactly is put into the HTACCESS file?

Is this the statement?

Code:
RewriteCond robots.txt => index.php?xfa-robots/index   ??

Or do I just drop in

Code:
robots.txt => index.php?xfa-robots/index

Any insight would be great, thank you.
 
Ya that's not default. I remember not seeing it in the previous version, and I am running the latest Beta and it's not in there. So ya I am pretty sure it's an addon. For robots.txt I just created one and uploaded it to the forum root.
 
Look in the add-on discussion area. If I remember correctly there are examples in there for both Apache and nginx in the thread.
Not that it will do you any good since it is nginx related, but mine is
Code:
rewrite /(robots.txt)$ /robots.php last;
in the vhost config file.
 
Top Bottom