Selectors for h1-h6 – distinction between post & page

Posted in: Newspaper
Post count: 30

Hi there,

I want to target h1-h6 in my style.css, but I can’t find a way to distinguish between page h1-h6 and post h1-h6.

If I e.g. use

.td-post-content h1, h2, h3, h4 {
font-family: ‘Francois One’, sans-serif!important;
font-weight: bold!important;

…this not only applies for my posts, but also for all my pages (widgets!).

Can you help me out here?

Thanks!

Post count: 23312

Hello muggi15,

Please notice that if you want to change the headings for your pages you will have to edit the code from the page template if you are using on your side (page.php, page-pagebuilder-latest.php and page-pagebuilder-title.php), like this -> http://screencast.com/t/n5FoS0MB and for posts, you will have to edit the td_module_single_base.php like this -> http://screencast.com/t/SuyhomF3e

Hope this helps!

Thanks for your understanding!

Post count: 30

Hi Catalin,

thx for your reply! Would you mind to explain why I have to switch to the td_module_single_base.php instead of just using the style.css?

The reason I’m asking is that I’m currently already using the style.css for several css modifications (which btw started the moment a member of your support team suggested to modify stuff like that 😉 (that was another question i’ve posted several days ago).

Thanks!

Post count: 23312

Hello muggi15,

Please try to check all the settings from Theme panel for Headings for pages and posts, like this -> http://screencast.com/t/jWFOTiVOp2f and from there you will be able to change these parameters as you wish. Also, please notice that you can use a bit of CSS code to target these H Tags. For example, for pages, you can use the code below ->
.page H1 {
your code
}

and for post pages ->

.single H1 {
your code
}

Hope this helps!

Thanks for your understanding!

Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic.