Do not ever use the guid element for creating links – ever – ever

I was recently (I always seem to start posts with that phrase) learning how to update a clients posts post_title, slug (aka post_name in the db) and guid when a post title was changed programatically. I was using get_sample_permalink() in combination with wp_update_post() to generate a permalink and update the post guid along with the … Continued