Sigurjón Sigurjón - 1 year ago 83
CSS Question

Hide header/footer when url contains a certain parameter

I have a multi page webpage that has a header and footer on all pages,
and I am creating an app than can view certain areas of the page, but I dont want to show the footer and header when I am browsing through the app.

When I access the page through the app the app adds a parameter to the url. like this:

What is the most efficient way to this with java script and css?

Answer Source
        var url = window.location.href;
        if('inapp=true') === true){
            $('header').css('display', 'none');
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download