Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

is there any (easy) way to convert an existing plugin to become shortcode instead? http://wordpress.org/extend/plugins/rax-top-social-media-share-with-counter/

I want to place it's output specifically in the layout and not below posts like plugin does automatically. Thanks!

share|improve this question

1 Answer 1

Sure, but it will take a little bit of hacking.

I took a quick look at the plugin and what you want is in the function rax_social_media_share_show_option(). I would copy it and make a new function with just the part that builds up $button_code. That's from line 315 to 516.

Add a simple one-tag shortcode that returns $button_code and Bob's your uncle.

share|improve this answer
    
...and Marry your aunt. haha! +1 –  kaiser Feb 23 '11 at 0:49

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.