Thèmes Shopify, Liquid, logos et autres sujets similaires
Hello,
I have been trying to add alt attribute to img tag generated by Magnific popup tool. But I don't manage to make it work.
Currently, I choosed vintage "minimal" theme : In file theme.js, a piece of Magnific popup code doesn't work : getImage function doesn't render alt attribute.
: function (c, d) {...}, following code is written by no alt :
,c.el&&c.el.find("img").length&&(j.alt=c.el.find("img").attr("alt"))
--> no alt anyway <img src=".//cdn.shopify.com/s/files/1/0111/3663/..........">
Test 1 : I tried to add
j.alt="MyAlt", --> working <img alt="MyAlt"....>
Test 2 : I tried to add
j.alt=c.el --> alt="[object Object]"
Test 3 : I tried to add
j.alt=c.el.find("img") --> alt="[object Object]"
Test 4 :
j.alt=c.el.find("img").attr("alt") --> alt="undefined"
Test 5 :
j.alt=c.el.find("img").attr("src") --> alt="undefined"
Test 6 :
j.alt=c.src --> alt="//cdn.shopify.com/s/files/1/0111/3663/0884/products/etuiprotectionkobo-35.jpg?v=1668278998"
More details here
Thanks for you help
Utilisateur | CLASSEMENT |
---|---|
3 | |
2 | |
2 | |
2 | |
2 |
La création d'une entreprise peut s'avérer difficile. Il y a beaucoup de choses à mettre e...
By Océanne Nov 29, 2023Le Black Friday Cyber Monday (BFCM), ou Vendredi Fou et Cyber Lundi, 2023 se profile à l'h...
By Océanne Oct 18, 2023Cet article de blog est un récapitulatif du webinaire Se préparer à BFCM : Comment lanc...
By Jacqui Oct 11, 2023