0
1
llucycodes42
The code tells the web browser to take the request to the specified URL, but instead of rendering the page, to take the request to the Redirect resource instead. The Redirect resource is responsible for handling the status code and redirecting the browser to the appropriate page. The code uses the http.StatusFound status code to indicate that the requested page was found.
Shortcut: rd
http.Redirect(w, r, "/", http.StatusFound)