Skip to content

Instantly share code, notes, and snippets.

View woogist's full-sized avatar

WooCommerce.com Documentation woogist

View GitHub Profile
@woogist
woogist / functions.php
Created July 23, 2014 00:53
canvas functions.php as example
<?php
/*-----------------------------------------------------------------------------------*/
/* Start WooThemes Functions - Please refrain from editing this section */
/*-----------------------------------------------------------------------------------*/
// Set path to WooFramework and theme specific functions
$functions_path = get_template_directory() . '/functions/';
$includes_path = get_template_directory() . '/includes/';
@woogist
woogist / class-woothemes-sensei-frontend.php
Created July 25, 2014 00:07
hide the notice: you have already added this Course to your cart
<?php
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
/**
* Sensei Frontend Class
*
* All functionality pertaining to the frontend of Sensei.
*
* @package WordPress
* @subpackage Sensei
<?php
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
/**
* Sensei Frontend Class
*
* All functionality pertaining to the frontend of Sensei.
*
* @package WordPress
* @subpackage Sensei
<?php
/*-----------------------------------------------------------------------------------*/
/* This theme supports WooCommerce, woo! */
/*-----------------------------------------------------------------------------------*/
add_action( 'after_setup_theme', 'woocommerce_support' );
function woocommerce_support() {
add_theme_support( 'woocommerce' );
}
@woogist
woogist / class-woothemes-sensei-messages.php
Created July 30, 2014 01:13
fix the sensei message_title error
<?php
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
/**
* Sensei Messages Class
*
* All functionality pertaining to the Messages post type in Sensei.
*
* @package WordPress
* @subpackage Sensei
@woogist
woogist / gist:9d6133aaf6f5724e1b06
Created August 7, 2014 15:45
Function Theme Add Custom URL For Slide TItle To Function Settings Post Meta Box On Posts
// Add custom slider url field to Function Settings Post Meta Box
function woo_metaboxes_add( $woo_metaboxes) {
// Check for post type = portfolio
if ( get_post_type() == "post" || !get_post_type() ) {
$woo_metaboxes['custom_field'] = array(
"name" => "url",
"label" => "Slider URL",
"type" => "text",
@woogist
woogist / single.php
Created August 11, 2014 07:57
empire: fix the title attribute on single.php
<?php get_header();?>
<?php global $woo_options; ?>
<div id="content" class="col-full">
<div id="main" class="col-left">
<?php if ( isset($woo_options[ 'woo_breadcrumbs_show' ]) && $woo_options[ 'woo_breadcrumbs_show' ] == 'true' ) { ?>
<div id="breadcrumbs">
<?php woo_breadcrumbs(); ?>
@woogist
woogist / single-portfolio.php
Created August 14, 2014 05:06
show wooslider on the single portfolio tempate of canvas theme
<?php
/**
* Single Portfolio Item Template
*
* This template is the default portfolio item template. It is used to display content when someone is viewing a
* singular view of a portfolio item ('portfolio' post_type).
* @link http://codex.wordpress.org/Post_Types#Post
*
* @package WooFramework
* @subpackage Template
@woogist
woogist / template-contact.php
Created August 15, 2014 01:28
enable new TLD's for the contact form
<?php
if ( ! defined( 'ABSPATH' ) ) exit;
/**
* Template Name: Contact Form
*
* The contact form page template displays the a
* simple contact form in your website's content area.
*
* @package WooFramework
* @subpackage Template
@woogist
woogist / wrapper-start.php
Created August 29, 2014 07:55
WPExplorer , sensei start wrapper
<?php
/**
* Content wrappers
*
* @author WooThemes
* @package Sensei/Templates
* @version 1.0.0
*/
if ( ! defined( 'ABSPATH' ) ) exit;