top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

What is Razor ?

+3 votes
248 views

Why Razor when we already have ASPX?

posted Feb 21, 2014 by Muskan

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

0 votes

Razor is clean, lightweight and syntax is easy as compared to ASPX.

For example, in ASPX to display simple time, we need to write:

<%=DateTime.Now%> 

In Razor, it’s just one line of code:

@DateTime.Now
answer Feb 25, 2014 by Sanketi Garg
...