This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
jQuery.ajax({ | |
type: 'GET', | |
url: 'http://mysite.myshopify.com/cart.json', | |
dataType: 'jsonp', | |
success: function(data) { | |
var item_count = data['item_count']; | |
var total_price = data['total_price']/100; | |
//If there are items in cart |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="instafeed"></div> | |
<script> | |
var feed = new Instafeed({ | |
clientId: 'XXXXXXXXXXXXXXXXXX', | |
accessToken: 'abcdefghijklmnop', | |
get: 'user', | |
userId: 12345678, | |
limit: 5, | |
after: function() { | |
external(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Check the gallery field (created with ACF PRO) for images | |
$images = get_field('images'); | |
if( $images ) : | |
// If it does have images: | |
// Create variable for download file | |
// This uses a /downloads/ directory and the page title as the file name | |
$destination = 'downloads/' . sanitize_title( get_the_title() ) . '.zip'; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Template Name: Shopify Collection Demo | |
* | |
*/ | |
get_header(); ?> | |
<div id="primary" class="full-width"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div style="width: 100%; margin: 0 auto; text-align: center; background: #ffffff;"> | |
<a href="{{ shop.url }}"><img src="{{ 'logo.png' | asset_url }}" alt="{{ shop_name }}" width="WIDTH" height="HEIGHT" style="margin: 0 auto;" /></a> | |
<br/><br/> | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // Include Twitter IDs for content creator (you, usually) ?> | |
<meta name="twitter:site" content="@zoe_rooney"/> | |
<meta name="twitter:creator" content="@zoe_rooney"/> | |
<?php | |
// get current post ID | |
$currentpost = get_the_ID(); | |
// get radio value | |
$radio = get_field( 'twitter_card_options', $currentpost ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data-platform="<?php echo implode(', ', get_field('platform')); ?>" | |
data-project-type="<?php echo implode(', ', get_field('project_type')); ?>" | |
data-designer="<?php the_field('designers'); ?>" |
NewerOlder