Server-side redirects are useful when the destination is determined by application logic rather than by a link the visitor clicked. Common cases include successful form processing, access control, login flows, and moving a visitor to a canonical or replacement page.
<%@ Language=VBScript %>
<%
Response.Redirect "basic.php"
%>Use a fixed relative destination before any output is sent. Response.Redirect normally sends a redirect response that the browser follows.
A redirect changes HTTP response headers. Decide the redirect before output has been flushed to the browser. With buffering enabled, generated content can still be held on the server until the redirect decision is made.
Prefer fixed internal destinations. If redirect targets come from user input, validate against a strict allowlist; run Response.Redirect before writing output.
Author & Instructor at plus2net
I write and maintain practical tutorials on Python, PHP, SQL, JavaScript, HTML, jQuery, and web development at plus2net. The tutorials focus on clear explanations, working examples, and code that readers can test and adapt while learning.