[horde] MIMP : I find out a bug I resolved

Gerard Breiner gerard.breiner at ias.u-psud.fr
Mon Nov 3 11:01:01 UTC 2008


Hello,

I wanted to add a link "Accueil" to the menu of Mimp by using  
config/menu.php  but unsuccessfull.
So, here is what I modified so that it could works.

mimp/config/menu.php

This  pattern is not correct $_menu[] = array( 'url' =>        
'http://www.example.com/',  'text' =>       'Example, Inc.');
The good pattern is :
$_menu = array( 'your url' =>        'your text');

for example in my case  :  $_menu = array( '/dimp' =>        'Accueil');

mimp/index.php

I added :
if (is_readable(MIMP_BASE . '/config/menu.php')) {
    require MIMP_BASE . '/config/menu.php';
}

mimp/mailbox.php

Before the "foreach of $items" I added :

foreach ($_menu as $link => $label) {
    $mset->add(new Horde_Mobile_link($label, $link));
}

After having these modifications my link "Accueil" is added at the top 
of the menu. I hope my humble contribution will be usefull.

Best regards

Gerard


 





-- 
Université Paris-Sud 11
Institut D'Astrophysique Spatiale
Gérard Breiner
Rue Georges Clémenceau
fr-91405 Orsay-ville 



More information about the horde mailing list