Skip to content

Instantly share code, notes, and snippets.

View wvuwebgist's full-sized avatar

wvuwebgist

View GitHub Profile
@wvuwebgist
wvuwebgist / assets.html
Last active August 29, 2015 14:08
Flexslider for CleanSlate
<!-- Stylesheet for flexslider - This goes in the <head> -->
<link href="https://code.wvu.edu/public/1438359736/vendor/flexslider/2.2.2/flexslider.css" rel="stylesheet"> <!-- Either reference the code repo, or you may copy and paste these into your stylesheets. We recommend overriding styles with new rules instead of directly editing the rules in this stylesheet. This allows for easy upgrades later. -->
<!--======================================================
The markup for Flexslider is determined by the Snippet
==========================================================-->
<!-- FlexSlider scripts - These go before the closing </body> tag -->
@wvuwebgist
wvuwebgist / _search.html
Last active August 29, 2015 14:08
Search in CleanSlate
<form class="form-search" action="//search.wvu.edu/search" method="get" role="search">
<label for="q">
<span class="form-search__label-text">Search</span>
<input id="q" class="form-search__field" name="q" maxlength="256" placeholder="Search this site..." type="search" />
</label>
<input id="as_sitesearch" name="as_sitesearch" type="hidden" value="<r:site:domain />" />
<input id="sort" name="sort" type="hidden" value="date:D:L:d1" />
<input id="output" name="output" type="hidden" value="xml_no_dtd" />
<input id="ie" name="ie" type="hidden" value="UTF-8" />
<input id="oe" name="oe" type="hidden" value="UTF-8" />
@wvuwebgist
wvuwebgist / quicklinks.rhtml
Last active September 28, 2015 19:38
Quicklinks V2 for West Virginia University
@wvuwebgist
wvuwebgist / flexslider.rhtml
Last active September 28, 2015 19:48
FlexSlider for West Virginia University (The old skool way)
<!-- Stylesheet for flexslider -->
<link rel="stylesheet" href="/themes/shared/flexslider/stylesheets/flexslider.2.1.css" /> <!-- being sure to reference the shared folder, you may copy and paste these into your stylesheets to tweak -->
<!--======================================================
Markup for Flexslider, .flexslider and .slides are required classes:
==========================================================-->
<div class="flexslider">
<ul class="slides">
</ul> <!-- close slides -->
@wvuwebgist
wvuwebgist / google_search.rhtml
Created December 26, 2011 20:54
Google Search for SlateCMS
<% # This is the template where search results will display.
# It must be called google_search.rhtml and should be placed in the same location as your index.rhtml and backpage.rhtml
# You'll likely want to copy the contents of your backpage.rhtml and paste the helper (below) in place of the main column
%>
<div id="main">
<h2>Google Search Results</h2>
<%= @search_results -%>
</div>
@wvuwebgist
wvuwebgist / jquery_slate.rhtml
Last active September 29, 2015 01:47
Attaching jQuery for Slate CMS Themes
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script>window.jQuery || document.write('<script src="/themes/shared/javascripts/jquery-1.10.2.min.js"><\/script>')</script>
@wvuwebgist
wvuwebgist / more.textile
Created February 9, 2012 19:15
Blog Article Excerpt

{{ MORE }}

@wvuwebgist
wvuwebgist / partial_include.txt
Last active October 3, 2015 18:27
Include a partial in your theme via an editable region
{{ Theme.include_partial template="/navigation" }}
@wvuwebgist
wvuwebgist / show_helper_syntax.rhtml
Created May 1, 2012 14:42
Show content before, after, or during a certain date & time
<%# Show something before May 2nd at 8:30am %>
<% show_before 'May 2, 2012 8:30 AM' do %>
<p>Your content here<p>
<% end %>
<%# Show something between May 2nd and May 3rd %>
<% show_between('May 2, 2012 8:30 AM', 'May 3, 2012 8:30 AM') do %>
<p>Your content here</p>
<% end %>
@wvuwebgist
wvuwebgist / Editable region snippet
Last active October 4, 2015 04:48
Flexslider for SlateCMS, v2
{{ Collection.gallery collection_id=5579, template="gallery" }}
comment. Change the collection id to your set id/number in Slate. template="gallery" is required in order to reference your customized _gallery.rhtml file.