Initial commit

This commit is contained in:
2018-09-13 20:49:49 +07:00
commit 32875f828d
82 changed files with 44319 additions and 0 deletions
+42
View File
@@ -0,0 +1,42 @@
<?php
/**
* Yeu Chay Bo
*
* This file adds the boxed page template to the Yeu Chay Bo Theme.
*
* Template Name: Boxed Template
*
* @package SEOThemes\CorporatePro
* @link https://thuanbui.me/themes/yeuchaybo
* @author Thuan Bui
* @copyright Copyright © 2018 Thuan Bui
* @license GPL-2.0+
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
die;
}
add_filter( 'body_class', 'corporate_add_boxed_body_class' );
/**
* Add contact page body class to the head.
*
* @since 1.0.0
*
* @param array $classes Array of body classes.
*
* @return array
*/
function corporate_add_boxed_body_class( $classes ) {
$classes[] = 'boxed-page';
return $classes;
}
// Run the Genesis loop.
genesis();
+41
View File
@@ -0,0 +1,41 @@
<?php
/**
* Yeu Chay Bo
*
* This file adds the page builder template to the Yeu Chay Bo theme.
*
* Template Name: Page Builder
*
* @package SEOThemes\CorporatePro
* @link https://thuanbui.me/themes/yeuchaybo
* @author Thuan Bui
* @copyright Copyright © 2018 Thuan Bui
* @license GPL-2.0+
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
die;
}
// Remove default hero section.
remove_action( 'genesis_after_header', 'corporate_hero_section_open', 20 );
remove_action( 'genesis_after_header', 'corporate_hero_section_title', 24 );
remove_action( 'genesis_after_header', 'corporate_hero_section_close', 28 );
// Get site-header.
get_header();
// Custom loop, remove all hooks except entry content.
if ( have_posts() ) :
the_post();
do_action( 'genesis_entry_content' );
endif;
// Get site-footer.
get_footer();
+67
View File
@@ -0,0 +1,67 @@
<?php
/**
* Yeu Chay Bo
*
* This file adds the contact page template to the Yeu Chay Bo Theme.
*
* Template Name: Contact Page
*
* @package SEOThemes\CorporatePro
* @link https://thuanbui.me/themes/yeuchaybo
* @author Thuan Bui
* @copyright Copyright © 2018 Thuan Bui
* @license GPL-2.0+
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
die;
}
add_filter( 'body_class', 'corporate_add_contact_body_class' );
/**
* Add contact page body class to the head.
*
* @since 1.0.0
*
* @param array $classes Array of body classes.
*
* @return array
*/
function corporate_add_contact_body_class( $classes ) {
$classes[] = 'contact-page';
return $classes;
}
add_action( 'genesis_before_content_sidebar_wrap', 'corporate_contact_page_map' );
/**
* Display Google map shortcode.
*
* Simply echoes the default map shortcode created by the Google Map plugin.
*
* @since 1.0.0
*
* @return void
*/
function corporate_contact_page_map() {
echo do_shortcode( '[ank_google_map]' );
}
// Remove default hero section (show map instead).
remove_action( 'genesis_before_content_sidebar_wrap', 'corporate_hero_section' );
// Add entry title back inside content.
add_action( 'genesis_entry_header', 'genesis_do_post_title', 2 );
// Add page excerpt just below the title.
add_action( 'genesis_entry_header', 'corporate_page_excerpt', 3 );
// Run the Genesis loop.
genesis();
+89
View File
@@ -0,0 +1,89 @@
<?php
/**
* Yeu Chay Bo
*
* This file adds the landing page template to the Yeu Chay Bo Theme.
*
* Template Name: Landing Page
*
* @package SEOThemes\CorporatePro
* @link https://thuanbui.me/themes/yeuchaybo
* @author Thuan Bui
* @copyright Copyright © 2018 Thuan Bui
* @license GPL-2.0+
*/
// If this file is called directly, abort.
if ( ! defined( 'WPINC' ) ) {
die;
}
add_filter( 'body_class', 'corporate_add_landing_body_class' );
/**
* Add landing page body class to the head.
*
* @since 1.0.0
*
* @param array $classes Array of body classes.
*
* @return array
*/
function corporate_add_landing_body_class( $classes ) {
$classes[] = 'landing-page';
return $classes;
}
add_action( 'wp_enqueue_scripts', 'corporate_dequeue_skip_links' );
/**
* Dequeue Skip Links script.
*
* @since 1.0.0
*
* @return void
*/
function corporate_dequeue_skip_links() {
wp_dequeue_script( 'skip-links' );
}
// Remove Skip Links.
remove_action( 'genesis_before_header', 'genesis_skip_links', 5 );
// Force full width content layout.
add_filter( 'genesis_site_layout', '__genesis_return_full_width_content' );
// Remove site header elements.
remove_action( 'genesis_header', 'genesis_header_markup_open', 5 );
remove_action( 'genesis_header', 'genesis_do_header' );
remove_action( 'genesis_header', 'genesis_header_markup_close', 15 );
// Remove default hero section.
remove_action( 'genesis_before_content_sidebar_wrap', 'corporate_hero_section' );
// Remove navigation.
remove_theme_support( 'genesis-menus' );
// Remove breadcrumbs.
remove_action( 'genesis_before_loop', 'genesis_do_breadcrumbs' );
// Remove footer widgets.
remove_theme_support( 'genesis-footer-widgets' );
remove_action( 'genesis_footer', 'corporate_before_footer' );
remove_action( 'genesis_footer', 'corporate_footer_credits', 14 );
// Remove site footer elements.
remove_action( 'genesis_footer', 'genesis_footer_markup_open', 5 );
remove_action( 'genesis_footer', 'genesis_do_footer' );
remove_action( 'genesis_footer', 'genesis_footer_markup_close', 15 );
// Add title back (removed in /includes/header.php).
remove_action( 'genesis_before', 'corporate_hero_section_setup' );
// Run the Genesis loop.
genesis();