0

Let me try to explain the issue facing in razor pages asp.net core. I have a dynamic link on my page. Please refer the below screen shot for that. enter image description here

When I first time click and use this url - it hit the backend OnGet Action method and I get expected result. But once I was resulted into an exception and I have received an error.

Since then if same dynamic url is passed, I get the same page again and again.

Seems page / action is being cached in asp.net core but I am unable to make a fresh call. Can someone help me? Please.

Narender Kumar
  • 121
  • 1
  • 9
  • maybe you created a bad url.you can disable cache in browser https://stackoverflow.com/questions/38231739/how-to-disable-browser-cache-in-asp-net-core-rc2 – abolfazl sadeghi May 02 '23 at 15:12
  • This is not bad url. this url is being generated dynamically and at the page load based on queryString parameter, request get processed. if one scenerio, a exception has come so now if the dynamic url is same.. without executing.. I see the same error. I have tried the solution posted on the motioned url before posting the question. – Narender Kumar May 02 '23 at 15:53
  • can you disable cache with this is site https://stackoverflow.com/questions/38231739/how-to-disable-browser-cache-in-asp-net-core-rc2 – abolfazl sadeghi May 02 '23 at 17:17
  • if you want to disable cache, comments above already provided related answers. If they didn't work, then you may provide a minimal sample to reproduce the issue. – Tiny Wang May 03 '23 at 06:05

0 Answers0