blob: 76310d716ed17a01fd645f5f2d59908d86c0e9d3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
<?php
/**
*/
function dl_twitter($locale)
{
$langs = array(
'en' => 'I just downloaded Mageia 1, a new Linux distribution! Try it out!',
'fr' => 'Je viens de télécharger Mageia 1, nouvelle distribution Linux. À vous d\'essayer !'
);
if (!array_key_exists($locale, $langs))
$locale = 'en';
$s = <<<S
<a
href="http://twitter.com/share"
class="twitter-share-button"
data-url="http://mageia.org/downloads/"
data-text="{$langs[$locale]}"
data-count="horizontal"
data-via="mageia_org"
data-lang="{$locale}">Tweet</a>
<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
S;
return $s;
}
|