Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource


Babel is required to process package imports. If you need a different preprocessor remove all packages first.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.


              <!-- Create a new TinyMCE-enabled textarea -->
    <textarea rows="12" class="tinymce"></textarea>

    <!-- A Modal with our pictures laid out -->
    <div class="modal fade" id="filePicker" tabindex="-1" role="dialog" aria-labelledby="lblFilePicker" aria-hidden="true">
        <div class="modal-dialog" role="document">
            <div class="modal-content">

                <!-- Modal Heading amd Close Button -->
                <div class="modal-header">
                    <h5 class="modal-title" id="lblFilePicker">Please Select an Image</h5>
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                        <span aria-hidden="true">&times;</span>

                <!-- Modal Content - Your images will go here. This is also a good place to include an upload form. -->
                <div class="modal-body fileSelection">
                    <img src="" />
                    <img src="" />
                    <img src="" />
            </div> <!-- /end of modal-content -->
        </div>  <!-- /end of modal-dialog -->
    </div> <!-- /end of modal -->


              .fileSelection img{
  width: 100%;


              // A variable used to track the active textarea, in case multiple textareas are included on the same page.
        // - this will store the textarea the image must be included in.
        var activeTextArea = null;

        // Initialize a new TinyMCE textarea
            selector: ".tinymce",  // change this to target the appropriate HTML control on your page
            setup: function (editor) { // on the setup of the TinyMCE plugin, add a button with the alias 'addImage'
                editor.addButton('addImage', {
                    text: 'Add Image', // the text to display alongside the button
                    icon: 'image', // the icon to display alongside the button
                    onclick: function () {
                        activeTextArea = editor; // onclick of this button, set the active textarea to that of which the button was pressed
                        $('#filePicker').modal('show'); // show the file picker modal
            //include buttons on the toolbar of our TinyMCE textarea, notice our new aliased button 'addImage' is included
            toolbar1: 'undo redo | insert | styleselect | bold italic | alignleft aligncenter alignright alignjustify | addImage'

        // when an image is selected, insert the image into the active textarea and then close the modal
        $(function () {
            $(".fileSelection img").click(function (e) {
                activeTextArea.insertContent('&nbsp; <img src="' + $(this).attr("src") + '" /> &nbsp;');