Add 'Send to Twitter' and 'Send to Facebook' links to the users Dashboard
I wanted to put links for the end user so they could easily post their ads on their own Facebook and Twitter pages.
Instead of messing around with specific user rights on individual ads, I decided to just add them to the Dashboard, alongside each ad.
In order to do this, open 'tpl-dashboard.php' and search for <div class="meta">
Before the next </div>
tag, enter the following:
<?php the_category(', ') ?>Created <?php the_time(get_option('date_format'))?> |
<a href="http://www.facebook.com/sharer.php?u=<?php the_permalink();?>&t=<?php the_title(); ?>" target="_blank">Send to Facebook</a> | <a href="http://twitter.com/home?status=I'm selling this, buy it! <?php the_permalink(); ?>" title="Click to send this ad to Twitter" target="_blank">Send to Twitter</a>
You can change the link text to whatever you want it to display. A screenshot of the end result is attached.
I hope this helps someone out.