1
1
Fork 0

per design spec, hide global directory if update url not present

This commit is contained in:
Mike Macgirvin 2010-09-23 18:33:07 -07:00
parent 4c2fbc81a0
commit 0ebd4aa783
2 changed files with 8 additions and 2 deletions

View file

@ -10,10 +10,16 @@ function directory_content(&$a) {
$tpl .= load_view_file('view/directory_header.tpl');
$globaldir = '';
$gdirpath = dirname(get_config('system','directory_submit_url'));
if(strlen($gdirpath)) {
$globaldir = '<ul><li><div id="global-directory-link"><a href="'
. $gdirpath . '">' . t('Global Directory') . '</a></div></li></ul>';
}
$o .= replace_macros($tpl, array(
'$search' => $search,
'$globaldir' => $globaldir,
'$finding' => (strlen($search) ? '<h4>' . t('Finding: ') . "'" . $search . "'" . '</h4>' : "")
));

View file

@ -1,6 +1,6 @@
<h1>Site Directory</h1>
<ul><li><div id="global-directory-link"><a href="http://dir.dfrn.org">Global Directory</a></div></li></ul>
$globaldir
$finding