Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • synapsis Friend
    #194384

    I’ve added a second button to section 1 of the OnePage template — and it works fine on the desktop. But on my Android smart phone it does nothing. The other button, however, works exactly as it should. Is there something wrong with having more than one button? Why would it work on desktops, but not my phone?

    I’ve included a screen-shot with denotation, but I encourage you to try it yourself on a smartphone to see if it works for you or not. I’ve duplicated the code for the button exactly, so I’m not sure why it’s not working.

    Your swift reply is greatly appreciated.

    Thank you.


    1. joomlart_support
    Wall Crasher Developer
    #521027

    @ synapsis,

    I have checked your site and see that the Porfolio block was hidden on mobile.
    There is no way to focus this block when you click on the button.

    Please have it shown on mobile layout (‘hidden-phone’ class suffix).

    synapsis Friend
    #523074

    I should clarify… I have TWO portfolio modules — both are at the same #portfolio location. But one is set to hidden-phone, and the other is set to hidden-desktop and hidden-tablet. Both are at the same #portfolio location, which is where the Hero Portfolio button points… so why doesn’t it go to whichever module is loading?

    The idea is to allow me to have two different portfolio layouts (1 image on phones vs. 4 images on everything else), along with different navigation.

    But if I understand you right, the Portfolio button in the hero section is pointing to only one of them — which works on the desktop and tablet, but not the phone? So do I need a second button that’s hidden-desktop and hidden-tablet that points to a different url? (not #portfolio?) That I can do… I just need to know where to point the new button to, to get to the appropriate module, depending on device.

    I’m sure this is also the reason for the main menu not working correctly. Again, any suggestions on what the different URL needs to be, if not #portfolio for both?

    Hope someone can help.
    Thanks!

    Wall Crasher Developer
    #523083

    @ synapsis,

    Since you have two modules with the same title, so when you click on the button, it does not know which portfolio module to focus.

    I have changed a little bit:

    1. In the /html/modules.php file:

    function modChrome_onepage($module, &$params, &$attribs)
    {
    static $zids;
    if(!$zids){
    $zids = array();
    }

    $lang = jFactory::getLanguage();
    $key = strtoupper(str_replace (‘ ‘, ‘_’, stripslashes($module->title)));
    $subtitlekey = ‘TPL_SUBTITLE_’.$key;
    $subtitle = JText::_($subtitlekey);
    $menuid = strtolower(str_replace (‘ ‘, ‘_’, stripslashes($module->title)));
    if($lang->isRTL() == 1){
    $menuid = ‘page-‘.$module->id;
    }else{
    $menuid = strtolower(str_replace (‘ ‘, ‘_’, stripslashes($module->title)));
    }

    if(in_array($menuid, $zids)){
    $menuid = $menuid . ‘_z’;
    }

    $zids[] = $menuid;
    ?>

    2 In the /js/script.js file:

    $target = $(target);
    if(!$target.is(‘:visible’)){
    $target = $(target + ‘_z’);
    }
    target = $target;

    Please check again and let me know how it goes.

    synapsis Friend
    #523099

    That appears to have done the trick… thank you. A most excellent solution. Bravo!

    I have one other challenge for you, if you’re familiar with the workings of the JA Content Popup module…

    I’d like to change the navigation function on the Portfolio slideshows… the dots for pages doesn’t work well, especially if you have a lot of slides, or in my case, wish to show them one slide at a time on smartphones.

    Is there more of a Right/Left arrow or Next/Previous button solution we could substitute for the dots? Show Nav Control doesn’t seem to do anything.

    Wall Crasher Developer
    #523687

    @ synapsis,

    I have added some style to the control Next/Prev button.
    Please check again.

    /* JA Content popup */ @media (max-width: 600px) {
    .ja-cp-controls {
    position: absolute;
    top: 30%;
    width: 100%;
    z-index: 100;
    }
    .ja-cp-prev {
    position: absolute;
    top: 0;
    left: 0;
    height: 40px;
    width: 40px;
    background: url(../images/arrow-left.png) 0 0 transparent no-repeat;
    }

    .ja-cp-next {
    position: absolute;
    right: 0;
    top: 0;
    width: 40px;
    height: 40px;
    background: url(../images/arrow-right.png) 0 0 transparent no-repeat;
    }

    .ja-cp-prev:hover,
    .ja-cp-next:hover {
    background-position: 0 bottom;
    }
    }

Viewing 6 posts - 1 through 6 (of 6 total)

This topic contains 6 replies, has 2 voices, and was last updated by  Wall Crasher 10 years, 9 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum