Quantcast
Channel: WordPress.org Forums » [Jetpack - WP Security, Backup, Speed, & Growth] Support
Viewing all articles
Browse latest Browse all 36984

salabinha on "[Plugin: Jetpack by WordPress.com] sharing email button to send post image"

$
0
0

Can someone help me with this? I have spent hours trying to find a way to send the featured post image along with the email sent via the email sharing button.

I know the new code to get the image goes within this line of code

function sharing_email_send_post( $data ) {
$content = sprintf( __( '%1$s (%2$s) thinks you may be interested in the following post:'."\n\n", 'jetpack' ), $data['name'], $data['source'] );
$content .= $data['post']->post_title."\n";
$content .= get_permalink( $data['post']->ID )."\n";

wp_mail( $data['target'], '['.__( 'Shared Post', 'jetpack' ).'] '.$data['post']->post_title, $content );
}

What is the code I need to add to this so that the featured image from the post is sent along with the post name and link?

http://wordpress.org/extend/plugins/jetpack/


Viewing all articles
Browse latest Browse all 36984

Trending Articles