I'm trying to replace all the instances of | in a string with \| but when I try to do:
strings.Replace(f, "|". '\|', -1)
I get: expected selector or type assertion, found 'CHAR' ' \| ' error.
use this:
strings.Replace(f ,"|", `\|`, -1)
example:
http://play.golang.org/p/EQFR2EX5Bi