handlers

package
v0.0.31 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2021 License: GPL-2.0, GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddURL

func AddURL(w http.ResponseWriter, r *http.Request)

AddURL adds a URL to the short urls list and returns the assigned short url

func GetURL

func GetURL(w http.ResponseWriter, r *http.Request)

GetURL redirects to the full URL from the given shortURL if no url is assigned or the short URL is not valid it rick rolls the caller :)

func GoogleLogin added in v0.0.2

func GoogleLogin(w http.ResponseWriter, r *http.Request)

GoogleLogin handles login using google authentication

func HandleAbout added in v0.0.2

func HandleAbout(w http.ResponseWriter, r *http.Request)

HandleAbout renders the about page

func HandleCallback added in v0.0.2

func HandleCallback(w http.ResponseWriter, r *http.Request)

HandleCallback is called when authenticating with google

func HandleHome added in v0.0.2

func HandleHome(w http.ResponseWriter, r *http.Request)

HandleHome renders the shortening page of a specific or an anonymous user

func HandleTracking added in v0.0.2

func HandleTracking(w http.ResponseWriter, r *http.Request)

HandleTracking renders the URLs tracking page of a specific user

func HandleUserInfo added in v0.0.2

func HandleUserInfo(w http.ResponseWriter, r *http.Request)

HandleUserInfo renders the user info page

func RickRoll

func RickRoll(w http.ResponseWriter, r *http.Request)

RickRoll redirects to Rick Astley's - Never Gonna Give You Up YT Video, perfect RickRolling :)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL