gf: Index | Files

package gurl

import ""

Package gurl provides useful API for URL handling.


Package Files


func BuildQuery Uses

func BuildQuery(queryData url.Values) string

Generate URL-encoded query string. See

func Decode Uses

func Decode(str string) (string, error)

url decode string

func Encode Uses

func Encode(str string) string

url encode string, is + not %20

func ParseURL Uses

func ParseURL(str string, component int) (map[string]string, error)

Parse a URL and return its components. -1: all; 1: scheme; 2: host; 4: port; 8: user; 16: pass; 32: path; 64: query; 128: fragment. See

func RawDecode Uses

func RawDecode(str string) (string, error)

Decode URL-encoded strings. See

func RawEncode Uses

func RawEncode(str string) string

URL-encode according to RFC 3986. See

Package gurl imports 2 packages (graph) and is imported by 4 packages. Updated 2019-06-20. Refresh now. Tools for package owners.