Ok, so I am making a one-pager with 4 different 'pages'. Everything was working normally before, I was referring to elements on the page that had an ID in CSS, and it worked like a charm.
However, now it does not. It does move me somehow, but never correct, and the weirdest thing is that it varies for each time!
This is how my menu look like.
<a href="#one" class="smoothScroll"> Kom i gang </a></li> <a href="#two" class="smoothScroll"> Utstyr</a> </li> <a href="#three" class="smoothScroll"> Oppskrifter</a> </li> <a href="#four" class="smoothScroll"> Kontakt </a></li> This is how one of the elements I am linking to look like in CSS:
#two { position: absolute; height: 120%; top: 275%; z-index: 1000; width: 100%; border-top: 4px #444444 outset; border-bottom: 4px #444444 outset; background-color: #C7A066; color: #ffffff; background-image: url('../img/pattern.png'); } I hope somebody can help me :-) It's quite annoying!
tl;dr the links does not seem to take me to the element i'm referring to. what has gone wrong?
idofoneortwo...?<li>starting tags are missing!