Change translation of uploaded file text on cart

For new installs, file uploads that contain an image will automatically show a thumbnail of the image on the cart page. Send us a support email if you want us to upgrade your store to show thumbnails on the cart.

To show text instead of the thumbnail image add the code below on the theme.liquid page after the <head> tag.

Replace “file upload name” with the text you want to appear.

<script>
window.addEventListener('load', function (event) {
document.getElementsByClassName('bcpo-cart-file')[0].innerHTML = 'file upload name';
});
</script>
Make sure to leave ‘ on each side of the name.

The code should look like the image below but different themes may have the <head> tag lower on the page. Just make sure to add the code after the <head> tag.

Was this article helpful?
Dislike 3

Pin It on Pinterest