blob: f590245e23428808d5b5b978b9e2573e8c035312 (
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
27
28
|
<?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 !',
'de' => 'Habe gerade Mageia 1, eine neue Linuxdistribution heruntergeladen, Versuche es selbst!',
'pt' => 'Acabei de transferir a Mageia 1, uma nova distribuição Linux! Experimente-a!'
);
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"
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;
}
|