In view I want to show image which is store in view folder named Errorpage.png. Now, I want to show that image in Error.cshtml view file.
Here is my code
<img src="~/Views/Errorpage.png" alt="error">
Now , this code is not working and showing error alt in the place of image. While the path is perfectly right, but surprised that why it is not working.
While I tried by fetch the online image and that is work.
Here is the code
<img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/4273/anton-ploom.jpg"
alt="A danseur in brisé (a leap with the legs together) on a blue background">
Now, I am confused that this second code is working properly while the first code is not working.
The syntax is same both of the code.
Thank You.