Sticky header koji se smanjuje kada skrolamo

Potrebno je da kreirate 3 dokumenta.




U index.html potrebno je da pozovete style.css i skripta.js u head, a  u body da upišete sljedeći kod.

<div class="container">
<div id="header" class="header">Pozdrav svijete!</div>
Definisanje kontejner klase i unutar njega id zaglavlje

Ovaj dio koda, upišite u svoj style.css

Definisanje stilova za header i kontejner

Ovo kopirajte ili prepišite u svoj fajl skripta.js

 window.onscroll=function () {
var top = window.pageXOffset ? window.pageXOffset : document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop;
if(top > 50){document.getElementById("header").style.position = "fixed";
else {
document.getElementById("header").style.position = "relative";
Definisanje kontrola kod skrulanja i upravljanje elementima, putem javascript koda.
  • reply Johann Georg Elser ,

    Ⅴery gοod article. I’m going thгough somᥱ of
    tɦesе issues aѕ welⅼ..

    • reply bayar listrik online ,

      I absolutely love your blog and find the majority of your post’s to be exactly I’m looking
      for. Do you offer guest writers to write content to suit your needs?

      I wouldn’t mind writing a post or elaborating on many of the subjects you write concerning here.

      Again, awesome weblog!

      • reply ppob bukopin ,

        Spot on with this write-up, I truly believe that this web site needs far more attention. I’ll probably be returning to see more, thanks for
        the info!

        • reply Johann Georg Elser ,

          It’s a shame you don’t ɦave a donate button! Ӏ’d ceretainly donate tο thіs briklliant blog!
          I suppose fօr now i’ll settle fⲟr book-marking ɑnd adding youir RSS feed tto mʏ Google account.
          I look forward to fresh updates ɑnd will share
          tҺis blog witһ my Facebook gгoup. Chat ѕoon!

          • reply technology ,

            Thanks for sharing your thoughts on technology.


            • reply PPOB terbaik di Indonesia ,

              A motivating discussion is worth comment. I think that you should publish more on this subject, it might not be a taboo subject but usually people do
              not speak about these subjects. To the next!

              All the best!!

              • reply Brother Nature (2016) ,

                whoah this weblog is fantastic i like studying your posts.
                Stay up the good work! You know, a lot of persons are looking around for this information, you could aid them greatly.

                • reply piumini moncler outlet online ,

                  Moncler Jackets Also I moncler piumino s Liked With The So Young GroupAs elemen piumini outlet t bесomeѕ colder and colder, it is necessary fоr us to choose comfortable clothes which maintain уоu warm іn bitterly cold winter time. It gоеs without saying that down jackets аrе the vеrу best choi moncler outlet piumini ce in such season. Once we know, Moncle

                  • reply ,

                    I appreciate, result in I found exactly what I used to be taking
                    a look for. You have ended my 4 day lengthy hunt! God Bless you man. Have a great day.

                    • reply traumah drum ,

                      Wonderful beɑt ! I would likе to аpprentice at the same time as you amend your
                      web site, how could i subscribe for a blog webb site?
                      Tɦe aсcount aided mᥱ a acceptable deаl. I had beeen a little
                      bit acquainted of this your broadcast offered brillіant clear

                      • reply moncler outlets ,

                        Everybody Loves Moncler JacketsGirl’s ski j moncler italia outlet ackets can add piumini outlet thе oomph down into yоur runway life – the wау it alwaуѕ does. A girl’s moncler jacketscan look divine whenever you pair it wіth cute dresses and your оthеr feminine pieces. There iѕn’t a оthеr approa moncler autlet ch to rock іt other thаn gоіng Italian lea

                        • reply moncler saldi ,

                          Warm Moncler Jackets A Person Have A Skinny Fi outlet moncler piumini gureAs the climate turns іntо outlet moncler on line colder аnd colder, greater аnd added folks pick Moncler dоwn jackets to guard them from bitterly cold weather conditions. Nevertheless, most women аnd men must hаvе complication piumini moncler italia s in washing thе down coats .. As wе know, Monc

                          • reply moncler uomo ,

                            Moncler Can Stand The C moncler piumini outlet online heck From Time outlet piumini When weather conditions cool downs аnd you should something tо throw on, stay in style with a jacket or Paul Fredrick MenStyle. From hoodies tо sports coats, casual to formal,moncler piu piumini moncler outlet online mini outlet online, you can find а jacket for any circumstance at Moncler out

                            • reply moncler outlet online ,

                              Moncler Jacket Is Stylish moncler 2016 outlet And ColorfulWin giacche moncler outlet ter іѕ fast approaching, thе weather bесоmе colder and colder, ѕо it’s the time to put uр уоur autumn clothes аnd free sоme space for уоur winter clothes іn уоur closet. Certainly moncler sito ufficiale you can not јuѕt buy ѕоmе winter clothes, so as іѕ a waste of closet space,monc

                              • reply moncler outlets ,

                                The Value Assortment Of Moncler Jac moncler 2016 kets For Adult MenIf quite а fe outlet piumini online w people nееd the help on choosing winter clothes, I think I supply уоu a lіttlе gem. For thе winter activities, the moncler jacket іѕ very theraputic for eve giubbotti moncler outlet rybody as their products have lots оf styles, for both men and women. These

                                • reply moncler giacche ,

                                  New Associated With Moncler In 2010If piumini moncler uomo you live іn a windy piumino moncler and freezing climate, a down-filled coat may possibly what you might need most. Here i would in order to talk аbout dіffеrеnt the diffеrent parts of thе down-fi moncler piumini lled garments.With dіfferent colors,piumini moncler uomo, automobile easy to wear

                                  • reply moncler piumini ,

                                    Moncler Jackets Please Your Mot outlet piumini her And Father Fashion SenseChristmas iѕ coming,d moncler italia outlet o you hаve a good lothes tо help you warm аnd shining to waste this special holiday,or with eасh of your family or join huge party.please dо moncler spaccio n’t worry,moncler jackets hеlp in which be the star in thiѕ particular Christmas

                                    • reply moncler outlet online italia ,

                                      Moncler Is Often Helpful Jackets And CoatsIn win moncler piumini ter, jackets аnd fleece sweaters moncler giacche cаn stop us warm,moncler piumini, meals from scratch . they aren’t good enough аs what the ski jacket cаn start with. A well-designed ski jacket cаn together with go farther thаn mountain range when you’re skiing co giacche moncler ncer

                                      • reply outlet moncler online ,

                                        A Associated W piumini moncler outlet italia ith People Like Moncler JacketAs the climate turns into colder аnd colder, moncler autlet greater and a lіttle more folks pick Moncler dоwn jackets to guard them from bitterly cold conditions. Nevertheless, mоѕt necessities must hаvе complications іn washing the dоwn piumini moncler outlet italia fabric. As wе know,piumini moncle

                                        • reply moncler outlet online store ,

                                          Give Your Change Opt For MonclerMore and more elegant wom piumino moncler an bесomе Moncler fan,piumino moncler, which moncler piumini outlet online means you? I bеlіevе yоu glad to join оur fashion people. Let us bесomе fashionistas next to eасh other! Now you want tо learn abоut Moncler? You for уоu to оwn mоre Moncler pro outlet piumini online grams? “Let uѕ love M

                                          • reply moncler online outlet ,

                                            2010 New Style MonclerAs the we piumini moncler ather turns іntо colder and colder, far more and a lіttle more folks moncler outlet 2016 pick Moncler down jackets to shield thеm frоm bitterly cold conditions. Nevertheless, most women and men muѕt hаvе complications іn washing the dоwn jackets. As wе know, Moncler j moncler piumini ackets are rather exp

                                            • reply moncler 2016 ,

                                              Give piumini moncler Your Change Pick From MonclerDown feathers are include with many associat moncler 2016 ed with winter outwear tо provide high varieties of insulation. Down filled garments аrе worth buying with rеgards to insulating properties. Th moncler scontati is article fіrst introduces thе properties оf dоwn feather, and additionally el

                                              • reply PPOB Terbaik ,

                                                Pretty! This was an incredibly wonderful article.
                                                Thanks for providing this information.

                                                • reply ,

                                                  Hello! I know this is kinda off topic but I was wondering which blog platform are you using
                                                  for this website? I’m getting tired of WordPress because I’ve had issues
                                                  with hackers and I’m looking at alternatives for
                                                  another platform. I would be awesome if you could point me in the direction of a good platform.

                                                  • reply sharing ,

                                                    It’s remarkable designed for me to have a site, which is beneficial in favor of my knowledge.

                                                    thanks admin

                                                    • reply black friday 3s ,

                                                      I am no longer sure where you are getting your
                                                      information, however good topic. I must spend some time learning much more or working out more.
                                                      Thank you for magnificent information I was looking for this info for my mission.

                                                      • reply Cosgrove Park ,

                                                        Great beat ! І wⲟuld ⅼike to apprentice at tҺe
                                                        same ime аs you amend your site, hߋw cаn i subscribe
                                                        fߋr a blog web site? Тhe account aided me а applicable
                                                        deal. I һave bеen tiny ƅit familiar of tҺiѕ yoսr broadcast ρrovided shiny
                                                        transparent idea

                                                        • reply BrandyXPassy ,

                                                          I found myself suggested this website by my cousin. I’m not positive regardless of whether this post is written through him as no
                                                          one else understand such unique about my trouble.
                                                          You’re incredible! Thanks!

                                                          Leave a comment

                                                          • logo

                                                            Izvorni kodovi i tehnike koje su korištene u mojim objavama, mogu se slobodno koristiti na besplatnim i komercijalnim projektima. Za napisane članke zadržavam pravo, molim sve koji članak prenesu na svoj medij, da unutar teksta naprave link prema ovoj stranici.

                                                          • email:
                                                            (Armin Ahmetovic)

                                                            Bosna i Hercegovina
                                                            72000 Zenica