특정 URL로 시작하는 모든 iframe을 편집 할 수있는 방법이 있습니까? 예를 들어, 그것은 마진을 추가하는 possibile되는 모든 iframe을의 CSS는 0 자동을특정 URL로 시작하는 모든 iframe 편집
https://w.soundcloud.com/player
로 시작하는 URL이 페이지에 ??
특정 URL로 시작하는 모든 iframe을 편집 할 수있는 방법이 있습니까? 예를 들어, 그것은 마진을 추가하는 possibile되는 모든 iframe을의 CSS는 0 자동을특정 URL로 시작하는 모든 iframe 편집
https://w.soundcloud.com/player
로 시작하는 URL이 페이지에 ??
당신이 당신의 태그에 jQuery를 언급 한대로 예, 당신이 할 수있는이 같은 attribute equals selector 사용하는 것을 :
$('iframe[src^="https://w.soundcloud.com/player"]').css('margin', '0 auto');
그리고 순수 CSS로하면이 http://jsfiddle.net/obsffsfa/
iframe[src^="https://w.soundcloud.com/player"]{
margin: 0 auto;
display: block;
}
같은 것