setCache($cache) // Comment this lign for avoid cache use
->setDatas($_REQUEST);
// Data transformation
$format = Format::create($format);
$format
->setDatas($bridge->getDatas())
->setExtraInfos(array(
'name' => $bridge->getName(),
'uri' => $bridge->getURI(),
))
->display();
die;
}
break;
}
}
}
catch(HttpException $e){
header('HTTP/1.1 ' . $e->getCode() . ' ' . Http::getMessageForCode($e->getCode()));
header('Content-Type: text/plain');
die($e->getMessage());
}
catch(\Exception $e){
die($e->getMessage());
}
function getHelperButtonFormat($value, $name){
return '';
}
function getHelperButtonsFormat($formats){
$buttons = '';
foreach( $formats as $name => $infos )
{
if ( isset($infos['name']) )
{
$buttons .= getHelperButtonFormat($name, $infos['name']) . PHP_EOL;
}
}
return $buttons;
}
function displayBridgeCard($bridgeReference, $bridgeInformations, $formats, $isActive = true)
{
$name = isset($bridgeInformations['homepage']) ? ''.$bridgeInformations['name'].'' : $bridgeInformations['name'];
$description = isset($bridgeInformations['description']) ? $bridgeInformations['description'] : 'No description provided';
$card = <<
{$name}
{$description}
CARD;
if( isset($bridgeInformations['use']) && count($bridgeInformations['use']) > 0 )
{
$card .= '' . PHP_EOL;
foreach($bridgeInformations['use'] as $anUseNum => $anUse)
{
$card .= '- ' . PHP_EOL;
$card .= '
' . PHP_EOL;
}
$card .= '
' . PHP_EOL;
}
else
{
$card .= '' . PHP_EOL;
}
$card .= isset($bridgeInformations['maintainer']) ? ''.$bridgeInformations['maintainer'].'' : '';
$card .= '';
return $card;
}
$bridges = Bridge::searchInformation();
$formats = Format::searchInformation();
?>
RSS-Bridge
RSS-Bridge
·Reconnecting the Web·
$bridgeInformations)
{
if(BridgeWhitelist($whitelist_selection, $bridgeReference))
{
echo displayBridgeCard($bridgeReference, $bridgeInformations, $formats);
$activeFoundBridgeCount++;
}
elseif ($showInactive)
{
// inactive bridges
$inactiveBridges .= displayBridgeCard($bridgeReference, $bridgeInformations, $formats, false) . PHP_EOL;
}
}
echo '
' . $inactiveBridges;
?>