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

Ruby

Wayne Fonseca
Wayne Fonseca
7,796 Points

[Help] Stuck on challenge 5

Add an a tag with the class "brand" and the content "Treebook"

http://teamtreehouse.com/library/programming/build-a-simple-ruby-on-rails-application/frontend-development/layouts

===========Code=========

<!DOCTYPE html> <html> <head> <title>Treebook</title> <%= stylesheet_link_tag 'application' %> </head> <body> <div class="navbar"> <div class="navbar-inner"> <div class="container"> </div> </div> </div> <div class="container"> <%= yield %> </div> </body> </html>

7 Answers

samiff
samiff
31,206 Points

Hey Wayne, seems like maybe you're putting it in the wrong area?

<div class="navbar">
    <div class="navbar-inner">
        <div class="container">
            <a class="brand">Treebook</a>
        </div>
    </div>
</div>

And the forums use Markdown for sytnax highlighting. You can see an easy way to format entire blocks of code in this post here.

Mike White
Mike White
23,234 Points

I believe it should look something like this.

<a href="#" class="brand">Treebook</a>

You are creating an anchor tag with the class "brand" and putting "Treebook" as the content of the anchor tag. Hope this helps.

Wayne Fonseca
Wayne Fonseca
7,796 Points

Thank mike, but seems that the issue states:

There is no a tag in your navbar container. By the way, how do you paste in the codes above? I cant seem to add in my codes?

Wayne Fonseca
Wayne Fonseca
7,796 Points

Thanks Sam, and great picture :) So here is the full script but seems adding below anywhere gives me this error: "Bummer! There is no a tag in your navbar container."

<a href="#" class="brand">Treebook</a>
<!DOCTYPE html>
<html>
  <head>
    <title>Treebook</title>
    <%= stylesheet_link_tag 'application' %>
  </head>
  <body>
    <div class = "navbar">
    <div class = "navbar-inner">
        <div class = "container">
      </div>
    </div>
  </div>
    <div class = "container">
    <%= yield %>
  </div>
  </body>
</html>
samiff
samiff
31,206 Points

Thanks Wayne! That <a> needs to go between

<div class = "container">
INSERT HERE
</div>

Tried it with your code exactly and it worked fine.

Wayne Fonseca
Wayne Fonseca
7,796 Points

Booya! Thanks a bunch Sam! Kudos to you!

samiff
samiff
31,206 Points

Glad to see you got it worked out :thumbsup: Keep up the good work!