2020-04-20 14:18:35 +00:00
|
|
|
package main
|
|
|
|
|
2020-05-08 15:52:17 +00:00
|
|
|
/* Function does, as function is named */
|
2020-04-20 14:18:35 +00:00
|
|
|
func generateHtmlRedirect(url string) []byte {
|
|
|
|
content :=
|
|
|
|
"<html>\n"+
|
|
|
|
"<head>\n"+
|
|
|
|
"<meta http-equiv=\"refresh\" content=\"1;URL="+url+"\">"+
|
|
|
|
"</head>\n"+
|
|
|
|
"<body>\n"+
|
|
|
|
"You are following an external link to a web site.\n"+
|
|
|
|
"You will be automatically taken to the site shortly.\n"+
|
|
|
|
"If you do not get sent there, please click <A HREF=\""+url+"\">here</A> to go to the web site.\n"+
|
|
|
|
"<p>\n"+
|
|
|
|
"The URL linked is <A HREF=\""+url+"\">"+url+"</A>\n"+
|
|
|
|
"<p>\n"+
|
|
|
|
"Thanks for using Gophor!\n"+
|
|
|
|
"</body>\n"+
|
|
|
|
"</html>\n"
|
|
|
|
|
2020-04-20 20:28:20 +00:00
|
|
|
return []byte(content)
|
2020-04-20 14:18:35 +00:00
|
|
|
}
|