Hello,
on the twitter developers page you can find the following tweet button
<script src="//platform.twitter.com/widgets.js" type="text/javascript"></script>
<div>
<a href="https://twitter.com/share" class="twitter-share-button"
data-url="https://dev.twitter.com/pages/tweet_button"
data-via="your_screen_name"
data-text="Checking out this page about Tweet Buttons"
data-related="anywhere:The Javascript API"
data-count="vertical">Tweet</a>
</div>
Now I want to hardcode this into my theme. I thought it should work with the following code:
<script src="//platform.twitter.com/widgets.js" type="text/javascript"></script>
<div>
<a href="https://twitter.com/share" class="twitter-share-button"
data-url="<?php the_permalink(); ?>"
data-text="<?php the_title(); ?>"
data-count="vertical">Tweet</a>
</div>
Now the problem comes. The title shows up fine, but there is no URL what so ever. What do I do wrong?
(the website is on a local server)