• Resolved porkchop_001

    (@porkchop_001)


    Hi Guys,

    Really odd issue. My home page (index.php) isn’t loading the stylesheet…yet if I click-through to an individual blog post, it’s rendering perfectly (i.e. the stylesheet is loading/rendering correctly).

    Any reason why this is happening? I’ve tried all sorts of methods to isolate the issue – but I’m completely stuck.

    FYI using the Bones theme.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator keesiemeijer

    (@keesiemeijer)

    Please post a link to your site.

    Try:
    – deactivating all plugins to see if this resolves the problem? If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    – switching to the default theme (Twenty Fourteen) to rule out any theme-specific problems.

    Thread Starter porkchop_001

    (@porkchop_001)

    Hi. I’m developing locally via MAMP – so I’m afraid I can’t link anyone to the site.

    Yes – I’ve looked up older threads concerning a similar issue, and like your suggestion, have attempted to deactivate all plugins and changing back to the default theme.

    Changing themes fixes things – thus the issue lies in my stylesheet somewhere. I’m just not sure where. It’s very confusing. I’ve looked for brackets that haven’t been closed – and still no luck. Why on earth would it break JUST the index.php and not the other pages? They’re all connecting to the one .css file – aren’t they?

    Moderator keesiemeijer

    (@keesiemeijer)

    Can you post your theme’s header.php file here. Did you make any edit’s to it?

    Check in the source code of your browser if the stylesheet url is the same for the front page and your single posts.

    Thread Starter porkchop_001

    (@porkchop_001)

    I don’t recall making any edits to it. The header.php file was one of the first places I went to when things started going belly up. Admittedly, it wouldn’t hurt for another pair of eyes to look over it ??

    <!doctype html>
    
    <!--[if lt IE 7]><html <?php language_attributes(); ?> class="no-js lt-ie9 lt-ie8 lt-ie7"><![endif]-->
    <!--[if (IE 7)&!(IEMobile)]><html <?php language_attributes(); ?> class="no-js lt-ie9 lt-ie8"><![endif]-->
    <!--[if (IE 8)&!(IEMobile)]><html <?php language_attributes(); ?> class="no-js lt-ie9"><![endif]-->
    <!--[if gt IE 8]><!--> <html <?php language_attributes(); ?> class="no-js"><!--<![endif]-->
    
    <head>
    	<meta charset="utf-8">
    
    	<?php // Google Chrome Frame for IE ?>
    	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    
    	<title><?php wp_title(''); ?></title>
    
    	<?php // mobile meta (hooray!) ?>
    	<meta name="HandheldFriendly" content="True">
    	<meta name="MobileOptimized" content="320">
    	<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
    
    	<?php // icons & favicons (for more: https://www.jonathantneal.com/blog/understand-the-favicon/) ?>
    	<link rel="apple-touch-icon" href="<?php echo get_template_directory_uri(); ?>/library/images/apple-icon-touch.png">
    	<link rel="icon" href="<?php echo get_template_directory_uri(); ?>/favicon.png">
    	<!--[if IE]>
    		<link rel="shortcut icon" href="<?php echo get_template_directory_uri(); ?>/favicon.ico">
    	<![endif]-->
    	<?php // or, set /favicon.ico for IE10 win ?>
    	<meta name="msapplication-TileColor" content="#f01d4f">
    	<meta name="msapplication-TileImage" content="<?php echo get_template_directory_uri(); ?>/library/images/win8-tile-icon.png">
    
    	<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>">
    
    	<?php // wordpress head functions ?>
    	<?php wp_head(); ?>
    	<?php // end of wordpress head ?>
    
    	<?php // drop Google Analytics Here ?>
    	<?php // end analytics ?>
    
    </head>
    
    <body <?php body_class(); ?>>
    
    <div id="container">
    
    	<header class="header" role="banner">
    		<!-- <div id="inner-header" class="wrap clearfix"> -->
    			<div class="logo">
    				<a href="<?php echo home_url(); ?>"><img src="<?php echo get_template_directory_uri(); ?>/library/images/regen-logo-single.png" /></a>
    			</div>
    		<!-- </div> -->
    	</header>

    Will check source code now.

    Thread Starter porkchop_001

    (@porkchop_001)

    Ah, d’uh *face palm*

    For some unknown reason, the ‘<?php get_header(); ?> had fallen out. Not sure how and when that happened…but it caused a lot of unnecessary stress.

    Thanks for your help anyway – keesiemeijer ??

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Stylesheet not loading on index.php – but fine on single.php’ is closed to new replies.