Ignore:
Timestamp:
12/22/10 15:39:15 (13 years ago)
Author:
eduardoalex
Message:

Ticket #1470 - Redirecionamento para o expresso mini a depender da plataforma.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2/login.php

    r3448 r3621  
    1111        *  option) any later version.                                              * 
    1212        \**************************************************************************/ 
    13  
     13         
    1414        $phpgw_info = array(); 
    1515        $submit = False;                        // set to some initial value 
     
    4040                if(function_exists('CreateObject')) 
    4141                { 
     42                        //detect if the user has a compatible browser, if don't have send him to expresso mini 
     43                        $browser = CreateObject('phpgwapi.browser'); 
     44                         
     45                        switch ($browser->get_platform()) { 
     46                                case browser::PLATFORM_IPHONE: 
     47                                case browser::PLATFORM_IPOD: 
     48                                case browser::PLATFORM_IPAD: 
     49                                case browser::PLATFORM_BLACKBERRY: 
     50                                case browser::PLATFORM_NOKIA: 
     51                                case browser::PLATFORM_ANDROID: 
     52                                        $GLOBALS['phpgw']->redirect_link('/mobile/');                                    
     53                                        break; 
     54                                default: 
     55                                        break; 
     56                        } 
     57                         
    4258                        $GLOBALS['phpgw']->session = CreateObject('phpgwapi.sessions'); 
    4359                } 
     
    99115                $GLOBALS['phpgw']->session->phpgw_setcookie('serverID', $GLOBALS['phpgw_info']['server']['use_frontend_id']); 
    100116        } 
    101 if($GLOBALS['phpgw_info']['server']['captcha']==1) 
     117        if($GLOBALS['phpgw_info']['server']['captcha']==1) 
    102118  { 
    103119     session_start(); 
    104120  } 
    105 include(personalize_include_path('phpgwapi','login')); 
     121        include(personalize_include_path('phpgwapi','login')); 
    106122?> 
    107123 
Note: See TracChangeset for help on using the changeset viewer.