• Resolved JCKnoell

    (@jcknoell)


    I need to create a new page on my site and I need to start from scratch on it. It needs to not have ANY of the themes, headers, menus, footers, etc. of the rest of the site.
    How do I block the CSS on just one page? (I know about using the
    <?php if (!is_page('')) { ?>
    but I don’t want to have to go through every single style sheet and theme editor and put that in every one. Is there any way to do this once for just one page?

    Thanks!

Viewing 15 replies - 1 through 15 (of 21 total)
  • Create a custom page template and then target your CSS effectively using the classes generated on the opening body tag.

    Thread Starter JCKnoell

    (@jcknoell)

    I’m sorry, I’m a little new to the whole CSS scene… would you be willing to be a little more specific on how to do that, exactly?

    What theme are you using? Where did you download it from?

    Thread Starter JCKnoell

    (@jcknoell)

    It wasn’t my site to begin with, I’ve been brought on as a consultant, so I don’t know everything about the site yet. We’re using “Mingle” and Twenty Eleven and Twenty Ten

    Try looking at the classes generated on the opening body tag of any page.

    Thread Starter JCKnoell

    (@jcknoell)

    So, I’ve found them. What now? Those are what I don’t want on my new page, right? But the “body” tag isn’t accessible for just one page with wordpress, right?

    Yes – it’s on every page. And on a page with a custom page template, a new class – specific to that page template – is added to the list of body classes. You can use this in your theme’s stylesheet to target your CSS effectively.

    Thread Starter JCKnoell

    (@jcknoell)

    Will that overwrite all the other styling that has already loaded then from all the other tags?
    If so, how do you create a custom template and load it on only that page?

    Will that overwrite all the other styling that has already loaded then from all the other tags?

    with the right CSS specificity & rules, yes.

    how do you create a custom template and load it on only that page

    See custom page templates

    Thread Starter JCKnoell

    (@jcknoell)

    Thank you. You’ve been a great help. ??

    Thread Starter JCKnoell

    (@jcknoell)

    I can’t find the “templates” dropdown in the page edit screen… It has the parent dropdown and the Order box… where’s the template drop down?

    Your theme has to have at least 1 custom page template before the Templates dropdown automagically appears.

    Thread Starter JCKnoell

    (@jcknoell)

    My theme doesn’t have that… Can I add one?

    Well, yes. That’s what I’ve been suggesting ??
    What theme are you using? Where did you download it from?

    Thread Starter JCKnoell

    (@jcknoell)

    It’s called “mingle” I don’t where it’s from. How do I add a new one… Sorry, this must sound so silly… Haha

Viewing 15 replies - 1 through 15 (of 21 total)
  • The topic ‘Remove ALL CSS from a single page’ is closed to new replies.