Hello there! Welcome to Youjoomla Support Forums

We are Web Development Company specializing in Joomla Templates , Joomla Extensions and WordPress Themes development . You are not able to see some forum threads due to your memberhip level. To unlock all forums and special customer support please take few moments to signup . If you are just searching for free joomla templates , or free joomla extension support simply head to our Free Joomla Support forums and open a new thread. Our moderators will help you as soon as possible. To spead up the response time please take few seconds and go over forum rules

Have fun!

[SOLVED] Menu fails on small resolution when Joomla Caching is on

07-24-2013, 07:55 AM
# 1 (permalink)
adiehm
When the screen width is made narrow enough to make the menu switch to the mobile version or the site is viewed on a mobile device the the menu no longer functions if the Joomla Caching is enabled

With Joomla Caching turned on no mater what menu option is selected the website remains on the home page - Switch Joomla Caching off and it comes good again - Switch Joomla Caching on and the menu will work 2 or 3 times than stops.

I see this on both "Developer Box" and "Yougrids 1.04"

Ipswich - Yamanto Metal Traders "Developer Box" Caching is off - Menu works on narrow screen width

Car and Truck Licences - Ipswich Prodrive "Yougrids 1.04" Caching is on - Menu does not work on narrow screen width.

I have changed the Custom.CSS file on both sites
I have changed yjresponsive.js on ipswichprodrive.com.au function size_menu() and function resize() widths changed from 980 to 768

Are you sure your are posting in product assigned forum?: Yes

What is your CMS version?: Joomla 2.5

MySQL Version: 5.x

PHP version: 5.x

Link to installation: Ipswich - Yamanto Metal Traders

Have you edited any files? If yes tell us which ones.: Yes

Is this personal or client website?: Client
07-29-2013, 06:57 AM
# 2 (permalink)
neo
did you test the menus on our demos ? what particular caching setting are you talking about. module caching or ?
07-29-2013, 07:08 AM
# 3 (permalink)
adiehm
did you test the menus on our demos ? : no
what particular caching setting are you talking about? :
Joomla - admin - Site - Global Config - System - Cache Settings.
Cache: On Conservative or on Progressive
Cache Handler :File
Cache Time: 15
07-30-2013, 08:09 AM
# 5 (permalink)
neo
u right , the mobile menu list is not being populated properly , will work on this today and advise , keep it off for now please
07-30-2013, 08:37 AM
# 7 (permalink)
neo
working on better option since menuitem->link does not match the actual link and JRoute is not working properly , disregard solution above for few min untill I reply back
07-30-2013, 08:57 AM
# 8 (permalink)
neo
OK here is better one wich check all possible route options



template/YJSG_BASED_TEMPLATE/layouts/yjsg_mobilemenu.php

change lines 61-65

PHP Code:

        if($menuitem->id == $SetActiveId){
            
$selected ' selected="selected"';
        }else{
            
$selected ='';
        } 


to


PHP Code:

        
        
        
if($menuitem->id == $SetActiveId){
            
$selected ' selected="selected"';
        }else{
            
$selected ='';
        }
        
$menuitem->flink $menuitem->link;
        switch (
$menuitem->type)
        {
            case 
'separator' :
                continue;

            case 
'url' :
                if ((
strpos($menuitem->link'index.php?') === 0) && (strpos($menuitem->link'Itemid=') === false))
                {
                    
$menuitem->flink $menuitem->link.'&Itemid='.$menuitem->id;
                }
                break;

            case 
'alias' :
                
$menuitem->flink 'index.php?Itemid='.$menuitem->params->get('aliasoptions');
                break;

            default :
                
$router JSite::getRouter();
                if (
$router->getMode() == JROUTER_MODE_SEF)
                {
                    
$menuitem->flink 'index.php?Itemid='.$menuitem->id;
                }
                else
                {
                    
$menuitem->flink .= '&Itemid='.$menuitem->id;
                }
                break;
        }

        if (
strcasecmp(substr($menuitem->flink04), 'http') && (strpos($menuitem->flink'index.php?') !== false))
        {
            
$menuitem->flink JRoute::_($menuitem->flinktrue$menuitem->params->get('secure'));
        }
        else
        {
            
$menuitem->flink JRoute::_($menuitem->flink);
        } 

or download the attached file , unzip it and replace existing

template/YJSG_BASED_TEMPLATE/layouts/yjsg_mobilemenu.php

with the new one
Attached Files
File Type: zip yjsg_mobilemenu.zip (1.5 KB, 29 views)
08-01-2013, 06:12 PM
# 9 (permalink)
adiehm
Thanks for the quick response, but there is still a minor problem - The fix allows you to navigate using the menu to all pages except back to the Home page.

I installed the zip file on this site Car and Truck Licences - Ipswich Prodrive

Second point: Not sure if this is by design or not, The mobile menu always shows "Home" regardless of the page you are on.
08-01-2013, 06:50 PM
# 10 (permalink)
neo
I see , sef is not converting those links correctly ,
your link is index.php truck and mobile link is
index.php/component/content/category/9-truck-lessons?layout=blog

SIlviu is out till Tuesday , I am defending our server with arms and legs since about 6 days from an awful attack and getting ready to release new template, il have him look deeper in to this one he is back.
Thread Tools
Display Modes

Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.

Members Login

Username
Password