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

CSS How to Make a Website CSS: Cascading Style Sheets Center the Wrapper

Ray Kennedy
PLUS
Ray Kennedy
Courses Plus Student 2,982 Points

doesn't look right

I'm developing along with the video but I'm using laravel. his bullet points move from the bottom left, to the top left. Is this because I'm using laravel? things like this drive me crazy please help. as I feel like theres something wrong.

my master layout:

<!doctype html>

<html lang="en">
    <head>
        <title>ray Kennedy | Designer</title>





        <!-- this has to come before my app.css or it wont work-->
        <link href="{{ asset('css/main.css') }}" rel="stylesheet" type="text/css" >


        <!-- Latest compiled and minified CSS -->
        <link href="{{ asset('css/normalize.css') }}" rel="stylesheet" type="text/css" >



        <meta charset=“UTF-8”>
        <meta name="viewport" content="width=device-width, initial-scale=1">



        <!-- jQuery library -->
        <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>

        <!-- Latest compiled JavaScript -->
        <script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
    </head>

    <body>

        <header>
            <a href="{{ action('HomeController@index')   }}">
                <h1>ray Kennedy</h1>
                <h2>Designer</h2>
            </a>

            <nav>
                <ul>
                    <li><a href="{{ action('HomeController@index')   }}">HOME</a></li>
                    <li><a href="{{ action('AboutController@index')  }}">ABOUT</a></li>
                    <li><a href="{{ action('ContactController@index')}}">CONTACT</a></li>
                </ul>
            </nav>
        </header>

        <div id="wrapper">

            <section>
                @yield('content')
            </section>

            <footer>
                <a href="#">{!! Html::image('image/twitter-wrap.png', 'Facebook logo') !!}</a>
                <a href="#">{!! Html::image('image/facebook-wrap.png', 'Twitter logo') !!}</a>
                <p>&copy; 2014 ray Kennedy.</p>
            </footer>

        </div>

    </body>
</html>

my main css:

a {
    text-decoration: none;
}

#wrapper {
    max-width: 940px;
    margin: 0 auto;
    padding: 0 5%;

}

nav li {
    list-style: none;
}
Sam Baines
Sam Baines
4,315 Points

Post your code Ray and maybe some people can help you out.

1 Answer

Shawn Flanigan
PLUS
Shawn Flanigan
Courses Plus Student 15,815 Points

Hi Ray,

I've never worked with laravel, but I doubt that's the issue. Not sure if this is it, but...I noticed that you have your main.css called above your normalize.css. You probably want to switch that. Normalize it first and then add your styling. Otherwise, any styling you do in main.css can be overridden by normalize.css.

Hope that does the trick!

Shawn Flanigan
Shawn Flanigan
Courses Plus Student 15,815 Points

It's also possible that you have an error in the content that you're inserting using @yield('content'). An extra closing div tag would certainly cause the #wrapper styling to fail.