Use the latest WP Socializer version.
You need to do the domain name change work in the “wp-socializer.php” file.
The function “wpsr_get_post_details()” sends the post details to the share buttons.
So inside that function in line 1174 (as of v2.4.5) add your post URL changing code block like this
/******* TO CHANGE THE POST URL (obtained from encosia.com ) ***/
// Changed URL structure from /yyyy/mm/dd/slug to /slug on
// 5/28/2011. This ensures older posts still present the old URLs
// to sharing services so that share counts are maintained.
$url_change_date = strtotime(“5/28/2011”);
$post_date = strtotime(get_the_date());
$post_url = get_permalink($post->ID);
if ($post_date < $url_change_date) {
$url_date_prefix = "/" . date("Y", $post_date) .
"/" . date("m", $post_date) .
"/" . date("d", $post_date);
$permalink_inside_loop = str_replace("://encosia.com",
"://encosia.com" . $url_date_prefix,
$post_url);
}
/*********************** END *************************************************/
The actual concept is to store the “$permalink_inside_loop” variable with tweaked URL thats all.