This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't copy this line in your code. | |
function your_prefix_next_previous_post_titles() { | |
return array( | |
'next_text' => get_the_title( get_next_post() ) . ' <span class="ast-right-arrow">→</span>', | |
'prev_text' => '<span class="ast-left-arrow">←</span> ' . get_the_title( get_previous_post() ), | |
); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't copy this line in your code | |
function your_prefix_change_post_type_slug( $args, $post_type ) { | |
if ( 'sfwd-topic' == $post_type ) { | |
$args['labels']['name'] = 'LD Topics'; | |
} | |
return $args; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Change WooCommerce product gallery image thumbnail dimensions. | |
* | |
* @return Array Array( height, width ) | |
*/ | |
function your_prefix_gallery_image_sizes() { | |
return array( | |
600, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't copy this line in your code | |
/** | |
* Disable title on all post types. | |
* | |
* Change 'page' post type to your custom post type if you want to use this for different custom post types. | |
*/ | |
function your_prefix__featured_image() { | |
$post_types = array( | |
'post', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't copy this line in your code | |
/** | |
* Disable title on all post types. | |
*/ | |
function your_prefix_post_title() { | |
$post_types = array( | |
'post', | |
'page', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't copy this line in your file. | |
// Condition to check if this page requires `Apply Now` button. | |
if ( 1481 === get_the_id() ) { | |
your_prefix_setup_header_button_apply_now(); | |
} | |
/** | |
* Setup filters for changing the values in the Astra Settings. | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery(document).on('ready', function(event) { | |
// Scroll smoothly to anchor | |
jQuery('a[href^="#"]').on('click', function(event) { | |
var target = jQuery(this.getAttribute('href')); | |
if( target.length ) { | |
event.preventDefault(); | |
jQuery('html, body').stop().animate({ | |
scrollTop: target.offset().top | |
}, 1000); |