string_sanitisation.go 306 Bytes
package webutility

import "strings"

var patern string = "\"';&*<>=\\`:"

// SQLSafeString removes characters from s found in patern and returns new modified string.
func SanitiseString(s string) (safe string) {
	for _, c := range patern {
		safe = strings.Replace(s, string(c), "", -1)
	}
	return safe
}