How to show or hide side panel by script?

1 reply · opened Jun 26, 2019

AalexbaiJun 26, 2019

How to show or hide side panel by script?

I have add one button(id="showPanelBtn") which has a onclick event as follows:

$("#showPanelBtn").click(function(){
$(".side-panel-trigger").trigger('click');
});

But, it doesnot work.

Please help. Thanks a lot

SSemicolon WebSTAFFJun 27, 2019

Hello,

Instead of using the above code, simply add the .side-panel-trigger Class to the #showPanelBtn Element.

This will definitely work fine. Hope this Helps!

Let us know if we can help you with anything else or if you find any further issues.

Have the same question, or something new?

Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.

Reply on the dashboard