I have a gate mounted to a 6x8 post where the center has rotted out of the post. I am looking to fill the center of the post, rather then replace it if I could. The post itself is still solid, just hollow so the mount bolt have nothing to connect to anymore. I am thinking to try the expanding post foam inside the post, but have not worked with it and I have no reference if it would be stong enough to hold a bolt.
I’d replace the post.
The foam might work for a hot minute but I’m not even convinced of that. I’d think the stress from the weight of the gate will cause it to fail rather quickly.
If the hollow is up in an area where the hinges attach you might split the post with the foam expanding as it cures.