ecommerce:storefront_child_theme_functions.php
no way to compare when less than two revisions
Differences
This shows you the differences between two versions of the page.
— | ecommerce:storefront_child_theme_functions.php [2021/10/20 23:28] (current) – created mithat | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== functions.php for Storefront child theme ====== | ||
+ | Hack to get the copyright line to appear as I want. | ||
+ | <file php functions.php> | ||
+ | <?php | ||
+ | // Exit if accessed directly | ||
+ | if ( !defined( ' | ||
+ | |||
+ | // BEGIN ENQUEUE PARENT ACTION | ||
+ | // AUTO GENERATED - Do not modify or remove comment markers above or below: | ||
+ | |||
+ | // END ENQUEUE PARENT ACTION | ||
+ | |||
+ | /* | ||
+ | * MFK Storefront customizations | ||
+ | * Mithat Konar | ||
+ | */ | ||
+ | |||
+ | /* Replace copyright info. */ | ||
+ | // | ||
+ | function storefront_credit() { | ||
+ | ?> | ||
+ | <div class=" | ||
+ | Copyright © 2018-2021 Mithat Konar. All rights reserved. | ||
+ | </ | ||
+ | <?php | ||
+ | } | ||
+ | |||
+ | /* Disable different address checked by default. | ||
+ | * From https:// | ||
+ | * Doesn' | ||
+ | */ | ||
+ | // | ||
+ | |||
+ | /* Number of categories on homepage. */ | ||
+ | add_filter(' | ||
+ | function custom_storefront_category_per_page( $args ) { | ||
+ | | ||
+ | | ||
+ | | ||
+ | } | ||
+ | |||
+ | /* Change titles of homepage sections */ | ||
+ | // Featured products | ||
+ | add_filter( ' | ||
+ | function custom_storefront_product_featured_title( $args ) { | ||
+ | $args[' | ||
+ | return $args; | ||
+ | } | ||
+ | |||
+ | // Recent (new) products title | ||
+ | add_filter( ' | ||
+ | function custom_storefront_product_recent_products_title( $args ) { | ||
+ | $args[' | ||
+ | return $args; | ||
+ | } | ||
+ | |||
+ | /* Fonts */ | ||
+ | // From http:// | ||
+ | // Remove Google Font from Storefront theme | ||
+ | /* | ||
+ | function iggy_child_styles() { | ||
+ | wp_dequeue_style(' | ||
+ | add_filter( ' | ||
+ | wp_enqueue_style(' | ||
+ | } | ||
+ | add_action( ' | ||
+ | */ | ||
+ | |||
+ | // If you just need to change Google font from default one, you may use the snippet taken from here. | ||
+ | /* | ||
+ | add_filter( ' | ||
+ | function my_font_families( $family ) { | ||
+ | //$family = []; // mfk to get rid of Source Sans Pro, which isn't gotten rid of anyway though it's not in HTML | ||
+ | $family[' | ||
+ | return $family; | ||
+ | } | ||
+ | */ | ||
+ | </ |
ecommerce/storefront_child_theme_functions.php.txt · Last modified: 2021/10/20 23:28 by mithat