Announcements

Help Wizard

Step 1

NEXT STEP

Embed code generated contains errors

Embed code generated contains errors

Creating an embedable iframe generates wrong code:

<iframe 
style="border-radius:12px" 
src="https://open.spotify.com/embed/playlist/37i9dQZF1DXcBWIGoYBM5M?utm_source=generator"
 width="100%" height="352" frameBorder="0" allowfullscreen="" 
allow="autoplay; clipboard-write; encrypted-media; fullscreen; 
picture-in-picture" loading="lazy"></iframe>

According to standards the width attribute is a unitless value in pixels. 100% is wrong. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#width

Reply
1 Reply

"you can provide height and width in % to iframe. Although there is a catch to it." - https://stackoverflow.com/a/24301807/7111585

XimzendSpotify Star
Help others find this answer and click "Accept as Solution".
If you appreciate my answer, maybe give me a Like.
Note: I'm not a Spotify employee.

Suggested posts

Let's introduce ourselves!

Hey there you,   Yeah, you! 😁   Welcome - we're glad you joined the Spotify Community!   While you here, let's have a fun game and get…

ModeratorStaff / Moderator/ 4 years ago  in Social & Random