This article is a mirror article of machine translation, please click here to jump to the original article.

View: 41330|Reply: 1

[ASP.NET] ASP.NET Core gets the request full URL link

[Copy link]
Posted on 5/10/2021 1:10:32 PM | | | |
In production, we sometimes need to record the full URL link of the current request as follows:




You can also install the Microsoft.AspNetCore.Http.Extensions plugin with the following command:

The plugin Microsoft.AspNetCore.Http.Extensions.UriHelper has an extension method for GetDisplayUrl, the code is as follows:

The source code is as follows:

The hyperlink login is visible.

(End)




Previous:.NET Core implements distributed locks based on Redis Lua [with source code]
Next:Ocelot Request headers must contain only ASCII characters
Posted on 4/8/2022 1:53:13 PM |
See if that helps
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com