Hello I added this code which works fine. Only issue is the element does not come back once it is instructed to only hide on one page. Once it hides it does not come back on other pages. Here is the code below. Can anyone help with this? Thanks.
$w.onReady( function () {
// Hides the element when the page loads
$w(“#box19”).hide();
});
Is this component shown on all pages? If so, once you hide it, it’s hidden.
Yep, either that or it has been added to the site tab instead of the page tab.
Yes show on all pages in on and yes I added it to the page tab and not the website tab. I just want to know how to make it appear on the rest of the pages except the page I have the code added onto
@qualitykindpromotion
If you want to hide it on certain pages then you can’t use the show on all pages toggle.
Have a read of this page to understand more.
https://support.wix.com/en/article/corvid-tutorial-hiding-an-element-on-certain-pages
Line 5 calls the hide u[/u] function, which sets the element’s hidden property to true. This means the element will not be displayed on this page even if the element is set to “Show on all pages”.
That page will also tell you about using collapse instead of hide sometimes too, so that you don’t end up leaving a gap where the element is still on your page whilst being hidden from view.
Unfortunately you will have to copy and paste it onto all your other pages and then simply add the hide code to that page that you want it to be hidden on.
If you click on the box and do your keyboard copy command instead of using your mouse and right clicking the box to copy, then it will be much quicker.
As you can then simply go to all other pages and just use your keyboard paste command and it will be pasted in place for you and it should be in the same position as the original box that you copied.
https://support.wix.com/en/article/copying-and-pasting-an-element
Also, have a read of the show on all pages support page from Wix.
https://support.wix.com/en/article/showing-an-element-on-all-pages-6533570
Especially the notes section at the end as it tells you about using show on all pages in your mobile view and how any element with that toggled on will be put in either your header or footer depending on it’s location to them, basically the closest one that the element is to will be the one where it goes.
thanks so much for your help guys
Hi I’m having the same issue so i have few elements on my booking page which I want hidden so I uses the hide and collapse function which hid the the elements however when I go back to my home page or any other page the elements are hidden there as welI until I click reload the elements show up on the other pages would I have to copy and paste everything or is there another way around this issue and the show on all button is on