From 2bd7f83a6495011ada78ca8a9f2af417caf01760 Mon Sep 17 00:00:00 2001 From: ahriman Date: Wed, 2 Jan 2019 04:57:35 +0000 Subject: removed dokuwiki --- .../lib/Creator/AtomCreator03.php | 95 ------- .../lib/Creator/AtomCreator10.php | 163 ------------ .../lib/Creator/FeedCreator.php | 274 --------------------- .../lib/Creator/GPXCreator.php | 50 ---- .../lib/Creator/HTMLCreator.php | 162 ------------ .../universalfeedcreator/lib/Creator/JSCreator.php | 45 ---- .../lib/Creator/KMLCreator.php | 107 -------- .../lib/Creator/MBOXCreator.php | 111 --------- .../lib/Creator/OPMLCreator.php | 68 ----- .../lib/Creator/PHPCreator.php | 57 ----- .../lib/Creator/PIECreator01.php | 63 ----- .../lib/Creator/RSSCreator091.php | 198 --------------- .../lib/Creator/RSSCreator10.php | 113 --------- .../lib/Creator/RSSCreator20.php | 23 -- 14 files changed, 1529 deletions(-) delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator03.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator10.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/FeedCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/GPXCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/HTMLCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/JSCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/KMLCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/MBOXCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/OPMLCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PHPCreator.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PIECreator01.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator091.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator10.php delete mode 100644 wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator20.php (limited to 'wiki/vendor/openpsa/universalfeedcreator/lib/Creator') diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator03.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator03.php deleted file mode 100644 index 5f80a75..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator03.php +++ /dev/null @@ -1,95 +0,0 @@ -, Scott Reynen - * @package de.bitfolge.feedcreator - */ -class AtomCreator03 extends FeedCreator -{ - - /** - * AtomCreator03 constructor. - */ - public function __construct() - { - $this->contentType = "application/atom+xml"; - $this->encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createGeneratorComment(); - $feed .= $this->_createStylesheetReferences(); - $feed .= "format == 'TOOLBAR') { - $feed .= " xmlns:gtb=\"http://toolbar.google.com/custombuttons/\""; - } - if ($this->language != "") { - $feed .= " xml:lang=\"".$this->language."\""; - } - $feed .= ">\n"; - $feed .= " ".htmlspecialchars($this->title)."\n"; - $feed .= " ".htmlspecialchars($this->description)."\n"; - $feed .= " link)."\"/>\n"; - $feed .= " ".htmlspecialchars($this->link)."\n"; - $now = new FeedDate(); - $feed .= " ".htmlspecialchars($now->iso8601())."\n"; - if ($this->editor != "") { - $feed .= " \n"; - $feed .= " ".$this->editor."\n"; - if ($this->editorEmail != "") { - $feed .= " ".$this->editorEmail."\n"; - } - $feed .= " \n"; - } - $feed .= " ".FEEDCREATOR_VERSION."\n"; - $feed .= $this->_createAdditionalElements($this->additionalElements, " "); - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " \n"; - $feed .= " ".htmlspecialchars(strip_tags($this->items[$i]->title))."\n"; - $feed .= " items[$i]->link - )."\"/>\n"; - if ($this->items[$i]->date == "") { - $this->items[$i]->date = time(); - } - $itemDate = new FeedDate($this->items[$i]->date); - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($this->items[$i]->link)."\n"; - $feed .= $this->_createAdditionalElements($this->items[$i]->additionalElements, " "); - if ($this->items[$i]->author != "") { - $feed .= " \n"; - $feed .= " ".htmlspecialchars($this->items[$i]->author)."\n"; - $feed .= " \n"; - } - if ($this->items[$i]->description != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->description)."\n"; - } - if (isset($this->items[$i]->thumbdata)) { - $feed .= " \n"; - $feed .= chunk_split(base64_encode($this->items[$i]->thumbdata))."\n"; - $feed .= " \n"; - } - $feed .= " \n"; - } - $feed .= "\n"; - - return $feed; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator10.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator10.php deleted file mode 100644 index db7314e..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/AtomCreator10.php +++ /dev/null @@ -1,163 +0,0 @@ -contentType = "application/atom+xml"; - $this->encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createGeneratorComment(); - $feed .= $this->_createStylesheetReferences(); - $feed .= "items[0]->lat)) { - $feed .= " xmlns:georss=\"http://www.georss.org/georss\"\n"; - } - if ($this->language != "") { - $feed .= " xml:lang=\"".$this->language."\""; - } - $feed .= ">\n"; - $feed .= " ".htmlspecialchars($this->title)."\n"; - $feed .= " ".htmlspecialchars($this->description)."\n"; - $feed .= " link)."\"/>\n"; - $feed .= " ".htmlspecialchars($this->link)."\n"; - $now = new FeedDate(); - $feed .= " ".htmlspecialchars($now->iso8601())."\n"; - if ($this->editor != "") { - $feed .= " \n"; - $feed .= " ".$this->editor."\n"; - if ($this->editorEmail != "") { - $feed .= " ".$this->editorEmail."\n"; - } - $feed .= " \n"; - } - if ($this->category != "") { - - $feed .= " category)."\" />\n"; - } - if ($this->copyright != "") { - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->copyright), 100)."\n"; - } - $feed .= " ".$this->version()."\n"; - - $feed .= " syndicationURL - )."\" />\n"; - $feed .= $this->_createAdditionalElements($this->additionalElements, " "); - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " \n"; - $feed .= " ".htmlspecialchars(strip_tags($this->items[$i]->title))."\n"; - $feed .= " items[$i]->link - )."\"/>\n"; - if ($this->items[$i]->date == "") { - $this->items[$i]->date = time(); - } - $itemDate = new FeedDate($this->items[$i]->date); - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - - $tempguid = $this->items[$i]->link; - if ($this->items[$i]->guid != "") { - $tempguid = $this->items[$i]->guid; - } - - $feed .= " ".htmlspecialchars($tempguid)."\n"; - $feed .= $this->_createAdditionalElements($this->items[$i]->additionalElements, " "); - if ($this->items[$i]->author != "") { - $feed .= " \n"; - $feed .= " ".htmlspecialchars($this->items[$i]->author)."\n"; - if ($this->items[$i]->authorEmail != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->authorEmail)."\n"; - } - - if ($this->items[$i]->authorURL != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->authorURL)."\n"; - } - - $feed .= " \n"; - } - - if ($this->items[$i]->category != "") { - $feed .= " items[$i]->categoryScheme != "") { - $feed .= " scheme=\"".htmlspecialchars($this->items[$i]->categoryScheme)."\" "; - } - - $feed .= " term=\"".htmlspecialchars($this->items[$i]->category)."\" />\n"; - } - - if ($this->items[$i]->description != "") { - - /* - * ATOM should have at least summary tag, however this implementation may be inaccurate - */ - $tempdesc = $this->items[$i]->getDescription(); - $temptype = ""; - - if ($this->items[$i]->descriptionHtmlSyndicated) { - $temptype = " type=\"html\""; - $tempdesc = $this->items[$i]->getDescription(); - - } - - if (empty($this->items[$i]->descriptionTruncSize)) { - $feed .= " ".$tempdesc."\n"; - } - - $feed .= " ".$tempdesc."\n"; - } else { - - $feed .= " no summary\n"; - - } - - if ($this->items[$i]->enclosure != null) { - $feed .= " items[$i]->enclosure->url."\" type=\"".$this->items[$i]->enclosure->type."\" length=\"".$this->items[$i]->enclosure->length."\""; - - if ($this->items[$i]->enclosure->language != "") { - $feed .= " xml:lang=\"".$this->items[$i]->enclosure->language."\" "; - } - - if ($this->items[$i]->enclosure->title != "") { - $feed .= " title=\"".$this->items[$i]->enclosure->title."\" "; - } - - $feed .= " /> \n"; - } - if ($this->items[$i]->lat != "") { - $feed .= " ".$this->items[$i]->lat." ".$this->items[$i]->long."\n"; - } - $feed .= " \n"; - } - $feed .= "\n"; - - return $feed; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/FeedCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/FeedCreator.php deleted file mode 100644 index d5e99cd..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/FeedCreator.php +++ /dev/null @@ -1,274 +0,0 @@ - - * @since 1.4 - * @package de.bitfolge.feedcreator - */ -abstract class FeedCreator extends HtmlDescribable -{ - - /** - * Mandatory attributes of a feed. - */ - public $title, $description, $link; - public $format = 'BASE'; - - /** - * Optional attributes of a feed. - */ - public $syndicationURL, $image, $language, $copyright, $pubDate, $lastBuildDate, $editor, $editorEmail, $webmaster, $category, $docs, $ttl, $rating, $skipHours, $skipDays; - - /** - * The url of the external xsl stylesheet used to format the naked rss feed. - * Ignored in the output when empty. - */ - public $xslStyleSheet = ""; - - - /** @var FeedItem[] */ - public $items = Array(); - - /** - * Generator string - */ - public $generator = "info@mypapit.net"; - - /** - * This feed's MIME content type. - * - * @since 1.4 - * @access private - */ - protected $contentType = "application/xml"; - - /** - * This feed's character encoding. - * - * @since 1.6.1 - */ - protected $encoding = "UTF-8"; //"ISO-8859-1"; - - /** - * Any additional elements to include as an associated array. All $key => $value pairs - * will be included unencoded in the feed in the form - * <$key>$value - * Again: No encoding will be used! This means you can invalidate or enhance the feed - * if $value contains markup. This may be abused to embed tags not implemented by - * the FeedCreator class used. - */ - public $additionalElements = Array(); - - /** - * Adds a FeedItem to the feed. - * - * @param FeedItem $item The FeedItem to add to the feed. - */ - public function addItem($item) - { - $this->items[] = $item; - } - - /** - * Get the version string for the generator - * - * @return string - */ - public function version() - { - return FEEDCREATOR_VERSION." (".$this->generator.")"; - } - - /** - * Truncates a string to a certain length at the most sensible point. - * First, if there's a '.' character near the end of the string, the string is truncated after this character. - * If there is no '.', the string is truncated after the last ' ' character. - * If the string is truncated, " ..." is appended. - * If the string is already shorter than $length, it is returned unchanged. - * - * @param string $string A string to be truncated. - * @param int $length the maximum length the string should be truncated to - * @return string the truncated string - */ - public static function iTrunc($string, $length) - { - if (strlen($string) <= $length) { - return $string; - } - - $pos = strrpos($string, "."); - if ($pos >= $length - 4) { - $string = substr($string, 0, $length - 4); - $pos = strrpos($string, "."); - } - if ($pos >= $length * 0.4) { - return substr($string, 0, $pos + 1)." ..."; - } - - $pos = strrpos($string, " "); - if ($pos >= $length - 4) { - $string = substr($string, 0, $length - 4); - $pos = strrpos($string, " "); - } - if ($pos >= $length * 0.4) { - return substr($string, 0, $pos)." ..."; - } - - return substr($string, 0, $length - 4)." ..."; - - } - - /** - * Creates a comment indicating the generator of this feed. - * The format of this comment seems to be recognized by - * Syndic8.com. - */ - protected function _createGeneratorComment() - { - return "\n"; - } - - /** - * Creates a string containing all additional elements specified in - * $additionalElements. - * - * @param array $elements an associative array containing key => value pairs - * @param string $indentString a string that will be inserted before every generated line - * @return string the XML tags corresponding to $additionalElements - */ - protected function _createAdditionalElements($elements, $indentString = "") - { - $ae = ""; - if (is_array($elements)) { - foreach ($elements AS $key => $value) { - $ae .= $indentString."<$key>$value\n"; - } - } - - return $ae; - } - - protected function _createStylesheetReferences() - { - $xml = ""; - if (!empty($this->cssStyleSheet)) { - $xml .= "cssStyleSheet."\" type=\"text/css\"?>\n"; - } - if (!empty($this->xslStyleSheet)) { - $xml .= "xslStyleSheet."\" type=\"text/xsl\"?>\n"; - } - - return $xml; - } - - /** - * Builds the feed's text. - * - * @return string the feed's complete text - */ - abstract public function createFeed(); - - /** - * Generate a filename for the feed cache file. The result will be $_SERVER["PHP_SELF"] with the extension changed - * to .xml. For example: echo $_SERVER["PHP_SELF"]."\n"; echo FeedCreator::_generateFilename(); would produce: - * /rss/latestnews.php - * latestnews.xml - * - * @return string the feed cache filename - * @since 1.4 - * @access private - */ - protected function _generateFilename() - { - $fileInfo = pathinfo($_SERVER["PHP_SELF"]); - - return substr($fileInfo["basename"], 0, -(strlen($fileInfo["extension"]) + 1)).".xml"; - } - - /** - * Send given file to Browser - * - * @since 1.4 - * @param string $filename - */ - protected function _redirect($filename) - { - // attention, heavily-commented-out-area - - // maybe use this in addition to file time checking - //header("Expires: ".date("r",time()+$this->_timeout)); - - /* no caching at all, doesn't seem to work as good: - header("Cache-Control: no-cache"); - header("Pragma: no-cache"); - */ - - // HTTP redirect, some feed readers' simple HTTP implementations don't follow it - //header("Location: ".$filename); - - header("Content-Type: ".$this->contentType."; charset=".$this->encoding."; filename=".basename($filename)); - if (preg_match('/\.(kml|gpx)$/', $filename)) { - header("Content-Disposition: attachment; filename=".basename($filename)); - } else { - header("Content-Disposition: inline; filename=".basename($filename)); - } - readfile($filename); - exit(); - } - - /** - * Turns on caching and checks if there is a recent version of this feed in the cache. - * If there is, an HTTP redirect header is sent. - * To effectively use caching, you should create the FeedCreator object and call this method - * before anything else, especially before you do the time consuming task to build the feed - * (web fetching, for example). - * - * @since 1.4 - * @param string $filename optional the filename where a recent version of the feed is saved. If not specified, - * the filename is $_SERVER["PHP_SELF"] with the extension changed to .xml (see - * _generateFilename()). - * @param int $timeout optional the timeout in seconds before a cached version is refreshed (defaults to - * 3600 = 1 hour) - */ - public function useCached($filename = "", $timeout = 3600) - { - $this->_timeout = $timeout; - if ($filename == "") { - $filename = $this->_generateFilename(); - } - if (file_exists($filename) AND (time() - filemtime($filename) < $timeout)) { - $this->_redirect($filename); - } - } - - /** - * Saves this feed as a file on the local disk. After the file is saved, a redirect - * header may be sent to redirect the user to the newly created file. - * - * @since 1.4 - * @param string $filename optional the filename where a recent version of the feed is saved. If not - * specified, the filename is $_SERVER["PHP_SELF"] with the extension changed to .xml - * (see _generateFilename()). - * @param bool $displayContents optional send an HTTP redirect header or not. If true, the user will be - * automatically redirected to the created file. - */ - public function saveFeed($filename = "", $displayContents = true) - { - if ($filename == "") { - $filename = $this->_generateFilename(); - } - $feedFile = fopen($filename, "w+"); - if ($feedFile) { - fputs($feedFile, $this->createFeed()); - fclose($feedFile); - if ($displayContents) { - $this->_redirect($filename); - } - } else { - echo "
Error creating feed file, please check write permissions.
"; - } - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/GPXCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/GPXCreator.php deleted file mode 100644 index e8df308..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/GPXCreator.php +++ /dev/null @@ -1,50 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class GPXCreator extends FeedCreator -{ - - /** - * GPXCreator constructor. - */ - public function __construct() - { - $this->contentType = "text/xml"; - $this->encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createStylesheetReferences(); - $feed .= "\n"; - - $now = new FeedDate(); - $feed .= "".FeedCreator::iTrunc(htmlspecialchars($this->title), 100)." - {$http_host} - ".htmlspecialchars($this->link)." - - \n"; - - for ($i = 0; $i < count($this->items); $i++) { - $feed .= "items[$i]->lat."\" lon=\"".$this->items[$i]->long."\"> - ".substr(htmlspecialchars(strip_tags($this->items[$i]->title)), 0, 6)." - ".htmlspecialchars(strip_tags($this->items[$i]->title))." - ".htmlspecialchars($this->items[$i]->author)." - ".htmlspecialchars($this->items[$i]->link)." - \n"; - } - $feed .= "\n"; - - return $feed; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/HTMLCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/HTMLCreator.php deleted file mode 100644 index 9b6f8b5..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/HTMLCreator.php +++ /dev/null @@ -1,162 +0,0 @@ - tags to enable formatting - * using CSS. - * - * @author Pascal Van Hecke - * @since 1.7 - * @package de.bitfolge.feedcreator - */ -class HTMLCreator extends FeedCreator -{ - - protected $contentType = "text/html"; - - /** - * Contains HTML to be output at the start of the feed's html representation. - */ - public $header; - - /** - * Contains HTML to be output at the end of the feed's html representation. - */ - public $footer; - - /** - * Contains HTML to be output between entries. A separator is only used in - * case of multiple entries. - */ - public $separator; - - /** - * Used to prefix the stylenames to make sure they are unique - * and do not clash with stylenames on the user's page. - */ - public $stylePrefix; - - /** @var bool Determines whether the links open in a new window or not. */ - public $openInNewWindow = true; - - /** @var string image alignments in output */ - public $imageAlign = "right"; - - /** - * In case of very simple output you may want to get rid of the style tags, - * hence this variable. There's no equivalent on item level, but of course you can - * add strings to it while iterating over the items ($this->stylelessOutput .= ...) - * and when it is non-empty, ONLY the styleless output is printed, the rest is ignored - * in the function createFeed(). - */ - public $stylelessOutput = ""; - - /** - * Writes the HTML. - * - * @inheritdoc - */ - public function createFeed() - { - // if there is styleless output, use the content of this variable and ignore the rest - if ($this->stylelessOutput != "") { - return $this->stylelessOutput; - } - - //if no stylePrefix is set, generate it yourself depending on the script name - if ($this->stylePrefix == "") { - $this->stylePrefix = str_replace(".", "_", $this->_generateFilename())."_"; - } - - //set an openInNewWindow_token_to be inserted or not - if ($this->openInNewWindow) { - $targetInsert = " class='target_blank'"; - } else { - $targetInsert = ''; - } - - // use this array to put the lines in and implode later with "document.write" javascript - $feedArray = array(); - if ($this->image != null) { - $imageStr = "". - "".
-                FeedCreator::iTrunc(htmlspecialchars($this->image->title), 100).
-                "image->width) { - $imageStr .= " width='".$this->image->width."' "; - } - if ($this->image->height) { - $imageStr .= " height='".$this->image->height."' "; - } - $imageStr .= "/>"; - $feedArray[] = $imageStr; - } - - if ($this->title) { - $feedArray[] = ""; - } - if ($this->getDescription()) { - $feedArray[] = "
". - str_replace("]]>", "", str_replace("getDescription())). - "
"; - } - - if ($this->header) { - $feedArray[] = "
".$this->header."
"; - } - - for ($i = 0; $i < count($this->items); $i++) { - if ($this->separator and $i > 0) { - $feedArray[] = "
".$this->separator."
"; - } - - if ($this->items[$i]->title) { - if ($this->items[$i]->link) { - $feedArray[] = - ""; - } else { - $feedArray[] = - "
". - FeedCreator::iTrunc(htmlspecialchars(strip_tags($this->items[$i]->title)), 100). - "
"; - } - } - if ($this->items[$i]->getDescription()) { - $feedArray[] = - "
". - str_replace("]]>", "", str_replace("items[$i]->getDescription())). - "
"; - } - } - if ($this->footer) { - $feedArray[] = "
".$this->footer."
"; - } - - $feed = "".join($feedArray, "\r\n"); - - return $feed; - } - - /** - * Overrides parent to produce .html extensions - * - * @return string the feed cache filename - * @since 1.4 - * @access private - */ - protected function _generateFilename() - { - $fileInfo = pathinfo($_SERVER["PHP_SELF"]); - - return substr($fileInfo["basename"], 0, -(strlen($fileInfo["extension"]) + 1)).".html"; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/JSCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/JSCreator.php deleted file mode 100644 index 5b75ea7..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/JSCreator.php +++ /dev/null @@ -1,45 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class KMLCreator extends FeedCreator -{ - - /** - * KMLCreator constructor. - */ - public function __construct() - { - $this->contentType = "application/vnd.google-earth.kml+xml"; - $this->encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createStylesheetReferences(); - $feed .= "\n"; - $feed .= "\n"; - if ($_GET['LinkControl']) { - $feed .= "\n3600\n\n"; - } - if (!empty($_GET['simple']) && count($this->items) > 0) { - $feed .= " - - - - normal - #defaultIcon - - - highlight - #hoverIcon - - - "; - $style = "#defaultStyle"; - } else { - $style = "root://styleMaps#default?iconId=0x307"; - } - $feed .= "\n"; - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->title), 100)." - ".$this->getDescription()." - 1\n"; - $this->truncSize = 500; - - for ($i = 0; $i < count($this->items); $i++) { - //added here beucase description gets auto surrounded by cdata - $this->items[$i]->description = "".$this->items[$i]->description."
- ".$this->items[$i]->licence." -

items[$i]->link)."\">View Online"; - - $feed .= " - - ".$this->items[$i]->getDescription(true)." - ".FeedCreator::iTrunc(htmlspecialchars(strip_tags($this->items[$i]->title)), 100)." - 1 - - ".$this->items[$i]->long.",".$this->items[$i]->lat.",25 - "; - if ($this->items[$i]->thumb != "") { - $feed .= " - $style - "; - } - $feed .= " - \n"; - } - $feed .= "
\n
\n
\n"; - - return $feed; - } - - /** - * Generate a filename for the feed cache file. Overridden from FeedCreator to prevent XML data types. - * - * @return string the feed cache filename - * @since 1.4 - * @access private - */ - protected function _generateFilename() - { - $fileInfo = pathinfo($_SERVER["PHP_SELF"]); - - return substr($fileInfo["basename"], 0, -(strlen($fileInfo["extension"]) + 1)).".kml"; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/MBOXCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/MBOXCreator.php deleted file mode 100644 index d7f898d..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/MBOXCreator.php +++ /dev/null @@ -1,111 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class MBOXCreator extends FeedCreator -{ - - /** - * MBOXCreator constructor. - */ - public function __construct() - { - $this->contentType = "text/plain"; - $this->encoding = "ISO-8859-15"; - } - - /** - * Quoted Printable encoding - * - * @param string $input - * @param int $line_max wrap lines after these number of characters - * @return string - */ - protected function qp_enc($input = "", $line_max = 76) - { - $hex = array('0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F'); - $lines = preg_split("/(?:\r\n|\r|\n)/", $input); - $eol = "\r\n"; - $escape = "="; - $output = ""; - foreach ($lines as $line) { - $linlen = strlen($line); - $newline = ""; - for ($i = 0; $i < $linlen; $i++) { - $c = substr($line, $i, 1); - $dec = ord($c); - if (($dec == 32) && ($i == ($linlen - 1))) { // convert space at eol only - $c = "=20"; - } elseif (($dec == 61) || ($dec < 32) || ($dec > 126)) { // always encode "\t", which is *not* required - $h2 = floor($dec / 16); - $h1 = floor($dec % 16); - $c = $escape.$hex["$h2"].$hex["$h1"]; - } - if ((strlen($newline) + strlen($c)) >= $line_max) { // CRLF is not counted - $output .= $newline.$escape.$eol; // soft line break; " =\r\n" is okay - $newline = ""; - } - $newline .= $c; - } // end of for - $output .= $newline.$eol; - } - - return trim($output); - } - - /** - * Builds the MBOX contents. - * - * @inheritdoc - */ - public function createFeed() - { - $feed = ''; - for ($i = 0; $i < count($this->items); $i++) { - if ($this->items[$i]->author != "") { - $from = $this->items[$i]->author; - } else { - $from = $this->title; - } - $itemDate = new FeedDate($this->items[$i]->date); - $feed .= "From ".strtr(MBOXCreator::qp_enc($from), " ", "_")." ".date( - "D M d H:i:s Y", - $itemDate->unix() - )."\n"; - $feed .= "Content-Type: text/plain;\n"; - $feed .= " charset=\"".$this->encoding."\"\n"; - $feed .= "Content-Transfer-Encoding: quoted-printable\n"; - $feed .= "Content-Type: text/plain\n"; - $feed .= "From: \"".MBOXCreator::qp_enc($from)."\"\n"; - $feed .= "Date: ".$itemDate->rfc822()."\n"; - $feed .= "Subject: ".MBOXCreator::qp_enc(FeedCreator::iTrunc($this->items[$i]->title, 100))."\n"; - $feed .= "\n"; - $body = chunk_split(MBOXCreator::qp_enc($this->items[$i]->description)); - $feed .= preg_replace("~\nFrom ([^\n]*)(\n?)~", "\n>From $1$2\n", $body); - $feed .= "\n"; - $feed .= "\n"; - } - - return $feed; - } - - /** - * Generate a filename for the feed cache file. Overridden from FeedCreator to prevent XML data types. - * - * @return string the feed cache filename - * @since 1.4 - * @access private - */ - protected function _generateFilename() - { - $fileInfo = pathinfo($_SERVER["PHP_SELF"]); - - return substr($fileInfo["basename"], 0, -(strlen($fileInfo["extension"]) + 1)).".mbox"; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/OPMLCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/OPMLCreator.php deleted file mode 100644 index 6dcdc82..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/OPMLCreator.php +++ /dev/null @@ -1,68 +0,0 @@ -encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createGeneratorComment(); - $feed .= $this->_createStylesheetReferences(); - $feed .= "\n"; - $feed .= " \n"; - $feed .= " ".htmlspecialchars($this->title)."\n"; - if ($this->pubDate != "") { - $date = new FeedDate($this->pubDate); - $feed .= " ".$date->rfc822()."\n"; - } - if ($this->lastBuildDate != "") { - $date = new FeedDate($this->lastBuildDate); - $feed .= " ".$date->rfc822()."\n"; - } - if ($this->editor != "") { - $feed .= " ".$this->editor."\n"; - } - if ($this->editorEmail != "") { - $feed .= " ".$this->editorEmail."\n"; - } - $feed .= " \n"; - $feed .= " \n"; - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " items[$i]->title, "\n\r", " "))); - $feed .= " title=\"".$title."\""; - $feed .= " text=\"".$title."\""; - - if (isset($this->items[$i]->xmlUrl)) { - $feed .= " xmlUrl=\"".htmlspecialchars($this->items[$i]->xmlUrl)."\""; - } - - if (isset($this->items[$i]->link)) { - $feed .= " url=\"".htmlspecialchars($this->items[$i]->link)."\""; - } - - $feed .= "/>\n"; - } - $feed .= " \n"; - $feed .= "\n"; - - return $feed; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PHPCreator.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PHPCreator.php deleted file mode 100644 index 23b8352..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PHPCreator.php +++ /dev/null @@ -1,57 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class PHPCreator extends FeedCreator -{ - - /** - * PHPCreator constructor. - */ - public function __construct() - { - $this->contentType = "text/plain"; - $this->encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "title), 100))."';\n"; - $this->truncSize = 500; - $feed .= " \$feedDescription='".addslashes($this->getDescription())."';\n"; - $feed .= " \$feedLink='".$this->link."';\n"; - $feed .= " \$feedItem = array();\n"; - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " \$feedItem[$i] = new FeedItem();\n"; - if ($this->items[$i]->guid != "") { - $feed .= " \$feedItem[$i]->id='".htmlspecialchars($this->items[$i]->guid)."';\n"; - } - $feed .= " \$feedItem[$i]->title='".addslashes( - FeedCreator::iTrunc(htmlspecialchars(strip_tags($this->items[$i]->title)), 100) - )."';\n"; - $feed .= " \$feedItem[$i]->link='".htmlspecialchars($this->items[$i]->link)."';\n"; - $feed .= " \$feedItem[$i]->date=".htmlspecialchars($this->items[$i]->date).";\n"; - if ($this->items[$i]->author != "") { - $feed .= " \$feedItem[$i]->author='".htmlspecialchars($this->items[$i]->author)."';\n"; - if ($this->items[$i]->authorEmail != "") { - $feed .= " \$feedItem[$i]->authorEmail='".$this->items[$i]->authorEmail."';\n"; - } - } - $feed .= " \$feedItem[$i]->description='".addslashes($this->items[$i]->getDescription())."';\n"; - if ($this->items[$i]->thumb != "") { - $feed .= " \$feedItem[$i]->thumbURL='".htmlspecialchars($this->items[$i]->thumb)."';\n"; - } - } - $feed .= "?>\n"; - - return $feed; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PIECreator01.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PIECreator01.php deleted file mode 100644 index 5700123..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/PIECreator01.php +++ /dev/null @@ -1,63 +0,0 @@ - and Kai Blankenhorn - * @package de.bitfolge.feedcreator - */ -class PIECreator01 extends FeedCreator -{ - - /** - * PIECreator01 constructor. - */ - public function __construct() - { - $this->encoding = "utf-8"; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createStylesheetReferences(); - $feed .= "\n"; - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->title), 100)."\n"; - $this->truncSize = 500; - $feed .= " ".$this->getDescription()."\n"; - $feed .= " ".$this->link."\n"; - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " \n"; - $feed .= " ".FeedCreator::iTrunc( - htmlspecialchars(strip_tags($this->items[$i]->title)), - 100 - )."\n"; - $feed .= " ".htmlspecialchars($this->items[$i]->link)."\n"; - $itemDate = new FeedDate($this->items[$i]->date); - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - $feed .= " ".htmlspecialchars($this->items[$i]->guid)."\n"; - if ($this->items[$i]->author != "") { - $feed .= " \n"; - $feed .= " ".htmlspecialchars($this->items[$i]->author)."\n"; - if ($this->items[$i]->authorEmail != "") { - $feed .= " ".$this->items[$i]->authorEmail."\n"; - } - $feed .= " \n"; - } - $feed .= " \n"; - $feed .= "
".$this->items[$i]->getDescription( - )."
\n"; - $feed .= "
\n"; - $feed .= "
\n"; - } - $feed .= "
\n"; - - return $feed; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator091.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator091.php deleted file mode 100644 index cd229e9..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator091.php +++ /dev/null @@ -1,198 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class RSSCreator091 extends FeedCreator -{ - - /** @var string Stores this RSS feed's version number. */ - protected $RSSVersion; - - /** - * RSSCreator091 constructor. - */ - function __construct() - { - $this->_setRSSVersion("0.91"); - $this->contentType = "application/rss+xml"; - } - - /** - * Sets this RSS feed's version number. - * - * @param string $version - */ - protected function _setRSSVersion($version) - { - $this->RSSVersion = $version; - } - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createGeneratorComment(); - $feed .= $this->_createStylesheetReferences(); - $feed .= "RSSVersion."\""; - - if (count($this->items) > 0 - && !empty($this->items[0]->lat) - ) { - $feed .= " xmlns:georss=\"http://www.georss.org/georss/\"\n"; - } - if (count($this->items) > 0 - && isset($this->items[0]->additionalElements['xcal:dtstart']) - ) { - $feed .= " xmlns:xcal=\"urn:ietf:params:xml:ns:xcal\"\n"; - } - $feed .= ">\n"; - if ($this->format == 'BASE') { - $feed .= " \n"; - } else { - $feed .= " \n"; - } - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->title), 100)."\n"; - $this->descriptionTruncSize = 500; - $feed .= " ".$this->getDescription()."\n"; - $feed .= " ".$this->link."\n"; - $now = new FeedDate(); - $feed .= " ".htmlspecialchars( - $this->lastBuildDate ?: $now->rfc822() - )."\n"; - $feed .= " ".FEEDCREATOR_VERSION."\n"; - - if ($this->image != null) { - $feed .= " \n"; - $feed .= " ".$this->image->url."\n"; - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->image->title), 100)."\n"; - $feed .= " ".$this->image->link."\n"; - if ($this->image->width != "") { - $feed .= " ".$this->image->width."\n"; - } - if ($this->image->height != "") { - $feed .= " ".$this->image->height."\n"; - } - if ($this->image->description != "") { - $feed .= " ".htmlspecialchars($this->image->description)."\n"; - } - $feed .= " \n"; - } - if ($this->language != "") { - $feed .= " ".$this->language."\n"; - } - if ($this->copyright != "") { - $feed .= " ".FeedCreator::iTrunc( - htmlspecialchars($this->copyright), - 100 - )."\n"; - } - if ($this->editor != "") { - $feed .= " ".FeedCreator::iTrunc( - htmlspecialchars($this->editor), - 100 - )."\n"; - } - if ($this->webmaster != "") { - $feed .= " ".FeedCreator::iTrunc( - htmlspecialchars($this->webmaster), - 100 - )."\n"; - } - if ($this->pubDate != "") { - $pubDate = new FeedDate($this->pubDate); - $feed .= " ".htmlspecialchars($pubDate->rfc822())."\n"; - } - if ($this->category != "") { - $feed .= " ".htmlspecialchars($this->category)."\n"; - } - if ($this->docs != "") { - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->docs), 500)."\n"; - } - if ($this->ttl != "") { - $feed .= " ".htmlspecialchars($this->ttl)."\n"; - } - if ($this->rating != "") { - $feed .= " ".FeedCreator::iTrunc(htmlspecialchars($this->rating), 500)."\n"; - } - if ($this->skipHours != "") { - $feed .= " ".htmlspecialchars($this->skipHours)."\n"; - } - if ($this->skipDays != "") { - $feed .= " ".htmlspecialchars($this->skipDays)."\n"; - } - $feed .= $this->_createAdditionalElements($this->additionalElements, " "); - - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " \n"; - $feed .= " ".FeedCreator::iTrunc( - htmlspecialchars(strip_tags($this->items[$i]->title)), - 100 - )."\n"; - $feed .= " ".htmlspecialchars($this->items[$i]->link)."\n"; - $feed .= " ".$this->items[$i]->getDescription()."\n"; - - $creator = $this->getAuthor($this->items[$i]->author, $this->items[$i]->authorEmail); - if ($creator) { - $feed .= " ".htmlspecialchars($creator)."\n"; - } - - /* - // on hold - if ($this->items[$i]->source!="") { - $feed.= " ".htmlspecialchars($this->items[$i]->source)."\n"; - } - */ - if ($this->items[$i]->lat != "") { - $feed .= " ".$this->items[$i]->lat." ".$this->items[$i]->long."\n"; - } - if (is_array($this->items[$i]->category)) { - foreach ($this->items[$i]->category as $cat) { - $feed .= " ".htmlspecialchars($cat)."\n"; - } - } else { - if ($this->items[$i]->category != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->category)."\n"; - } - } - if ($this->items[$i]->comments != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->comments)."\n"; - } - if ($this->items[$i]->date != "") { - $itemDate = new FeedDate($this->items[$i]->date); - $feed .= " ".htmlspecialchars($itemDate->rfc822())."\n"; - } - if ($this->items[$i]->guid != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->guid)."\n"; - } - if ($this->items[$i]->thumb != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->thumb)."\n"; - } - $feed .= $this->_createAdditionalElements($this->items[$i]->additionalElements, " "); - $feed .= " \n"; - } - $feed .= " \n"; - $feed .= "\n"; - - return $feed; - } - - /** - * Compose the RSS-0.91 and RSS-2.0 author field. - * - * @author Joe Lapp - */ - function getAuthor($author, $email) - { - if ($author && $email) { - return $email.' ('.$author.')'; - } - - return $email; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator10.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator10.php deleted file mode 100644 index d9ed1d0..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator10.php +++ /dev/null @@ -1,113 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class RSSCreator10 extends FeedCreator -{ - - /** @inheritdoc */ - public function createFeed() - { - $feed = "encoding."\"?>\n"; - $feed .= $this->_createGeneratorComment(); - if (empty($this->cssStyleSheet)) { - $this->cssStyleSheet = "http://www.w3.org/2000/08/w3c-synd/style.css"; - } - $feed .= $this->_createStylesheetReferences(); - $feed .= "items[0]->thumb)) { - $feed .= " xmlns:photo=\"http://www.pheed.com/pheed/\"\n"; - } - if (!empty($this->items[0]->lat)) { - $feed .= " xmlns:georss=\"http://www.georss.org/georss\"\n"; - } - $feed .= " xmlns:dc=\"http://purl.org/dc/elements/1.1/\">\n"; - $feed .= " syndicationURL."\">\n"; - $feed .= " ".htmlspecialchars($this->title)."\n"; - $feed .= " ".htmlspecialchars($this->description)."\n"; - $feed .= " ".$this->link."\n"; - if ($this->image != null) { - $feed .= " image->url."\" />\n"; - } - $now = new FeedDate(); - $feed .= " ".htmlspecialchars($now->iso8601())."\n"; - $feed .= " \n"; - $feed .= " \n"; - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " items[$i]->link)."\"/>\n"; - } - $feed .= " \n"; - $feed .= " \n"; - $feed .= " \n"; - if ($this->image != null) { - $feed .= " image->url."\">\n"; - $feed .= " ".$this->image->title."\n"; - $feed .= " ".$this->image->link."\n"; - $feed .= " ".$this->image->url."\n"; - $feed .= " \n"; - } - $feed .= $this->_createAdditionalElements($this->additionalElements, " "); - - for ($i = 0; $i < count($this->items); $i++) { - $feed .= " items[$i]->link)."\">\n"; - $feed .= " text/html\n"; - if ($this->items[$i]->date != null) { - $itemDate = new FeedDate($this->items[$i]->date); - $feed .= " ".htmlspecialchars($itemDate->iso8601())."\n"; - } - if ($this->items[$i]->source != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->source)."\n"; - } - $creator = $this->getAuthor($this->items[$i]->author, $this->items[$i]->authorEmail); - if ($creator) { - $feed .= " ".htmlspecialchars($creator)."\n"; - } - if ($this->items[$i]->lat != "") { - $feed .= " ".$this->items[$i]->lat." ".$this->items[$i]->long."\n"; - } - if ($this->items[$i]->thumb != "") { - $feed .= " ".htmlspecialchars($this->items[$i]->thumb)."\n"; - } - $feed .= " ".htmlspecialchars( - strip_tags(strtr($this->items[$i]->title, "\n\r", " ")) - )."\n"; - $feed .= " ".htmlspecialchars($this->items[$i]->link)."\n"; - $feed .= " ".htmlspecialchars($this->items[$i]->description)."\n"; - $feed .= $this->_createAdditionalElements($this->items[$i]->additionalElements, " "); - $feed .= " \n"; - } - $feed .= "\n"; - - return $feed; - } - - /** - * Compose the RSS-1.0 author field. - * - * @author Joe Lapp - * @param string $author - * @param string $email - * @return string - */ - protected function getAuthor($author, $email) - { - if ($author) { - if ($email) { - return $author.' ('.$email.')'; - } - - return $author; - } - - return $email; - } -} diff --git a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator20.php b/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator20.php deleted file mode 100644 index dbc25ab..0000000 --- a/wiki/vendor/openpsa/universalfeedcreator/lib/Creator/RSSCreator20.php +++ /dev/null @@ -1,23 +0,0 @@ - - * @package de.bitfolge.feedcreator - */ -class RSSCreator20 extends RSSCreator091 -{ - - /** - * RSSCreator20 constructor. - */ - public function __construct() - { - parent::__construct(); - parent::_setRSSVersion("2.0"); - } - -} -- cgit 1.4.1-2-gfad0