jquery - How to secure knockout template? -


I am using the next code to load the template dynamical:

  $ ("Templates.html")}}   

Can the template content be protected from public load in any way? I am using ASP.NET MVC etc.

Instead of creating a physical file, create an action that templates in one of your views. You can use AuthorizeAttribute or you can use any other medium to secure your operation.

Action replacing template.html with the url pointing to the url.

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -