An Phan
An Phan

Reputation: 2568

Access existing HTML files in a Sitecore installation?

With virtually any PHP CMS you can easily access the existing files using .htaccess rules, when leaving the rest of the requests handled by the index.php file. Something like this:

RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]

How do I achieve the same in a .NET env, specifically Sitecore? So that I can upload, say, static.html to the root folder and it will be accessible at http://www.example.com/static.html?

Thanks in advance.

Upvotes: 0

Views: 1314

Answers (2)

Ahmed THADI
Ahmed THADI

Reputation: 231

just put your static.html file in the website folder or any subfolder it should be fine.

and if you have a multiple website in your sitecore instance, your html file will be accessible from all website

Upvotes: 2

Matthew Dresser
Matthew Dresser

Reputation: 11442

It is the default behaviour of Sitecore to serve real files from the webroot, so you shouldn't have to change anything for it to do this.

Upvotes: 0

Related Questions