NoWar
NoWar

Reputation: 37633

How to see simple txt files under ASP.NET MVC website

I use NLog to generate log files under log folder and file name looks like 2014-01-16.txt.

I would like to access it somehow i.e.

http://localhost:20168/log/2014-01-16.txt

Is it possible to configure somehow?

Thanks!

Upvotes: 1

Views: 113

Answers (1)

vmg
vmg

Reputation: 10566

You could configure your routing to ignore txt files:

routes.IgnoreRoute("log/{file}.txt");

Upvotes: 3

Related Questions