• Hi! I created a custom theme template by naming it homepage-template.php in my child theme and starting it with:

    <?php
    /*
    Template Name: Home Page
    */ ?>

    Problem: I added HTML, but my stylesheet and images aren’t being called. I’m linking it correctly. It’s in the same directory line. Why isn’t anything showing up?

    I also tried this in my header.php and it didn’t work:

    <?php if( is_page_template('homepage-template.php')  ) :?>
    <link rel="stylesheet" href="<?php bloginfo('template_directory'); ?>home-style.css" media="screen" type="text/css" />
    <?php else:?>
    <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
    <?php endif;?>

    Link: https://www.rachelsilberman.com/dianealberts/jen-mclaughlin/

Viewing 1 replies (of 1 total)
  • Thread Starter Rachel

    (@xxrayray)

    Fixed it. Put the styles in style.css and called it using this code:

    <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" />

    Thanks anyway!

Viewing 1 replies (of 1 total)
  • The topic ‘CSS/images not being called into my custom theme’ is closed to new replies.