I put the <?php do_action( 'addthis_widget' ); ?> where I wanted it to be, but if for example I try to tweet the post I'm on while on the home page. It just tweets the home page instead of the post url???
How can I fix this?
I put the <?php do_action( 'addthis_widget' ); ?> where I wanted it to be, but if for example I try to tweet the post I'm on while on the home page. It just tweets the home page instead of the post url???
How can I fix this?
I have the same issue, I inserted it in the home page inside the Post tag:
<div class="entry"><?php do_action( 'addthis_widget' ); ?>
<?php the_excerpt(); ?>
</div>
but it share the whole website, not only the single post.
But if I use it on Full Post page It works correctly.
I ended up just having the plugin place it for me. I gave up on placing it manually.
where is it placed automatically? because for me it shows under the post title but still share the whole page
See here - http://www.ps3blog.net/ It's at the bottom of each post.
The template tag supports custom URLs and titles:
<?php do_action( 'addthis_widget', $url, $title); ?>
Does that solve your problem?
Best,
Matt
for me it works on individual posts (although in the code looks like the Brand title gets called instead of the post title and the url is missing entirely), but not on categories/archives. It'll grab the title of the category rather than of the post. I even went in an added the addthis:url="$url" addthis:title="$title", same issue.
solution: add it automatically :\
I solved it!
This is just the single button which says share.
<?php $url = get_permalink(); $title = the_title('','', false); ?><a class="addthis_counter addthis_pill_style" addthis:url="<?php echo $url; ?>" addthis:title="<?php echo $title; ?>"></a>
However, it does not catch the post image because it still checks the page and not the post, will see if I can fix that to.
Updated:
It works with some images
Not working!
I want to display the button like on the example page above at http://www.ps3blog.net/
So that it is under every excerpt
AND I want to use custom images.
Does anyone have some advice?
This topic has been closed to new replies.