Posted By

kahlil on 11/18/09


Tagged

url module news typolight


Versions (?)

News Module in Typolight: add year and month in the url


 / Published in: PHP
 

I added this code in the ModuleNews.php file on line 310 - 314.

  1. //print_r(date('Y',$objArticle->date));
  2. setlocale(LC_TIME, "de_DE");
  3. $monat = strftime('%B',$objArticle->date);
  4. if ($monat == 'März') $monat = 'Maerz';
  5. $strUrl = ampersand($this->generateFrontendUrl($objPage->fetchAssoc(), '/'.date('Y',$objArticle->date).'/'.$monat.'/items/' . ((!$GLOBALS['TL_CONFIG']['disableAlias'] && strlen($objArticle->alias)) ? $objArticle->alias : $objArticle->id))/*.'?year=2009'*/);

Report this snippet  

You need to login to post a comment.