You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
856 B

<?php
class Appel{
static function refresh()
{
global $dsn, $user, $pass;
try {
$parser = new RssParser();
$gatewayNew = new GatewayNews(new Connection($dsn, $user, $pass));
$gatewaySource = new GatewaySources(new Connection($dsn, $user, $pass));
$listeSources = $gatewaySource->getSources();
foreach ($listeSources as $source) {
$resultFlux = $parser->getResultFlux($source->getLink());
foreach ($resultFlux as $n) {
$gatewayNew->addNews($n);
}
}
} catch (Exception $e) {
}
}
}
?>