Server-side Redirect - Code

Code

PHP code for server-side redirect.

header("Location: http://www.example.com/");

ASP.NET code for server-side redirect.

Response.AddHeader("Location: http://www.example.com/");

Implementation in JavaServer Pages (JSP).

response.setHeader("Location", "http://www.example.com/");

Read more about this topic:  Server-side Redirect

Famous quotes containing the word code:

    Faultless honesty is a sine qua non of business life. Not alone the honesty according to the moral code and the Bible. When I speak of honesty I refer to the small, hidden, evasive meannesses of our natures. I speak of the honesty of ourselves to ourselves.
    Alice Foote MacDougall (1867–1945)

    Hollywood keeps before its child audiences a string of glorified young heroes, everyone of whom is an unhesitating and violent Anarchist. His one answer to everything that annoys him or disparages his country or his parents or his young lady or his personal code of manly conduct is to give the offender a “sock” in the jaw.... My observation leads me to believe that it is not the virtuous people who are good at socking jaws.
    George Bernard Shaw (1856–1950)