cookieutil

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2019 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package cookieutil implements functions for working with http cookie.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteCookie

func DeleteCookie(rw http.ResponseWriter, req *http.Request, key string) error

DeleteCookie deletes cookie for specified key.

func GetCookieValue

func GetCookieValue(req *http.Request, key string) (string, error)

GetCookieValue returns cookie value for specified key.

func SaveCookie

func SaveCookie(rw http.ResponseWriter, key string, value string)

SaveCookie saves cookie with specified key and value.

func SetExpiration

func SetExpiration(duration string) error

SetExpiration sets cookie duration expiration for SaveCookie func.

Types

This section is empty.

Jump to

Keyboard shortcuts

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