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

JavaScript Using jQuery Plugins Add a Sticky Navigation Bar Adding Sticky Navigation

Matthew Peters
Matthew Peters
Full Stack JavaScript Techdegree Student 11,114 Points

Can someone please point out why sticky isn't working. I'm sure I've missed something, but I cannot see it.

I'm only on the second part all I've done is ad the sticky plugin to the HTML.

<!DOCTYPE html>
<html class="no-js">
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
        <title>Agency - A Treehouse template</title>
        <meta name="description" content="">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <link href='http://fonts.googleapis.com/css?family=Roboto:400,100,300,500,700,900' rel='stylesheet' type='text/css'>
        <link rel="stylesheet" href="css/normalize.min.css">
        <link rel="stylesheet" href="js/animsition/animsition.min.css">
        <link rel="stylesheet" href="css/main.css">
      <div class="row container animsition">
        <header class="row header">
          <div class="grid-third">
            <a href="index.html" class="logo"></a>
          <div class="grid-third">
            <h1 class="description">We build apps</h1>
          <div class="grid-third">
              <a href="#" class="active">Home</a>
              <a href="work.html" >Work</a>
              <a href="team.html" >Team</a>
        <div class="row">
          <div class="grid-full">

          <div class="main row">
            <div class="grid-third">
              <img src="img/sticker-team.png" alt="" />
              <p>United we stand divided we fail.  Meet the all star team behind the agency.</p>
              <a href="team.html" class="button">Meet the Team</a>
            <div class="grid-third">
              <img src="img/sticker-work.png" alt="" />
              <p>Check our latest app builds or download them in the App Store.</p>
              <a href="work.html" class="button">Latest Projects</a>
            <div class="grid-third">
              <img src="img/sticker-contact.png" alt="" />
              <p>Have questions or requests?  Feel free to contact us, we’d love hear from you.</p>
              <a href="#" class="button">Contact Us</a>
          <div class="row">
            <div class="grid-full">
              <p>Connect with us</p>
              <ul class="social">
                  <a href="#" class="pink"></a>
                  <a href="#" class="light-blue"></a>
                  <a href="#" class="dark-blue"></a>
      <script src="js/jquery-1.11.2.min.js"></script>
      <script src="js/animsition/jquery.animsition.min.js"></script>
      <script src="js/sticky/jquery.sticky.js"></script>
      <script src="js/main.js"></script>


  inClass: 'fade-in-right-lg',
  outClass: 'fade-out-right-lg',
  linkElement: 'header a',
  inDuration: 1000,
  outDuration: 500


Did you add the plugin to both team.html and work.html?

1 Answer