So I was trying to get a default product video to auto play as soon as you see the listing (without even clicking on it) and I saw a similar post in here and used the javascript that was suggested, however after doing that, our website doesn’t want to load very well and the images don’t show up at all now. We have since removed the javascript but it is still doing it. What have I don’t wrong and how can I fix my website? TIA
Could you share your store URL to check?
Did you revert all files that you edited? I see all images files are incorrect now so they cannot appear.
Sorry - I have no idea what that means? How would I change all the image files now? so I saw in another forum post that this chick wanted videos to be auto enabled and a couple of people said to add this javascript into the at the theme setting and one person said to do it to the product liquid. We tried the product.liquid and it did nothing so we deleted it from there and then went up to the theme.liquid (which is where someone said to put it) and added it to the bottom of the page - again it didn’t do anything, so we deleted it there and tried it up into the product stuff (within the theme.liquid) was listed and embedded it there. After we did that, that’s when the images stopped coming up and it was constantly loading. So we then removed all the javascript, refreshed everything and its still not loading. See below for the javascript that we added - we tired both in the product.liquid but only the top one in the theme section.
document.querySelector(‘.product-media .plyr__video-wrapper video’).play();
It looks like your theme is using a script to load the images. Therefore, when having error in your script, it prevents the loading of images. You do have an error in your console (see image below). This is a tricky process to debug and I would recommend hiring a developer to do so.
Other option is to upload a new theme and get the original code of the theme.js under the Asset folder. Copy/paste that said code and replace the theme.js on your theme. NOTE: This will erase your previous code edits that you did in theme.js
Thank you, I was already in the process of changing the theme, so I will hurry up and do that now so that there are no issues. Do I have to do anything to the images in our library/gallery? or it will automatically fix that issue when changing the theme?
On a side note - do you know if it is possible to have your default product image to be a video and have it auto play as soon as that product is visible when scrolling. As an example, if you go to https://thefluidproject.com.au they have videos as there main image and it plays straight away even when you haven’t clicked on it. That is what we are wanting to do and how we got into this issue to begin with. Is this possible on a shoplift site?
sorry that was meant to say shopify site?
