Skip to content

Instantly share code, notes, and snippets.

function wp_travel_customize_price_display( $s, $c, $d ) {
global $wp_travel_itinerary;
if ( $wp_travel_itinerary->is_sale_enabled() ) {
return $s;
}
function travel_log_front_page_slider_wrap() {
if ( ! is_front_page() || is_home() ) {
return;
}
$enabled = travel_log_get_theme_option( 'home_slider_enable' );
if ( ! is_customize_preview() && false === $enabled && ! is_home() ) {
function tp_philosophy_pro_filter_get_team_options( $input ) {
$options = tp_philosophy_pro_get_theme_options(); // get theme options
$content_type = $options['team_options_content_type'];
$content = array(); // create an empty array
switch ( $content_type ) {
case 'category':
$category_ids = ! empty( $options['team_options_content_category'] ) ? ( array ) $options['team_options_content_category'] : array();
// Bial if no category is selected
function wp_travel_customize_price_display( $s, $c, $d ) {
global $wp_travel_itinerary;
if ( $wp_travel_itinerary->is_sale_enabled() ) {
return $s;
}
add_filter( 'get_the_archive_title', function ($title) {
if ( is_category() ) {
$title = single_cat_title( '', false );
} elseif ( is_tag() ) {
$title = single_tag_title( '', false );
} elseif ( is_author() ) {
$title = '<span class="vcard">' . get_the_author() . '</span>' ;
}
return 'Change the tile as per your wish';
});
function wp_travel_customize_price_display( $s, $c, $d ) {
global $wp_travel_itinerary;
if ( $wp_travel_itinerary->is_sale_enabled() ) {
return $s;
}
return sprintf( esc_html__('Guide price %1s %2s', 'wp-travel' ), $c, $d );
}
add_filter( 'wp_travel_itinerary_price', 'wp_travel_customize_price_display', 99, 3 );
<?php
/**
*Recommended way to include parent theme styles.
*(Please see http://codex.wordpress.org/Child_Themes#How_to_Create_a_Child_Theme)
*/
add_action( 'wp_enqueue_scripts', 'travel_log_child_style' );
function travel_log_child_style() {
wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );
/**
* Testimonial Widget Class
*
* @since WEN Business 1.0
*
*/
class WEN_Business_Testimonial_Widget extends WP_Widget {
function __construct() {
$opts = array(
/**
* Render home news block.
*
* @since 1.0.0
*/
function education_hub_get_home_news_block_content() {
$home_news_section_status = education_hub_get_option( 'home_news_section_status' );
if ( true !== $home_news_section_status ) {
return;
<?php
/**
* Product search template.
*
* @package eCommerce_Market_Pro
*/
?>
<?php $args = array(
'number' => '',
'orderby' => 'name',