Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
Ground control to Major Tsong...

Jon Cuevas archondigital

💭
Ground control to Major Tsong...
View GitHub Profile
@archondigital
archondigital / sticky-top-bar.html
Last active Nov 7, 2016
Sticky top bar on Foundation 6
View sticky-top-bar.html
<div id="siteContainer">
<div id="siteNavStickyContainer" data-sticky-container>
<div id="siteNavStickyWrap" class="sticky" data-sticky data-sticky-on="small" data-anchor="siteContainer" data-margin-top="0">
<div id="siteNavToggler" class="title-bar" data-responsive-toggle="siteNav" data-hide-for="medium">
<!-- // your title-bar / toggler code -->
</div>
<div id="siteNav" class="top-bar">
<!-- // your top-bar code -->
</div>
</div>
@archondigital
archondigital / custom-rules.json
Last active Nov 3, 2016
Custom transformer rules for FB Instant Articles plugin on WordPress
View custom-rules.json
{ "rules" :
[
{ "class": "PassThroughRule", "selector" : "ins.adsbygoogle" },
{ "class": "PassThroughRule", "selector" : "div.alignright" },
{ "class": "PassThroughRule", "selector" : "div.alignleft" },
{ "class": "PassThroughRule", "selector" : "div.callout" },
{ "class": "PassThroughRule", "selector" : "div.row" },
{ "class": "PassThroughRule", "selector" : "div.columns" },
@archondigital
archondigital / clearing-lightbox-hash.html
Created Oct 19, 2015
Load Clearing Lightbox using URI hash on Foundation 5
View clearing-lightbox-hash.html
<div id="loadGallery"></div>
<script>
// load clearing lightbox with URI hash , requires Foundation 5
$(function(){
if (window.location.hash){
var hash = window.location.hash.substring(1);
if (hash == "loadGallery"){
$('ul[data-clearing] li a').first().click();
}
@archondigital
archondigital / adsense-conditional.html
Last active Oct 18, 2015
Conditional for disabling Adsense code when running Jekyll on localhost
View adsense-conditional.html
{% if site.enable_adsense == true %}
<!-- Adsense Code here -->
{% else %}
<!-- Placeholder Ad here -->
{% endif %}
@archondigital
archondigital / disqus-conditional.html
Last active Oct 18, 2015
Conditional for loading test Disqus account when running Jekyll on localhost
View disqus-conditional.html
<div id="disqus_thread"></div>
<script type="text/javascript">
/* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */
var disqus_shortname = '{% if site.enable_disqus == true %}username{% else %}testing{% endif %}'; // required: replace example with your forum shortname
/* * * DON'T EDIT BELOW THIS LINE * * */
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
@archondigital
archondigital / custom-taxonomy-loop
Created Jul 27, 2014
WordPress custom taxonomy query and loop
View custom-taxonomy-loop
<!-- banner full width home -->
<div id="banner" class="banner-main">
<ul data-orbit data-options="animation:slide;timer_speed:6000;animation_speed:400;stack_on_small:false;navigation_arrows:true;slide_number:false;pause_on_hover:true;resume_on_mouseout:false;bullets:false;timer:true;variable_height:false;">
<?php $args = array( 'banner-location' => 'banner-main-home', 'post_type' => 'govph_banners', 'posts_per_page' => 4, 'orderby' => 'date', 'order' => 'DESC' );
$loop = new WP_Query( $args );
while ( $loop->have_posts() ) : $loop->the_post(); ?>
<li>