go-wordpress
go-wordpress copied to clipboard
Why Tags are int ?
trafficstars
Hi, i think in wordpress are Tags normaly "strings" why i should put a slice of ints to the tags when i create a post?
Tags []int json:"tags,omitempty"
How does it work?
I want to tag my post with "apple, banana, test" and so on.
I believe it's because the tags in this case are integer primary keys.
@robbiet480 do you have an idea how i can achive this?
// create non existent tags or take existent and put id to int slice func SetOrCreateTags(tags []strings) *[]int {}
@n0v3xx I'm sorry, i'm not in a position to help as I no longer use this library, let alone WordPress.