RewriteOptionsExtensions.AddRedirect Metode
Definisi
Penting
Beberapa informasi terkait produk prarilis yang dapat diubah secara signifikan sebelum dirilis. Microsoft tidak memberikan jaminan, tersirat maupun tersurat, sehubungan dengan informasi yang diberikan di sini.
Overload
AddRedirect(RewriteOptions, String, String) |
Alihkan permintaan jika regex cocok dengan PathString HttpContext |
AddRedirect(RewriteOptions, String, String, Int32) |
Alihkan permintaan jika regex cocok dengan PathString HttpContext |
AddRedirect(RewriteOptions, String, String)
- Sumber:
- RewriteOptionsExtensions.cs
- Sumber:
- RewriteOptionsExtensions.cs
- Sumber:
- RewriteOptionsExtensions.cs
Alihkan permintaan jika regex cocok dengan PathString HttpContext
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::AspNetCore::Rewrite::RewriteOptions ^ AddRedirect(Microsoft::AspNetCore::Rewrite::RewriteOptions ^ options, System::String ^ regex, System::String ^ replacement);
public static Microsoft.AspNetCore.Rewrite.RewriteOptions AddRedirect (this Microsoft.AspNetCore.Rewrite.RewriteOptions options, string regex, string replacement);
static member AddRedirect : Microsoft.AspNetCore.Rewrite.RewriteOptions * string * string -> Microsoft.AspNetCore.Rewrite.RewriteOptions
<Extension()>
Public Function AddRedirect (options As RewriteOptions, regex As String, replacement As String) As RewriteOptions
Parameter
- options
- RewriteOptions
- regex
- String
String regex untuk dibandingkan.
- replacement
- String
Jika regex cocok, apa yang harus diganti dengan uri.
Mengembalikan
Opsi Penulisan Ulang.
Berlaku untuk
AddRedirect(RewriteOptions, String, String, Int32)
- Sumber:
- RewriteOptionsExtensions.cs
- Sumber:
- RewriteOptionsExtensions.cs
- Sumber:
- RewriteOptionsExtensions.cs
Alihkan permintaan jika regex cocok dengan PathString HttpContext
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::AspNetCore::Rewrite::RewriteOptions ^ AddRedirect(Microsoft::AspNetCore::Rewrite::RewriteOptions ^ options, System::String ^ regex, System::String ^ replacement, int statusCode);
public static Microsoft.AspNetCore.Rewrite.RewriteOptions AddRedirect (this Microsoft.AspNetCore.Rewrite.RewriteOptions options, string regex, string replacement, int statusCode);
static member AddRedirect : Microsoft.AspNetCore.Rewrite.RewriteOptions * string * string * int -> Microsoft.AspNetCore.Rewrite.RewriteOptions
<Extension()>
Public Function AddRedirect (options As RewriteOptions, regex As String, replacement As String, statusCode As Integer) As RewriteOptions
Parameter
- options
- RewriteOptions
- regex
- String
String regex untuk dibandingkan.
- replacement
- String
Jika regex cocok, apa yang harus diganti dengan uri.
- statusCode
- Int32
Kode status untuk ditambahkan ke respons.
Mengembalikan
Opsi Penulisan Ulang.