* * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. * @author Luigi Rizzo */ require "AlboParser.php"; require "../RSS/RSSFeedGenerator.php"; require "../RSS/RSSFeedItem.php"; $parser = AlboParser::createByYear(); $feed = new RSSFeedGenerator("Albo del Comune di Sant'Agata li Battiati", "Versione POP dell'Albo Pretorio del Comune di Sant'Agata li Battiati", "http://albopretorio.datamanagement.it/?ente=SantAgataLiBattiati", "http://dev.opendatasicilia.it/albopop/santagatalibattiati/albo2RSS.php"); foreach ($parser as $r) { $title = $r->mittente_descrizione; if (empty($title)) { $feed->addItem('ERROR', null, null, $r->link, $r->link); } else { $feed->addItem($title, $r->anno . "/" . $r->numero . " - " . $r->mittente_descrizione, null, $r->link, $r->link); } } //output header('Content-type: application/rss+xml; charset=UTF-8'); /* * Impostazioni locali in italiano, utilizzato per la stampa di data e ora * (il server deve avere il locale italiano installato */ setlocale(LC_TIME, 'it_IT'); echo $feed->getFeed();
* * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ require "AlboComuneCTParser.php"; require "../RSS/RSSFeedGenerator.php"; require "../RSS/RSSFeedItem.php"; require "../phpalbogenerator/AccessLogUtils.php"; define("RSSPATH", "http://dev.opendatasicilia.it/albopop/catania/"); AccessLogUtils::logAccess(); $parser = AlboComuneCTParser::createByYear(); $feed = new RSSFeedGenerator("Albo del Comune di Catania", "Versione POP e social dell'Albo Pretorio del Comune di Catania", "http://www.comune.catania.gov.it/EtnaInWeb/AlboPretorio.nsf/HomePage?Open&buffer=A20110301121017437GH", RSSPATH . "alboct2RSS-social.php"); foreach ($parser as $r) { //remove the sender if it is internal to the municipality of Catania $title = preg_replace('%^.*- COMUNE DI CATANIA *%', '', $r->mittente_descrizione, 1); if (empty($title)) { $feed->addItem('ERROR', null, null, $r->link, $r->link); } else { $description = $r->repertorio . " - " . $r->tipo . ": " . $r->mittente_descrizione; $newpagelink = RSSPATH . 'sharer.php?anno=' . urlencode($r->anno) . "&numero=" . urlencode($r->numero); $feed->addItem($title, $description, null, $newpagelink, $newpagelink); } } //output header('Content-type: application/rss+xml; charset=UTF-8'); /* * Impostazioni locali in italiano, utilizzato per la stampa di data e ora * (il server deve avere il locale italiano installato */ setlocale(LC_TIME, 'it_IT'); echo $feed->getFeed();
* * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public License * along with this program. If not, see <http://www.gnu.org/licenses/>. */ require "AlboComuneCTParser.php"; require "../RSS/RSSFeedGenerator.php"; require "../RSS/RSSFeedItem.php"; $parser = AlboComuneCTParser::createByYear(); $feed = new RSSFeedGenerator("Albo del Comune di Catania", "Versione POP dell'Albo Pretorio del Comune di Catania", "http://www.comune.catania.gov.it/EtnaInWeb/AlboPretorio.nsf/HomePage?Open&buffer=A20110301121017437GH", "http://dev.opendatasicilia.it/albopop/catania/alboct2RSS.php"); foreach ($parser as $r) { //remove the sender if it is internal to the municipality of Catania $title = preg_replace('%^.*- COMUNE DI CATANIA *%', '', $r->mittente_descrizione, 1); if (empty($title)) { $feed->addItem('ERROR', null, null, $r->link, $r->link); } else { $feed->addItem($title, $r->repertorio . " - " . $r->tipo . ": " . $r->mittente_descrizione, null, $r->link, $r->link); } } //output header('Content-type: application/rss+xml; charset=UTF-8'); /* * Impostazioni locali in italiano, utilizzato per la stampa di data e ora * (il server deve avere il locale italiano installato */ setlocale(LC_TIME, 'it_IT'); echo $feed->getFeed();