Hi All,
When accessing https://ww3.rics.org/robots.txt the browser doesn't actually display the file but download it. Could you please suggest me how can I fix it?
I am accessing the robots.txt file from dispatcher caches.
Thanks,
Niraj.
Solved! Go to Solution.
Views
Replies
Total Likes
hi @user00181 ,
The above solution will work, but if you don't want to make changes to the configuration file, you can add a rule at your dispatcher for a specific file so that it will open in the browser instead of downloading.
<FilesMatch "\.robots.txt$"> Header set Content-Disposition "inline" Require all granted </FilesMatch>
Hi @user00181 ,
Your robot.txt resource file by default have jcr:data property or jcr:content/jcr:data which has an header with value as "attachment".
You need to make an entry (exclude entry to not have the Content-Disposition as attachment)
Regards,
Santosh
hi @user00181 ,
The above solution will work, but if you don't want to make changes to the configuration file, you can add a rule at your dispatcher for a specific file so that it will open in the browser instead of downloading.
<FilesMatch "\.robots.txt$"> Header set Content-Disposition "inline" Require all granted </FilesMatch>
Hi @Anish-Sinha
Thank you for solution,
I am new in AEM where i need to add this rule . Actually I am using AEM 6.5 version.
There are already some rule are available for robots.txt file.
Please check this Screenshot, in this code what i need to change or add so the robots.txt fill will open.
Thanks,
Niraj Singh
I don't really have idea on dispatcher. Not sure which file I need to make this change into.
Views
Replies
Total Likes
Views
Likes
Replies