<script type="text/javascript">
tweetmeme_url = 'http://example.com/news/index.php?id={id}';
</script>
<script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script>
tweetmeme_url = 'http://example.com/news/index.php?id={id}';
tweetmeme_url = 'http://example.com/index.php?id={id}';
<meta name="tweetmeme-title" content="Retweet Button Explained" />
<?php
require_once('../news/db.php');
require_once('../news/config.php');
if(FRIENDLY){
$id = $url['0'];
}else{
$id = $_GET['id'];
}
$headerinfo = DataAccess::fetch(sprintf("SELECT title, shortstory AS summary, story AS article FROM %s WHERE id = ?", NEWS_ARTICLES), $id);
$title = $headerinfo['0']['title'];
$summary = $headerinfo['0']['summary'];
if(!$id || count($headerinfo) < 1){
// not viewing a full article or article doesn't exist so display your normal title
echo sprintf('<meta name="tweetmeme-title" content="%s" />%s', "Example something", PHP_EOL);
}else{
// Viewing a full article so display the title of that article + description meta tags
echo sprintf('<meta name="tweetmeme-title" content="%s" />%s', $title, PHP_EOL);
}
?>
<?php
require_once('news/db.php');
require_once('news/config.php');