I am using this code in main page
$w.onReady( function () {
//TODO: write your page related code here…
$w(“#button2”).show();
$w(“#horizontalMenu1”).show();
$w(“#button3”).hide();
});
and on another page
$w.onReady( function () {
//TODO: write your page related code here…
$w(“#horizontalMenu1”).hide();
$w(“#button2”).hide();
$w(“#button3”).show();
});
to show and hide some elements based on the current context. This works fine on desktop version but for the mobile version I am getting “#horizontalMenu1” is not a valid selector - error.
I’m guessing the mobile version is using “mobileMenu1” #instead of “#horizontalMenu1”.
So how get rid of this error? Can anyone please help me out with this?