date (true) - $entry1->date (true); } function sortReverseEntriesByDate ($entry1, $entry2) { return $entry1->date (true) - $entry2->date (true); } function get_domain ($url) { return parse_url($url, PHP_URL_HOST); } function opml_export ($cats) { $txt = ''; foreach ($cats as $cat) { $txt .= '' . "\n"; foreach ($cat['feeds'] as $feed) { $txt .= "\t" . '' . "\n"; } $txt .= '' . "\n"; } return $txt; } function opml_import ($xml) { // TODO }