Details
-
Bug
-
Resolution: Fixed
-
Medium
-
4.7.0, 5.0, 5.1, 5.2, 5.3-dev
Description
If you configure MobileSiteAccessURL to use a siteaccess passed trough URI, the redirection will fail and end up with "module not found" error.
This bug seems to happen because
// ezpublish_legacy/kernel/private/classes/ezpmobiledeviceregexpfilter.php // Line 121 if ( !isset( $_COOKIE['eZMobileDeviceDetect'] ) && !in_array( $currentSiteAccess['name'], eZINI::instance()->variable( 'SiteAccessSettings', 'MobileSiteAccessList' ) ) ) { $http->redirect( eZINI::instance()->variable( 'SiteAccessSettings', 'MobileSiteAccessURL' ) . eZSys::serverVariable( 'REQUEST_URI' )
eZ Publish will append eZSys::serverVariable( 'REQUEST_URI' ) at the end of MobileSiteAccessURL ignoring if among the REQUEST_URI is the siteaccess.
Steps to reproduce
- Configure site.ini.append.php of override with the following settings
[SiteSettings] DefaultAccess=eng
- Configure site.ini.append.php of eng siteaccess with the following settings
[SiteAccessSettings] DetectMobileDevice=enabled MobileSiteAccessURL=http://your-domain.com/iphone
- Open http://your-domain.com in your browser (from a mobile device) and confirm that you will end up in the correct mobile address: http://your-domain.com/iphone
- Now open your url with a siteaccess, in this case I'll use the default one eng: http://your-domain.com/eng
- If the bug is present, you will see the siteaccess uri part following the mobile siteaccess after the redirect: http://your-domain.com/iphone/eng.