Skip to content

Instantly share code, notes, and snippets.

<script src="https://f.convertkit.com/ckjs/ck.5.js"></script>
<form action="https://app.convertkit.com/forms/FORM_ID/subscriptions" method="post" data-sv-form="FORM_ID" data-uid="UID_FROM_FORM_HTML">
<ul data-element="errors"></ul>
<div data-element="fields">
<input name="fields[first_name]" type="text">
<input name="email_address">
<button data-element="submit">Subscribe</button>
</div>
</form>
<?php
// ConvertKit API Key:
$convertkitApiKey = 'your-convertkit-api-key';
// Map each of your Clickbank products to a ConvertKit tag ID, or leave this array empty to
// use the default tag for all products:
$convertkitTags = array(
'clickbankproduct1' => 'cktag1',
'clickbankproduct2' => 'cktag2',
'clickbankproduct3' => 'cktag3',
);
<style>
.message-content { max-width: 600px; }
.message-content div { padding-bottom: 10px; }
.message-content img { max-width: 100%; }
</style>
<div class="message-content">
{{ message_content }}
<br>
@nathanbarry
nathanbarry / ck_form.css
Created April 20, 2015 22:43
Top bar ConvertKit form
.ck_form_bar {
font-family: 'Helvetica Neue', Helvetica, Arial, Verdana, sans-serif;
line-height: 1.5em;
overflow: hidden;
color: #666;
font-size: 16px;
border-bottom: solid 1px #d1d1d1;
clear: both;
margin: 20px 0px;
padding: 20px;
@nathanbarry
nathanbarry / ck_form.css
Last active December 31, 2017 20:09
One line form
.ck_form.single_line {
background: #f9f9f9;
font-family: 'Helvetica Neue', Helvetica, Arial, Verdana, sans-serif;
line-height: 1.5em;
overflow: hidden;
color: #666;
font-size: 16px;
border: solid 1px #d1d1d1;
-webkit-box-shadow: none;
-moz-box-shadow: none;
@nathanbarry
nathanbarry / CSS
Created April 3, 2015 18:29
ConvertKit custom content
.book-image {
display:block;
padding-left: 150px;
background: url(http://nathanbarry.com/wp-content/themes/nathan2.0/img/authority/authority-small.jpg) no-repeat;
text-decoration: none;
color: #333;
min-height: 200px;
border-bottom: none;
}
<iframe src="https://app.convertkit.com/nathanbarry/outthink/"></iframe>
<style>
html,body {
margin: 0px;
padding: 0px;
height: 100%;
width: 100%;
}
<iframe src="url_of_your_new_page" width="300px" height="800px" style="border:none;"></iframe>