Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

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

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

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

Visit your global Editor Settings.

HTML

              
                <head>

  <!-- This is the InPlayer Script. This makes the paywall work. -->
  <script type="text/javascript" src="https://assets.inplayer.com/paywall/v3/paywall.min.js"></script>

  <!-- These are the card's visual settings. They affect how the card looks like. -->
  <style media="screen">
    .card img {
      width: 100%;
      max-width: 600px;
      /* This controls the size of the card. */
      margin: 0 auto;
      cursor: pointer;
      transition: all .2s ease-out;
      box-shadow: 0 14px 20px -20px rgba(0, 0, 0, .76);
      /* This controls the shadow effect of the card. */
    }

    .card img:hover {
      transform: translateY(-4px);
    }
  </style>

</head>

<body>

  <!-- 
Below, you will need to make the following changes:
1. Change the image URL (https://page.inplayer.com/beatles.jpg) with the URL to your own image (one instance). 
2. Change the current Asset ID (72681) with the ID of your own asset (three instances).
3. Change the current Account UUID (c424a964-2c3f-47fc-b10e-b808efbde9e2) with your own Account UUID (one instance).
-->

  <div class="card">
    <img src="https://page.inplayer.com/beatles.jpg" alt="" id="asset">
  </div>
  <div id="inplayer-72681"></div>

  <script type="text/javascript">
    var paywall = new InplayerPaywall('c424a964-2c3f-47fc-b10e-b808efbde9e2',
      [{
        id: 72681,
        options: {
          noPreview: true
        }
      }]
    )
    document.getElementById('asset').addEventListener("click", () => {
      paywall.showPaywall({
        asset: {
          assetId: 72681
        }
      })
    });
    paywall.on('inject', () => {
      document.getElementById('asset').style.display = "none";
    });
    paywall.on('logout', () => {
      document.getElementById('asset').style.display = "inline-block";
    });
  </script>

</body>
              
            
!

CSS

              
                
              
            
!

JS

              
                
              
            
!
999px

Console