047925ca0c7b374a42493b1311a3480dbcfba97e
Benjamin Renard Initial commit

Benjamin Renard authored 12 years ago

1) <?php
2) /**
3)  * Project infos plugin for ViewGit.
4)  *
5)  * This add project infos on summary page.
6)  *
7)  * @author Benjamin Renard <brenard@easter-eggs.com>
8)  */
9) class ProjectInfosPlugin extends VGPlugin
10) {
11) 	function __construct() {
12) 		$this->register_hook('summary');
13) 	}
14) 
15) 	function hook_summary() {
16) 		global $page;
17) 		$page['project_infos']=get_project_info($page['project']);
Benjamin Renard Fixed convertion of non arr...

Benjamin Renard authored 11 years ago

18) 		if (isset($page['project_infos']['url']) && !is_array($page['project_infos']['url'])) {
19) 			$page['project_infos']['url']=array($page['project_infos']['url']);