Start a new topic

JS | How to hide opening hours or company address based on GET parameters

If you use a minisite as a list of locations, you may want to hide the opening hours and address when the widget displays the widget displays the list of your locations:

var url = new URL(window.location.href);
const urlParams = new URLSearchParams(;
const cs = urlParams.get('cs');
if (cs == null) {
    $(".left .info.hours", window.parent.document).hide();
    $(".left .info.address", window.parent.document).hide();

This will have the following effect:

Login or Signup to post a comment