Detect what page was linked-from

To encode the URLs on the source page, in this case ‘home’: function append_query_string( $url, $post, $leavename ) { if ( $post->post_type == ‘post’ ) { $url = add_query_arg( ‘source’, ‘home’, $url ); } return $url; } add_filter( ‘post_link’, ‘append_query_string’, 10, 3 ); This adds ?source=home to the end of post link URLs on the … Read more

WordPress link management

You could create a single wordpress page with a PHP or meta redirect to the final URL. Then each of your blog posts would link to that single page. It would work, but I reckon that once you got past about 50 or so outgoing link pages it would get pretty hard to manage easily. … Read more