Posted by & filed under internet.

If we have Sharedaddy we probably would like that whoever twitts our blog, mentions our account through a ‘via @ourAccout’.

Sharedaddy has currently no support for this, but by editing a simple php file we can make it on our own.

First we must find the ‘sharing-souces.php’ file; if we have Sharedaddy activated through Jetpack it’s located at /wp-content/plugins/jetpack/modules/sharedaddy folder, otherwise at /wp-content/plugins/sharedaddy.

In the functionprocess_request we look for the line that begins:


$twitter_url = add_query_arg( urlencode_deep( array_filter( compact( 'via', 'related', 'text', 'url' ) ) ),
 sprintf( '%s://twitter.com/intent/tweet', $this->http() )

and modify it so it loks like this:

$twitter_url = add_query_arg(
 urlencode_deep( array_filter( compact( 'via', 'related', 'text', 'url' ) ) ),
 sprintf( '%s://twitter.com/intent/tweet?via=USERNAME', $this->http() )

As simple as that

[spoiler title="DISCLAIMER"]Editing the file can make our blog inaccessible, its recommended to make a copy of the file [/spoiler]

2 Responses to “Agregar Tu Cuenta de Twitter a Sharedaddy”

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>