Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Zen Hess
Zen Hess
6,700 Points

Blank page and erroneous page source in Linking CSS step

Hello! I've been cruising through the WordPress projects without issue until the Linking CSS step (https://teamtreehouse.com/library/websites/how-to-build-a-wordpress-theme/preparing-to-code-wordpress-templates/linking-css).

Up until this point, the page was viewable, just as Zac's was and the source code was also properly showing up. Unfortunately, once I linked the CSS to the file, the page began to display blank and the page source only displays this:

<!Doctype html>

<html>

<head>
<title>
    WordPress Portfolio</title>

Here is my functions.php folder:

<?php

/// Load the Theme's CSS ///
function theme_styles() {
wp_enqueue( 'normalize', get_template_directory_uri() . 'css/normalize.css' );
wp_enqueue( 'grid', get_template_directory_uri() . 'css/grid.css' );
wp_enqueue( 'googlefonts', get_template_directory_uri() . ' http://fonts.googleapis.com/css?family=Sorts+Mill+Goudy:400,400italic' );   
wp_enqueue( 'main', get_template_directory_uri() . 'style.css' );
wp_enqueue( 'social', get_template_directory_uri() . 'css/webfonts/ss-social.css' );

}
add_action( 'wp_enqueue_scripts', 'theme_styles' );


/// Enable Custom Menus
add_theme_support( 'menus' )


?>

Let me know if any other pages would be helpful, I would be glad to post them! Thanks in advance for any help.

Regards, Zen

2 Answers

Zac Gordon
STAFF
Zac Gordon
Treehouse Guest Teacher

There is a missing semi colon after the add_theme_support function that is likely causing the issue.

Zen Hess
Zen Hess
6,700 Points

That was part of it! But, unfortunately, I had some minor errors elsewhere. Back on track now. Thanks, Zac!