How to Create a Sticky Header | Velo by Wix

Поделиться
HTML-код
  • Опубликовано: 3 янв 2021
  • For a fully detailed API reference, articles, examples and more videos, visit:
    www.wix.com/velo?...
    Watch how to create a sticky header that changes as visitors scroll through your site. We’ll do this by using strip elements to create 2 headers and the point on the page where they switch, as well as a few lines of code to add functionality.
    About Velo by Wix:
    Velo by Wix is an open development platform that lets you build advanced web applications. With serverless computing and hassle-free coding, you can manage all your content from integrated databases, add your own code in the built-in IDE or work in your own environment, and connect to 100s of APIs. Plus, you get total design freedom from the Wix Editor and optimized business applications-all in one integrated platform. Build, manage, deploy and scale your next web project with Velo by Wix.
    Velo by Wix-Accelerated Development of Web Applications
    www.wix.com/
    / wix
    / wix
    / wixcom
    / wix
    en.wikipedia.org/wiki/Wix.com
  • ХоббиХобби

Комментарии • 114

  • @citra124499
    @citra124499 Год назад +12

    This is insanely complicated for what should be a basic feature. LOTS of websites have this, it's very common.

  • @5PGroup101
    @5PGroup101 2 года назад +6

    Pls Add the same CODE we learned here, in the description box

  • @strenghtizeful
    @strenghtizeful 3 года назад

    Thank you, this was exactly as i wanted!

    • @Wix
      @Wix  3 года назад

      We're glad we were spot on 😉

  • @akhilsampath
    @akhilsampath 2 года назад +1

    Loved the video. It worked perfectly fine after two to three trials. The only point we must ensure is to attach both strips to the header for the code to function properly.

    • @devenjain7116
      @devenjain7116 11 месяцев назад

      not working

    • @devenjain7116
      @devenjain7116 11 месяцев назад

      okay working now

    • @Adiism
      @Adiism 3 месяца назад

      Where we have to put 'transition strip'...? In header or in the section below...?

  • @miket1638
    @miket1638 3 года назад

    You are the man!

  • @manoncostard1479
    @manoncostard1479 2 года назад +1

    Hi, thank you for the video, it works great. The only issue I am having is when a user hits refresh on its browser after having scrolled down on the page. The website page reloads and opens directly halfway down the page where the user previously was. When that happens, the code does not work and the strip showing in the header is not the scrolling strip. Any way to fix that?

    • @Wix
      @Wix  2 года назад

      Hi there Manon, thank you for reaching out, we would recommend reaching out to our customer care team at wix.com/contact. They will be able to access your site and take a closer look at this for you.

  • @guille157
    @guille157 3 года назад +32

    If Wix is a tool for people who do not code, why wouldn't you add the code in the description to help people avoid mistakes?

    • @Wix
      @Wix  3 года назад +1

      Hi Gigi, Wix provides you with everything you need to create a professional website, whether you have experience in coding, or not. If you do know a little bit of coding, Velo by Wix allows you to rapidly build, manage and deploy professional web apps, among many other capabilities. lo f you'd like to give it a try or need some guidance, feel free to get in touch with our customer care department, they'll be happy to assist you with any questions you have. support.wix.com/en/article/contacting-wix-customer-care-for-support

    • @GraceXIEgx
      @GraceXIEgx 3 года назад +17

      @@Wix Come on.

  • @mejie6792
    @mejie6792 2 года назад +4

    At 1:53 the "Show in all Pages" toggle doesn't appear on the right click and the Site tab in the Code panel is not there. It really sucks because Wix keeps changing the interface so this type of tutorial is not helping over time. It's really inconvenient!

    • @Wix
      @Wix  2 года назад

      Hi there, we're sorry to hear you are having a hard time, and our customer care team would be happy to help walk you through anything you need. You may reach our team anytime at wix.com/contact.

  • @simranjain123
    @simranjain123 2 года назад

    Hi..I have a question. Do we have to publish to see the changes or we can view it on test site as well?

    • @Wix
      @Wix  2 года назад

      You can use a get feedback link if you are not ready to publish, please see here: wix.to/DdSplwo

  • @brendonenders6882
    @brendonenders6882 3 года назад +1

    How do you use one picture as the background for both the header and the first "page" or "section"?
    I started a site with ADI and moved to editor... Does that create some issues with using this method?

    • @Wix
      @Wix  3 года назад

      Hi Brendon, if you need help with editing your site, please get in touch with our customer care, they will be happy to provide you with additional information >> support.wix.com/en/article/contacting-wix-customer-care-for-support

    • @HmzAsiri
      @HmzAsiri Год назад

      Same here, got any help?

  • @Abysse20
    @Abysse20 3 года назад +4

    Thanks for the tutorial. Looks really cool. I couldn't bring it to work for me however. When draging the second strip into the header, it automatically wants to attach to the first strip already in the Header and not in the header itself. I coulnd't bring both strips to be attached in the header. Did someone have the same issue ? Is there any other way to do it than to drag ?

    • @Wix
      @Wix  3 года назад

      Hi there, thank you for the feedback. We would recommend getting in touch with our Velo team in customer care, they will be happy to take a closer look at this for you >> support.wix.com/en/article/contacting-wix-customer-care-for-support.

    • @danielrothmund4764
      @danielrothmund4764 3 года назад

      same problem here. I think wix isnt able to show how this is done correctly

    • @Abysse20
      @Abysse20 3 года назад +2

      ​@@danielrothmund4764 The trick I finally found to make it work was to make the header big enough to add both strips in it (one below the other) and then to select the one below and place it at the top using the up arrow key. You can then make the header its normal size again. A bit of a hassle but it worked for me.

    • @gusmac6634
      @gusmac6634 3 года назад

      @@Abysse20 Hi I see what you did, I tried the same but left with a little bit sticking out the bottom. Seems when attaching the strip to the header you have to watch it doesn't say connect to strip. can you only see the result in published? for me it didn't do anything

    • @lovemesomevols
      @lovemesomevols 8 месяцев назад

      dude you're a genius@@Abysse20

  • @janicelearmond-criqui6233
    @janicelearmond-criqui6233 Год назад

    I find that you see the Header and the two strips when you go to the mobile view. How do I fix it so that you only see the header?
    I notice that the WIX used in the video is an older version to the current WIX. The code works well when in desktop mode.

    • @Wix
      @Wix  Год назад

      Hi Janice, you can hide elements in the mobile view > wix.to/pkYUWZD
      For any assistance, please contact our team at wix.com/contact.

  • @climongi222
    @climongi222 6 месяцев назад

    Hi, thank you for this tutorial. It works perfectly on desktop. However, it does not work on mobile, because the transition strip (set to "Show on All Pages") gets placed within the header in the mobile version. Any solution for that? Thanks!

    • @Wix
      @Wix  6 месяцев назад

      Hey, this seems like an issue that our technical team should look into. Please submit a support request and include a detailed description of the issue, any screenshots to illustrate the issue, and a description of any steps you already tried to resolve the issue. This way, our team will have a clear understanding of the issue. You can reach them by visiting here >> wix.click/3J3Gj5l.

  • @johnfrank1918
    @johnfrank1918 3 года назад +1

    Is it a possibility to have a sticky header on the mobile version of your website?

    • @Wix
      @Wix  3 года назад

      Hi John, this should be possible with Velo. If you need help with setting up the sticky menu on your mobile, please get in touch with our customer care through our contact page, our team will be happy to assist further >> support.wix.com/en/article/contacting-wix-customer-care-for-support

  • @atharvakhodke5658
    @atharvakhodke5658 Год назад

    hey can you help me showing how to add multi level menu in wix, like a folder menu inside another folder menu in main menu

    • @Wix
      @Wix  Год назад

      Hi there, thank you for reaching out, you can find the steps to a mega menu here > www.wix.com/velo/example/mega-menu

  • @Peteristrate
    @Peteristrate 3 года назад

    Cool, but I think it's time to push Editor X more now, which is far superior to this outdated classic editor.
    I understand that this is more or a Velo related video, though :)

    • @HitarthSheth
      @HitarthSheth 3 года назад

      EditorX is still buggy (as it's in beta) but agree, they need to push it more.

  • @user-cp4xh9sr3v
    @user-cp4xh9sr3v 2 года назад

    Is it possible to make sticky menu In a different background color without using header strip? Because my site is in 2 languages with one from right to left and the other from left to right. So I moved the header up and created unreal menus.I would be very happy if you answer me soon. it urgent :(

    • @Wix
      @Wix  2 года назад

      Hi there, hank you for your interest, we would recommend checking out our Velo forum for similar requests, or submitting your own. You can find our forum here: www.wix.com/velo/forum. You may also contact our customer care team at wix.com/contact and they will be happy to look into the available options for you.

  • @jacobovaidov9675
    @jacobovaidov9675 Год назад

    Thank you for the video!, but what do i do if i want the defaultHeaderStrip text to be WHITE and leave the scrollingHeaderStrip with BLACK text?

    • @Wix
      @Wix  Год назад

      Hi Jason, we'd recommend contacting our customer care team with your request for assistance. You can reach our team at anytime at bit.ly/2S0NEJY they will be happy to assist you with this.

  • @danielemelillimancinetti7158
    @danielemelillimancinetti7158 Год назад

    Sorry but this might sound like t a stupid question, but how do you get the header to be transparent over the first section of the site?

    • @Wix
      @Wix  Год назад

      Hi Daniele, thank you for reaching out, you can do this from the settings, there is an option for opacity. You can find the steps here: wix.to/CWO0709 and if you need any assistance, you can always reach us at wix.com/contact.

  • @rewafrancisca
    @rewafrancisca 3 года назад +2

    Can you put the code in the description so people can copy it? :)

    • @Wix
      @Wix  3 года назад

      Thank you for the suggestion, Ja. In the meantime, we recommend visiting our Velo forum for additional tutorials and examples of code that you can implement on your site >> www.wix.com/velo/forum

  • @brendaameri
    @brendaameri 2 года назад

    I put in the code exactly as this one but if I start to scroll even a little past the main menu that's fixed (not the scrolling one), it won't allow me to click on it at all until I get past the transition point for the scrolling header to pop up. What can I do to fix this?

    • @Wix
      @Wix  2 года назад

      Hi Brenda, thank you for the feedback. We suggest reaching out to our customer care regarding this issue, they'll be happy to take a closer look >> support.wix.com/en/article/contacting-wix-customer-care-for-support.

    • @user-gb9wx6qc9g
      @user-gb9wx6qc9g 2 года назад

      Did you find out how to fix it?

  • @matthewmoore523
    @matthewmoore523 3 года назад

    what about viewing on mobile? I dont want both strips to show on mobile viewing of my website

    • @Wix
      @Wix  3 года назад +1

      Hi Matthew, if you need help with setting up a sticky header on your mobile site, please get in touch with our customer care department >> support.wix.com/en/article/contacting-wix-customer-care-for-support, they'll be happy to provide you with additional intructions.

  • @palakondarayuduuppu6420
    @palakondarayuduuppu6420 2 года назад

    are there tutorials for wix code?

    • @Wix
      @Wix  2 года назад

      Hi there, thank you for reaching out, we do have a list of tutorials in our help center. You can use our link to access them >> bit.ly/2YiH1s9
      You can also check out our Velo Forum for tutorials, assistance and more. >> www.wix.com/velo/forum

  • @MAHRYSKAINMOTION
    @MAHRYSKAINMOTION 2 года назад

    this is great but it only works on my homepage. it doesn't work properly on other pages. i put the code on the masterpage but the codes are giving me errors on other pages. any suggestions?

    • @Wix
      @Wix  2 года назад

      Hi there, thank you for reaching out, we would recommend posting your question in our Velo Forum here: www.wix.com/velo/forum
      You can also reach out to our customer care team through our contact link here: bit.ly/2S0NEJY

  • @garyyang2776
    @garyyang2776 Год назад

    My scrolling down menu only has the background, all the logo and menubar are gone, I check the code, the function are work, could you tell me how I can specify this issue, thanks

    • @Wix
      @Wix  Год назад

      Hi Gary, we recommend contacting our customer care team to take a look at your settings. You can visit our team here: bit.ly/2S0NEJY
      You can also check out our Velo Forum at www.wix.com/velo/forum

  • @KinkyLettuce
    @KinkyLettuce Год назад

    Ok so do the two strips belong to the header?
    because now the property "hide" doesnt exist in either header or footer

    • @KinkyLettuce
      @KinkyLettuce Год назад

      please, a proper response instead of another copy&paste...

    • @Wix
      @Wix  Год назад

      Yes, both strips go in the header and the third one is outside but still set to show on all pages. The full instructions can also be found here > www.wix.com/velo/example/sticky-header
      If you find you are missing a step or need any additional help, please contact our customer care team here: bit.ly/2S0NEJY

    • @KinkyLettuce
      @KinkyLettuce Год назад

      @@Wix appreciate it

  • @jillianjaszewski6448
    @jillianjaszewski6448 2 года назад

    what to do if you're on a mac? when I ctrl click none of those options pop up?

    • @Wix
      @Wix  2 года назад

      Hi Jillian, have you tried clicking Command instead? You can also find written instructions here: bit.ly/3x0G86L.

  • @askermarkussen3230
    @askermarkussen3230 3 года назад

    my "scrollingHeaderStrip" only shows up when I scroll up. So if I scroll down on the page it does not appear, only when i start to scroll up

    • @Wix
      @Wix  3 года назад

      Hi Asker, if you need help with your editor, please get in touch with our customer care department through our contact page >> support.wix.com/en/article/contacting-wix-customer-care-for-support. Our Velo team will be more than happy to take a look at this for you.

  • @danielrothmund4764
    @danielrothmund4764 3 года назад +1

    why is the code not in the description. I personally think that this isnt that userfriendly

    • @Wix
      @Wix  3 года назад

      Hi Daniel, thank you for the feedback. For a fully detailed API reference, articles, examples and more videos you can visit this link >> www.wix.com/velo?

  • @ella-cyndyb-johnson4105
    @ella-cyndyb-johnson4105 2 года назад

    My velo code doesn't work for some reason. When I try to implement a function or use an if-statement or an arrow function, nothing happens. I'm quite certain my syntax is correct but no matter what I do I can't get these simple features to work. Can someone please help? I've been searching all night and it seems no one else has run into this problem.

    • @Wix
      @Wix  2 года назад

      Hi there, thank you for reaching out, we would recommend checking out our Velo forum at wix.com/velo/forum or contacting our customer care team at wix.com/contact for assistance.

  • @gusmac6634
    @gusmac6634 3 года назад +2

    love the video thank you. would be nice if you had the code needed in the description. Also...I'm getting an "expected 1 argument but got 2" error. with
    $w("#DefaultHeading").show(); part

    • @Wix
      @Wix  3 года назад

      Hi Gus, if you need help with setting up your sticky header, please get in touch with our Velo customer care team through our contact page, they'll be happy to provide you with further assistance >> support.wix.com/en/article/contacting-wix-customer-care-for-support

  • @piotrkot4137
    @piotrkot4137 3 года назад +1

    It drives me nuts, how to attach both menus to the header? Only the first one attaches to it, the second one attaches to the first one.

    • @Wix
      @Wix  3 года назад

      Hi Piotr, if you need help with attaching the menu to the header, please get in touch with our customer care department, they'll be happy to provide you with additional instructions. You can get in touch with our team through the contact page >> support.wix.com/en/article/contacting-wix-customer-care-for-support.

    • @danielrothmund4764
      @danielrothmund4764 3 года назад

      same problem here Piotr

  • @user-hr7zn8we3w
    @user-hr7zn8we3w 7 месяцев назад

    My scrolling header do not show to the right point where I added my transition strip.

    • @Wix
      @Wix  7 месяцев назад

      Elle, our customer care team would be happy to look into this for you if you'd like to reach out to them here at wix.com/contact

  • @omarkhaled3706
    @omarkhaled3706 3 года назад

    I can't find the Site code toggle please help

    • @Wix
      @Wix  3 года назад

      Hi Omar, sounds like you might benefit out of speaking with our Velo team from customer care. Please get in touch with them through our contact page >> support.wix.com/en/article/contacting-wix-customer-care-for-support they will be happy to assist.

  • @riseacademy4461
    @riseacademy4461 Год назад

    Why this code is not working for me?

    • @Wix
      @Wix  Год назад

      Hello, we'd recommend checking out our Velo Forum for solutions or submitting your own post at wix.com/velo/forum. You can also contact our customer care team at wix.com/contact for assistance.

  • @koaleee
    @koaleee 7 месяцев назад

    I just can't make it to work 😫😭 The code just doesn't seem to run. I spent a whole day trying this, renaming the strips to even the same ID as you guys did in the video so that for some reason it would work better but nothing……… With normal HTML/CSS this basic functionality would be long done! Really desperate over here, please help!!

    • @Wix
      @Wix  7 месяцев назад

      Hi there. Our Velo team would be happy to look into this for you if you'd like to reach out at wix.com/contact. Thank you.

    • @koaleee
      @koaleee 6 месяцев назад

      Sadly even the support wasn't able to help me... However, for some unknown reason this suddenly just started working 🙌
      Is there any way to achieve this also on the mobile view? The burger menu / close menu element can only be used once in the header, so I'm unable to duplicate it on a scrolling header.

  • @chinarclub9216
    @chinarclub9216 Год назад

    its not showing in 2022 version wix

    • @Wix
      @Wix  Год назад

      Hi Chinar, thank you for reaching out, you can find the link with the steps here: www.wix.com/velo/example/sticky-header. We would also recommend using our Forum for assistance: wix.com/velo/forum

  • @mjdubarr
    @mjdubarr 3 года назад +1

    not working

    • @Wix
      @Wix  3 года назад

      Hi MJ, if you're running into trouble with creating a sticky header, please get in touch with our Velo team through customer care, they'll be happy to assist you further >> support.wix.com/en/article/contacting-wix-customer-care-for-support.

  • @Broockle
    @Broockle 9 месяцев назад

    What do you mean rightclick to open a menu? What do you mean there's a settings button for panels? What do you mean Dev Mode?
    I can't do any of that. de hek

    • @Wix
      @Wix  9 месяцев назад

      Hello. If you have any queries on any of these steps, feel free to reach out to our dedicated support team for assistance here >> bit.ly/3baYZ3L

    • @Broockle
      @Broockle 9 месяцев назад

      @@Wix well that doesn't help at all...
      I did find the Dev mode. But those cog symbol settings menus are still no where to be seen. Any ideas?

  • @gerbertela2
    @gerbertela2 Год назад

    I don't understand this at all. How the heck do you add a header? I'm working on a website that doesn't have one, and I can't "Add Header"

    • @Wix
      @Wix  Год назад

      Hi, you can see how to add or remove a header here > support.wix.com/en/article/wix-editor-adding-or-removing-the-header-and-footer-on-your-mobile-site
      If you need help, please reach out to our team at wix.com/contact

  • @spitfiredarts
    @spitfiredarts 7 месяцев назад

    Code is the same, steps are the same, The main header is hiding but the second is not appearing

    • @Wix
      @Wix  7 месяцев назад

      Hi there, we're sorry to hear you ran into trouble with creating a sticky header. Feel free to get in touch with our customer care department, they will be more than happy to go over the steps with you, and make sure you implement it correctly >> support.wix.com/en/article/contacting-wix-customer-care-for-support. Thank you.

  • @tomyrisstudios29
    @tomyrisstudios29 3 года назад +1

    For those who don't have Wix code knowledge, why isn't there an editor setting to change the color of the child objects inside when the header background is highlighted? I'm postponing the release date of my site for days just because of this mistake.
    This policy you are following is very stupid. If you're catering to an audience, you should have everything that audience needs!

    • @Wix
      @Wix  3 года назад

      Hello Tomyris, thank you for bringing this to our attention. Our velo team will be more than happy to provide you with further assistance. Kindly reach out to them through our contact page >> support.wix.com/en/article/contacting-wix-customer-care-for-support, they will be happy to further assist.

    • @tomyrisstudios29
      @tomyrisstudios29 3 года назад

      @@Wix Bullshit. They are not helping me. The only answer they gave me is from here "Own Velo" and write code.
      I am a desktop software developer. If I wanted to write code for the web, I would be a web developer. Also, I don't have time to learn the tutorial. I have very little time.

    • @orkneyrose
      @orkneyrose 2 года назад

      @@tomyrisstudios29 there’s a channel called wix fix. He does it and you can just copy the code he uses. It was a lot easier to understand. Hope this helps

    • @beefknuckles
      @beefknuckles 2 года назад

      @@tomyrisstudios29 Use default templates and non-Velo solutions or learn to code. Really simple solution. Your comment was very nasty for no reason. Stop being lazy.

  • @vladian101
    @vladian101 2 года назад

    Lost me at 'Code' :(

  • @rKingSalami
    @rKingSalami 3 года назад +3

    This is one of the worse video tutorials. Who was this intended for? People, who already know how to code?

    • @Wix
      @Wix  3 года назад

      Hi Robert, we're sorry you feel this way and appreciate the feedback. If there's anything specific you feel that is missing, please let us know through our contact page >> support.wix.com/en/article/contacting-wix-customer-care-for-support.

  • @guifjfhik9811
    @guifjfhik9811 3 года назад

    Greate Video! Is it possible to fade the header instead of just hide? Something like $w("#name").fade();?

    • @Wix
      @Wix  2 года назад

      Hi Guif, our Velo team will be happy to provide you with further instructions on how to achieve this result. Please get in touch with them through our contact page >> support.wix.com/en/article/contacting-wix-customer-care-for-support.

    • @guifjfhik9811
      @guifjfhik9811 2 года назад

      @@Wix found it already. Just call $w("#name").hide("fade");

  • @emilybaldwn4168
    @emilybaldwn4168 2 года назад

    Hello! I tried this exact code however its not working for mine. I get the error "Running the code for the site. To debug this code in your browser's dev tools, open masterPage.js.
    Error" please help!

    • @Wix
      @Wix  2 года назад

      Hi Emily, please contact our customer care team at wix.com/contact for assistance or check out our forum at wix.com/velo/forum.

  • @EilandSair
    @EilandSair 3 года назад +2

    Looking for the code? www.wix.com/velo/examples?category=interactions&search=sticky+header
    You're welcome