Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ================ Wrap img in content HTML5 tags ================
- var imgContent = $('.page__body.textblock a.popup-video img');
- imgContent.each(function() {
- $this = $(this);
- var imgTitle = $this.attr('title');
- if (imgTitle) {
- $this.parent('.popup-video').wrap('<figure class="content-image"></figure>');
- $this.parent('.popup-video').append('<figcaption class="content-image__title">' + imgTitle + '</figcaption>');
- }
- });
Add Comment
Please, Sign In to add comment