📜  更改 img src css - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:03:44.857000             🧑  作者: Mango

代码示例1
// You cannot do it with CSS alone
// You can with JS

element.style.src = "someImage.jpg";

// Or with jQuery
$('some-element').attr('src', 'someImage.jpg');