Changeset 1a0f60b in github


Ignore:
Timestamp:
Dec 9, 2011 4:38:34 AM (18 months ago)
Author:
thomascube <thomas@…>
Branches:
master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.8
Children:
231fae7
Parents:
6807865d
Message:

Allow custom content (from config dir) showing up on the about page

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • program/include/rcube_template.php

    rf230739 r1a0f60b  
    9595            'message'         => array($this, 'message_container'), 
    9696            'charsetselector' => array($this, 'charset_selector'), 
     97            'aboutcontent'    => array($this, 'about_content'), 
    9798        )); 
    9899    } 
     
    13361337    } 
    13371338 
     1339    /** 
     1340     * Include content from config/about.<LANG>.html if available 
     1341     */ 
     1342    private function about_content($attrib) 
     1343    { 
     1344        $content = ''; 
     1345        $filenames = array( 
     1346            'about.' . $_SESSION['language'] . '.html', 
     1347            'about.' . substr($_SESSION['language'], 0, 2) . '.html', 
     1348            'about.html', 
     1349        ); 
     1350        foreach ($filenames as $file) { 
     1351            $fn = RCMAIL_CONFIG_DIR . '/' . $file; 
     1352            if (is_readable($fn)) { 
     1353                $content = file_get_contents($fn); 
     1354                $content = $this->parse_conditions($content); 
     1355                $content = $this->parse_xml($content); 
     1356                break; 
     1357            } 
     1358        } 
     1359 
     1360        return $content; 
     1361    } 
     1362 
    13381363}  // end class rcube_template 
    13391364 
  • skins/default/templates/about.html

    r7bb5f63 r1a0f60b  
    1515<div class="readtext"> 
    1616<div id="license"> 
     17<roundcube:object name="aboutcontent" /> 
    1718<h2 class="sysname">Roundcube Webmail <roundcube:object name="version" /></h2> 
    1819<p class="copyright">Copyright &copy; 2005-2011, The Roundcube Dev Team</p> 
Note: See TracChangeset for help on using the changeset viewer.