获取图片的src 2017-09-27 本文已影响0人 低调的内双 如果直接用elements.src获取,是绝对路径,很蛋疼。 应该用elements.getAttribute("src")获取的才是我们用的相对路径。