[imp] Login problem with vinfo_hook

carlos maca macacohorde at gmail.com
Fri Jul 21 11:48:14 PDT 2006


Hi, i had put the imp_hook_vinfo to run, after do this in the login page the
domains appears before the user, this is ok, but when i try to log on, the
page loads, but dont log, in the firefox appears a message saying that the
page could not be load because the way the server is asking for it, and says
that this much be happening because some cookies must be blocked. In the
microsoftIE, it start to load the /horde/imp/redirect.php and never stop it
beeing in the login page.
-Here is the example of my imp_hook_vinfo :
   $HTTP_HOST = ' mail.pop-ro.rnp.br';
   $_SESSION['imp']['user'] = 'myname';
   $vdomain  = 'pop-ro.rnp.br';
   $username = 'myname_mydomain_com';

  if (!function_exists('_imp_hook_vinfo')) {
       function _imp_hook_vinfo($type = 'username')
       {
          $vdomain = getenv('HTTP_HOST');
          $vdomain = preg_replace('|^mail\.|i', '', $vdomain);
        $vdomain = String::lower($vdomain);

           if ($type == 'username') {
           return preg_replace('|\.|', '_', $_SESSION['imp']['user'] . '_' .
$vdomain);
           } elseif ($type == 'vdomain') {
               return $vdomain;
           } else {
               return PEAR::raiseError('invalid type: ' . $type);
           }
       }
           }
Any ideas, Thnks!


More information about the imp mailing list