Skip to content

Instantly share code, notes, and snippets.

K.J Ye kjy112

Block or report user

Report or block kjy112

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View Final MailChimp Form
<!-- Begin MailChimp Signup Form -->
<link href="//cdn-images.mailchimp.com/embedcode/classic-10_7.css" rel="stylesheet" type="text/css">
<style type="text/css">
#mc_embed_signup {
background: #fff;
clear: left;
font: 14px Helvetica, Arial, sans-serif;
}
/* Add your own MailChimp form style overrides in your site stylesheet or in this style block.
We recommend moving this block and the preceding CSS link to the HEAD of your HTML file. */
View Generic MailChimp Embedded Form
<!-- Begin MailChimp Signup Form -->
<link href="//cdn-images.mailchimp.com/embedcode/classic-10_7.css" rel="stylesheet" type="text/css">
<style type="text/css">
#mc_embed_signup{background:#fff; clear:left; font:14px Helvetica,Arial,sans-serif; }
/* Add your own MailChimp form style overrides in your site stylesheet or in this style block.
We recommend moving this block and the preceding CSS link to the HEAD of your HTML file. */
</style>
<div id="mc_embed_signup">
<form action="https://kjye.us2.list-manage.com/subscribe/post?u=38dcdbcb0503681c23642ba69&amp;id=c6bd6154a9" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
View gist:e8ff355d272e10396785
<?php
/*
* Adding actual Google Analytics
*/
add_action( 'amp_post_template_footer', 'xyz_amp_add_analytics' );
function xyz_amp_add_analytics() {
?>
<amp-analytics type="googleanalytics" id="analytics1">
<script type="application/json">
@kjy112
kjy112 / gist:867a39d3aab808026d56
Created Feb 24, 2016
Add Analytics Script to Head
View gist:867a39d3aab808026d56
<?php
/*
* Adding Google Analytics AMP Head
*/
add_action('amp_post_template_head', 'xyz_amp_google_analytics_head');
function xyz_amp_google_analytics_head(){
?>
<script async custom-element="amp-analytics" src="https://cdn.ampproject.org/v0/amp-analytics-0.1.js"></script>
<?php
View gist:95963479037e01aa5946
<?php
add_action( 'amp_post_template_css', 'xyz_amp_additional_css_styles' );
function xyz_amp_additional_css_styles( $amp_template ) {
// only CSS here please...
?>
nav.amp-wp-title-bar {
padding: 12px 0;
background: #000;
}
@kjy112
kjy112 / gist:fb9278133ebe55803c46
Created Feb 24, 2016
Code for Styling AMP Header Bar and Text
View gist:fb9278133ebe55803c46
<?php
/*
* Custom CSS for AMP
*/
add_action( 'amp_post_template_css', 'xyz_amp_my_additional_css_styles' );
function xyz_amp_my_additional_css_styles( $amp_template ) {
// only CSS here please...
?>
nav.amp-wp-title-bar{
You can’t perform that action at this time.