- Timestamp:
- Mar 6, 2013, 4:06:03 AM (11 years ago)
- Location:
- lib
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
lib/menu.php
r347 r348 64 64 } 65 65 66 function convert_news_data() { 66 /** 67 * Liest das YAML-formatierte News-Menue aus der news.php-File der entsprechenden 68 * Sprache aus und erzeugt daraus ein HTML-Menue, welches als String zurueckgegeben 69 * wird. 70 * @param $host Instance of t29Host which can be used for link rewriting if given. 71 **/ 72 function convert_news_data($host=null) { 67 73 require $this->conf['lib'].'/spyc.php'; 68 74 $data = Spyc::YAMLLoad($this->load_news_data()); … … 77 83 } else { 78 84 $url = ($e['link']{0} == '#' ? $this->conf['lang_path'].'/'.self::news_file : '').$e['link']; 85 if($host) 86 $url = $host->rewrite_link($url); 79 87 $li = "<li><a href='$url'>$e[titel]<span class='hidden'>: </span><em>$e[text]</em></a></li>"; 80 88 } … … 271 279 if($xpath_menu_selection == self::horizontal_menu) { 272 280 # inject news 273 $news_ul_content = $this->convert_news_data( );281 $news_ul_content = $this->convert_news_data($host); 274 282 $magic_comment = '<!--# INSERT_NEWS #-->'; 275 283 $menu = $xml->ul->asXML(); -
lib/template.php
r347 r348 232 232 ?> 233 233 234 <link rel="copyright" href="<?php $href($p('footer-legal-file')); ?>" title="<?php $href($p('footer-legal-link')); ?>">235 <link rel="search" type="application/opensearchdescription+xml" href="<?php $href($p('topnav-search-page')); print '?action=opensearch-desc&lang='.$this->conf['lang']; ?>" title="<?php $p('opensearch-desc'); ?>">234 <link rel="copyright" href="<?php print $href($_('footer-legal-file')); ?>" title="<?php $p('footer-legal-link'); ?>"> 235 <link rel="search" type="application/opensearchdescription+xml" href="<?php print $href($_('topnav-search-page')); print '?action=opensearch-desc&lang='.$this->conf['lang']; ?>" title="<?php $p('opensearch-desc'); ?>"> 236 236 <?php 237 237 // print interlanguage links for all languages except the active one
Note: See TracChangeset
for help on using the changeset viewer.