我无法从一个fram复制属性并创建一个类似的(见下图)。左边的图片,花,是我想要的属性。我想将它添加到右侧的图像(蓝色)。我尝试过使用谷歌浏览器编辑组件,但我无法弄清楚。
我只希望右边的图像具有与左图像相同的属性(大小和框架)。
答案 0 :(得分:0)
查看你的页面,我认为你应该做这样的事情(我正在使用jQuery)。
$(document).ready(function(){
var img = $('.attachment-shop_catalog');
var width = img.width();
var height = img.height();
//give an id or a class to identify your target img, i'm using id target-img
$('#target-img').css('width',width+'px');
$('#target-img').css('height',height+'px');
});