Welcome Guest, Not a member yet? Register   Sign In
What's the path for robots.txt ?
#1

[eluser]chefnelone[/eluser]
hello,

Where should I put the robots.txt file?
In application/views ?
If that's correct should I do something else?
#2

[eluser]danmontgomery[/eluser]
robots.txt should be in the web root, most likely the same location as codeigniter's index.php
#3

[eluser]chefnelone[/eluser]
thanks noctrum

so, there's nothing to do in .htaccess?
#4

[eluser]chefnelone[/eluser]
and the sitemap.xml goes also in the root?
#5

[eluser]danmontgomery[/eluser]
[quote author="chefnelone" date="1271359933"]thanks noctrum

so, there's nothing to do in .htaccess?[/quote]

You should add it to the rewritecond so it never gets routed... Mine looks like this:

Code:
# Allow these directories and files to be displayed directly:
RewriteCond $1 ^(index\.php|robots\.txt|favicon\.ico|assets)

# No rewriting
RewriteRule ^(.*)$ - [PT,L]

[quote author="chefnelone" date="1271360139"]and the sitemap.xml goes also in the root?[/quote]

Yep
#6

[eluser]chefnelone[/eluser]
[quote author="noctrum" date="1271360652"][quote author="chefnelone" date="1271359933"]thanks noctrum

so, there's nothing to do in .htaccess?[/quote]

You should add it to the rewritecond so it never gets routed... Mine looks like this:

Code:
# Allow these directories and files to be displayed directly:
RewriteCond $1 ^(index\.php|robots\.txt|favicon\.ico|assets)

# No rewriting
RewriteRule ^(.*)$ - [PT,L]

[quote author="chefnelone" date="1271360139"]and the sitemap.xml goes also in the root?[/quote]

Yep[/quote]

thanks




Theme © iAndrew 2016 - Forum software by © MyBB