Answer the question
In order to leave comments, you need to log in
How to handle cookies in Golang Gorilla?
Hello got user cookie when registering now cookie.Values[id]=id. Now this user wants to write an article. I need to take his username from the cookie in order to assign the article to him. But when receiving cookies, they come in the form of an interface, although when determining the type it shows that it is a string type. How do I get the id from the cookie as a string and not as an interface, or how do I handle the interface, or should there be another approach? Post examples if possible.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question