Cyber Week Sale! Get $20 off GP Premium, $40 off our new Lifetime license, and 45% off license renewals/extensions! Learn more

[Resolved] second style.css for some page.

Home Forums Support second style.css for some page.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #175696
    organ2

    Hi Tom. I need your help. For my main page I want use some style1.css and use common style.css for all other pages. I pasta this code in header.php between <head></head> but it didn’t help me. How can I do it?
    <?php if (is_page(’62’)) { ?>
    <link rel=”stylesheet” type=”text/css” media=”all” href=”style1.css” />
    <?php ;} else { ?>
    <link rel=”stylesheet” type=”text/css” media=”all” href=”style.css” />
    <?php ;}?>

    #175698
    organ2

    I do it). I just paste in style.css:

    body.page-id-62 #content {
    padding: 0px 40px 40px 40px;
    }

    #175722
    Tom
    Lead Developer
    Lead Developer

    Perfect 🙂

    Instead of pasting it into style.css, I suggest using our CSS plugin: https://generatepress.com/knowledgebase/adding-css/

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