my code stock.com

Your code- & snippet-collection - anywhere at any time.

» Back to my code stock.com home page «

API Reference for iframe Embeds

The standard iFrame code is really simple and you only need to set the height that you want use in your blog or website:

<iframe src="https://mycodestock.com/embed/snippet/XXXXXX?height=375" width="100%" height="375" frameborder="0" style="border:1px solid #efefef;"></iframe>

If you need a more customized version, you can use some of the following attributes to set the font-size or editor theme color:

Editor color:

theme you can use bright or dark.
Default: dark

Example:

<iframe src="https://mycodestock.com/embed/snippet/XXXXXX?height=375&amp;theme=bright" width="100%" height="375" frameborder="0" style="border:1px solid #efefef;"></iframe>

Editor font-size:

font-size you can use any numeric value as font-size e.g. 14.
Default: 12

Example:

<iframe src="https://mycodestock.com/embed/snippet/XXXXXX?height=375&amp;font-size=14" width="100%" height="375" frameborder="0" style="border:1px solid #efefef;"></iframe>

Open in a new window link:

new-window-link you can use a boolean value (true or false).
Default: true

Example:

<iframe src="https://mycodestock.com/embed/snippet/XXXXXX?height=375&amp;new-window-link=false" width="100%" height="375" frameborder="0" style="border:1px solid #efefef;"></iframe>

Show or hide branding:

branding you can use a boolean value (true or false).
Default: true

Example:

<iframe src="https://mycodestock.com/embed/snippet/XXXXXX?height=375&amp;branding=false" width="100%" height="375" frameborder="0" style="border:1px solid #efefef;"></iframe>