• Resolved lynnema

    (@lynnema)


    Hi everyone –

    I have developed a number of sites using Twenty Eleven. I’m familiar with using child themes, etc. For a new project, I’m checking out Twenty Twelve.

    I’m having the hardest time with the simplest thing – making template specific styles. In the past, I’ve created a custom page template, created a custom header and pointed that header at a specific stylesheet.

    I’m completely lost as to how to do this in this new setup. I also was trying to create page specific styles, but I don’t seem to be able to create them.

    Here is a sample page: https://69.195.124.71/~indusuf6/company/

    I tried using this: .page-template-page-inner-php body {background: none repeat scroll 0 0 #000;} and .template-page-inner body {background: none repeat scroll 0 0 #000;} Neither worked.

    The page template name is page-inner

    I don’t want to have to use the page ID, because I’m going to have a number of different pages, and this won’t be extensible. I really want it to be by page template.

    Any help would be greatly appreciated. Thanks in advance!

Viewing 2 replies - 16 through 17 (of 17 total)
  • this html code:

    <body class="home page page-id-5 page-template page-template-page-home-php custom-background custom-font-enabled single-author">

    translates for instance for the css into:

    body.page-template-page-home-php { ... }
    or
    .page-template-page-home-php { ... }
    or
    .home.page-template-page-home-php { ... }
    or in extreme
    body.home.page.page-id-5.page-template.page-template-page-home-php.custom-background.custom-font-enabled.single-author { ... }
    etc.

    w3school.com is good reference site – review those links posted by @andrew Nevins – this will save you a lot of trouble in the future.

    you can’t build a dream castle without proper foundations.

    Thread Starter lynnema

    (@lynnema)

    So, I finally got it figured out. If anyone else is trying to figure out what the class is for template based pages, it is:

    page-template-page-inner-php

    So – what follows page-template and before php.

Viewing 2 replies - 16 through 17 (of 17 total)
  • The topic ‘Twenty Twelve Page specific styles’ is closed to new replies.