I am creating an ASP.NET 5 Blazor Server application with MudBlazor.
I have a URL https://localhost:44324/OperationsAll?Proj_ID=23407&Tail_Nr=TG6R&Location=N.
The query string is used to initialize the data on the OperationsAll page.
It works great in the prerender stage of the lifecyle, retrieving the query string and initializing the page with the correct data in the Oninitialized() method.
In the render stage of the lifecycle when Oninitialized() is run again, the query string has changed to 'https://localhost:44324/OperationsAll?id=1234ASSAf31', with the id always being something different. This, of course, then causes the page to not have the required data for the final render of the page.
An interesting bit of information is that the query string is not being replaced in the web browser address bar, that still remains as https://localhost:44324/OperationsAll?Proj_ID=23407&Tail_Nr=TG6R&Location=N. The query string is being replaced with the random ?id=ASDF!1234 within the HttpContext.
Why is the query string being replaced?
How do I keep the query string from changing during the page lifecycle?
Oninitialized()is called for the second time, does your retrieval string change automatically? I don't have your situation, can you provide some code to reproduce the problem?HttpContext?