Skip to content

Instantly share code, notes, and snippets.

View crumina's full-sized avatar
🎯
Focusing

crumina

🎯
Focusing
View GitHub Profile
@crumina
crumina / Before header
Created February 27, 2015 09:41
Before header row for additional content [Onetouch2, Embrace, Atlantis]
<?php
function custom_before_header_bar()
{ ?>
<div style="background:gray; "> <!-- Full width row -->
<div class="row"><div class="large-12 small-12 columns">
<!-- Your Content Will be here -->
</div></div>
@crumina
crumina / functions.php
Created February 27, 2015 12:21
Blank page for child theme [onetouch, embrace]
/**
* Pages without top menu
* in footer.php
*
* @since 1.0.0
*/
function reactor_remove_footer() {
if (is_page_template('page-blank.php')):
@crumina
crumina / functions.php
Last active August 29, 2015 14:17
Postal code position changed
<?php
/* -------------------------------------------------------
You can add your custom functions below
-------------------------------------------------------- */
/*--------------------------------------------------------
Custom VCard Widget
--------------------------------------------------------*/
@crumina
crumina / functions.php
Last active August 29, 2015 14:18
[Onetouch] Modify post title
<?php
function cr_custom_header_titles() {
if ( is_single() ) { ?>
<h1 class="entry-title"><?php the_title(); ?></h1>
<?php if ( function_exists( 'the_ratings' ) ) {
the_ratings();
}
} else { ?>
@crumina
crumina / functions.php
Created April 13, 2015 13:26
remove meta from post
<?php
function _remove_meta_from_posts() {
remove_action('reactor_post_header', 'reactor_do_post_header_meta', 3);
}
add_action( 'init', '_remove_meta_from_posts', 1 );
@crumina
crumina / functions.php
Created April 15, 2015 07:14
[Embrace] add tabs to woocommerce
<?php
// Unhook default Crumina functions
function unhook_crumina_functions() {
remove_filter( 'woocommerce_product_tabs', 'crum_remove_product_tabs', 98 );
}
add_action( 'init', 'unhook_crumina_functions' );
@crumina
crumina / custom.js
Created April 25, 2015 08:26
Enable accordion deeplinking for Foundation 5
jQuery(document).ready(function () {
setTimeout(function() {
if (window.location.hash) {
jQuery('.accordion dd > a').each(function () {
var current = jQuery(this).parents('.accordion');
var hash = '#' + jQuery(this).attr('href').split('#')[1];
if (hash == window.location.hash) {
current.find('dd').removeClass('active');
current.find('.content').hide();
jQuery(this).parent().addClass('active');
@crumina
crumina / functions.php
Last active August 29, 2015 14:21
[Onetouch] Stunning header on page template "For Metro Visual builder"
/**
* Stunning header
* in header.php
*
* @since 1.0.0
*/
function frontpage_st_header ()
{
if (is_page_template('page-templates/fullwidth-page.php') ):
@crumina
crumina / functions.php
Created May 16, 2015 10:34
[Onetouch] Add custom shortcode after header on all pages
/**
* Custom shortcode on all pages
* in header.php
*
* @since 1.0.0
*/
function shortcode_after_header ()
{
@crumina
crumina / jquery-bootstrap-datepicker.css
Last active August 29, 2015 14:26 — forked from miwahall/jquery-bootstrap-datepicker.css
jQuery UI Datepicker Bootstrap 3 Style
.ui-datepicker {
background-color: #fff;
border: 1px solid #66AFE9;
border-radius: 4px;
box-shadow: 0 0 8px rgba(102,175,233,.6);
display: none;
margin-top: 4px;
padding: 10px;
width: 240px;
}