Blast off with Jetpack – WPBudapest meetup

Last night, I gave a talk about Jetpack at our local #WPBudapest meetup. If you live in Budapest and like WordPress, you should join us next time!

And until next month, you can check my slides here:

Blast off with Jetpack

Discover the Jetpack plugin, and why should you give it a try on your WordPress site.

If you have any questions about my presentation, let me know!

Connected: Myo, one more step towards Cyborg me

About 2 years ago, I stumbled across an interesting project: a team of developers from Ontario was developing an armband named Myo that would detect all muscle movements in your arm. It would then allow you to control all kinds of objects around you. Look at their demo video to find out more:

You’re sold, right? I was, too. I immediately pre-ordered one, and started imagining tons of potential uses for this thing.

Fast-forward 2 years, I finally received it! I’ve been playing with it for the past few weeks and it definitely has some potential. We’re still far from the demo video though: Thalmic (the company behind Myo) will need to get more developers involved to integrate Myo support for games, applications, and other gadgets. Still, it’s a nice little toy, and it could become very useful!

Details and first impressions

Evolution of language: gender neutral pronouns, slang, and American Sign Language

I’ve always been interested in linguistics, their evolution over time, and their impact on culture in different languages.

Working and writing in English for the last 7 years made me discover They, and the beauty of gender neutral pronouns. It took me a while to get used to it but I now use it every day!

Yesterday, Ben Lowery shared this article: Internet slang meets American Sign Language

It’s interesting to see how new words make their way into every language!

If you wanted to know how to sign words like Screencap, Selfie, Photobomb, or Emoji (another interesting evolution of our written language), check the post!

Jetpack: add hashtags to the twitter sharing button

A few days ago I explained how to add hashtags to the tweets sent out by Jetpack Publicize. But what about the tweets your read can send using the Jetpack Sharing buttons at the bottom of your posts?

Here is how to get tags from your posts, and add them as hashtags to the twitter sharing button. As always, you’ll want to paste that code in a functionality plugin.

function jeherve_custom_sharing_title() {
        $post = get_post();
        if ( empty( $post ) ) {
                return;
        } else {
                // Create sharing title
                $sharing_title = get_the_title( $post->ID );

                // Get the tags
                $post_tags = get_the_tags( $post->ID );
                if ( ! empty( $post_tags ) ) {
                        // Create list of tags with hashtags in front of them
                        $hash_tags = '';
                        foreach( $post_tags as $tag ) {
                                $hash_tags .= ' #' . $tag->name;
                        }
                        // Add tags to the title
                        $sharing_title .= $hash_tags;
                }

                return $sharing_title;
        }
}
add_filter( 'sharing_title', 'jeherve_custom_sharing_title', 10, 3 );

Hat tip to Ryan for the idea!

Jetpack: add hashtags to tweets sent by Publicize

Jetpack’s Publicize module allows you to automatically publish your posts to your favorite Social Networks like Twitter or Facebook.

You can customize the message that is posted to Social Networks thanks to the small input field right above the Publish button:

Publicize Options

But what if you wanted to automatically add details to each Publicized post? Since both Twitter and Facebook support hashtags, you could append the post tags after the post title, like so:

Tweet tags

To do so, add the following code to a functionality plugin:

function jeherve_publicize_hashtags() {
	$post = get_post();
	if ( ! empty( $post ) ) {

		// Grab the tags of the post
		$post_tags = get_the_tags( $post->ID );

		// Append tags to custom message
		if ( ! empty( $post_tags ) ) {

			// Create list of tags with hashtags in front of them
			$hash_tags = '';
			foreach( $post_tags as $tag ) {
				$hash_tags .= ' #' . $tag->name;
			}

			// Create our custom message
			$custom_message = get_the_title() . ' ' . $hash_tags;
			update_post_meta( $post->ID, '_wpas_mess', $custom_message );
		}
	}
}

// Save that message
function jeherve_cust_pub_message_save() {
	add_action( 'save_post', 'jeherve_publicize_hashtags' );
}
add_action( 'publish_post', 'jeherve_cust_pub_message_save' );