simpleplus_vertical_home_top
ソニーペイメントサービスの2つの決済モジュール

Welcart Beldad 1.5.3 をリリース

Welcart Beldad 1.5.3 をリリースしました。修正点は以下のとおりです。

PHP8.2対応

テンプレート修正 : inc/theme-customizer.php 1737行目~1869行目あたり

/**
 * Display theme option
 */
function wcct_get_options( $key = '' ) {
    if ( empty( $key ) ) {
        return;
    }

    $options = get_option( 'basic_type_options' );

    if ( ! is_admin() ) {
        if ( ! isset( $options['logo'] ) ) {
            $options['logo'] = '';
        }
        if ( ! isset( $options['facebook_id'] ) ) {
            $options['facebook_id'] = '';
        }
        if ( ! isset( $options['facebook_button'] ) ) {
            $options['facebook_button'] = false;
        }
        if ( ! isset( $options['twitter_id'] ) ) {
            $options['twitter_id'] = '';
        }
        if ( ! isset( $options['twitter_button'] ) ) {
            $options['twitter_button'] = false;
        }
        if ( ! isset( $options['instagram_id'] ) ) {
            $options['instagram_id'] = '';
        }
        if ( ! isset( $options['instagram_button'] ) ) {
            $options['instagram_button'] = false;
        }

        if ( ! isset( $options['page_loading'] ) ) {
            $options['page_loading'] = true;
        }
        if ( ! isset( $options['fixed_header'] ) ) {
            $options['fixed_header'] = false;
        }
        if ( ! isset( $options['display_top_sidebar'] ) ) {
            $options['display_top_sidebar'] = false;
        }
        if ( ! isset( $options['sidebar'] ) ) {
            $options['sidebar'] = 'left-set';
        }

        if ( ! isset( $options['display_h_item_slide'] ) ) {
            $options['display_h_item_slide'] = false;
        }

        if ( ! isset( $options['display_info'] ) ) {
            $options['display_info'] = false;
        }
        if ( ! isset( $options['info_cat'] ) ) {
            $options['info_cat'] = wcct_get_info_default();
        }
        if ( ! isset( $options['info_num'] ) ) {
            $options['info_num'] = 1;
        }
        if ( ! isset( $options['display_topics'] ) ) {
            $options['display_topics'] = false;
        }
        if ( ! isset( $options['topics_cat'] ) ) {
            $options['topics_cat'] = wcct_get_info_default();
        }
        if ( ! isset( $options['topics_num'] ) ) {
            $options['topics_num'] = 5;
        }
        if ( ! isset( $options['display_cat'] ) ) {
            $options['display_cat'] = false;
        }
        if ( ! isset( $options['display_cat_title'] ) ) {
            $options['display_cat_title'] = 'Category';
        }
        if ( ! isset( $options['display_cat_slide'] ) ) {
            $options['display_cat_slide'] = false;
        }
        if ( ! isset( $options['display_pickup'] ) ) {
            $options['display_pickup'] = false;
        }
        if ( ! isset( $options['pickup_cat'] ) ) {
            $options['pickup_cat'] = wcct_get_info_default();
        }
        if ( ! isset( $options['pickup_num'] ) ) {
            $options['pickup_num'] = 3;
        }
        if ( ! isset( $options['display_pickup_slide'] ) ) {
            $options['display_pickup_slide'] = false;
        }

        if ( ! isset( $options['display_soldout'] ) ) {
            $options['display_soldout'] = true;
        }
        if ( ! isset( $options['display_inquiry'] ) ) {
            $options['display_inquiry'] = true;
        }
        if ( ! isset( $options['display_inquiry_text'] ) ) {
            $options['display_inquiry_text'] = __( 'Contacting this item', 'welcart_basic_beldad' );
        }
        if ( ! isset( $options['display_produt_tag'] ) ) {
            $options['display_produt_tag'] = true;
        }

        if ( ! isset( $options['cart_button'] ) ) {
            $options['cart_button'] = __( 'Add to Shopping Cart', 'usces' );
        }
        if ( ! isset( $options['display_zaiko_text'] ) ) {
            $options['display_zaiko_text'] = false;
        }
        if ( ! isset( $options['display_soldout_text'] ) ) {
            $options['display_soldout_text'] = __( '只今お取扱い出来ません', 'welcart_basic_beldad' );
        }
        if ( ! isset( $options['inquiry_text'] ) ) {
            $options['inquiry_text'] = __( 'この商品に関するお問い合わせ', 'welcart_basic_beldad' );
        }
        if ( ! isset( $options['review'] ) ) {
            $options['review'] = false;
        }

        if ( ! isset( $options['continue_shopping_button'] ) ) {
            $options['continue_shopping_button'] = false;
        }
        if ( ! isset( $options['continue_shopping_url'] ) ) {
            $options['continue_shopping_url'] = '';
        }
    }

    if ( empty( $options[ $key ] ) ) {
        return;
    }

    return $options[ $key ];
}
/**
* Display theme option
*/
function wcct_get_options( $key = '' ) {

    $option_value = null;
    if ( empty( $key ) ) {
        return $option_value;
    }

    $options = get_option( 'basic_type_options' );

    if ( ! is_admin() ) {
        if ( isset( $options[ $key ] ) ) {
            $option_value = $options[ $key ];
        } else {
            switch ( $key ) {
                case 'logo':
                    $option_value = '';
                    break;
                case 'facebook_id':
                    $option_value = '';
                    break;
                case 'facebook_button':
                    $option_value = false;
                    break;
                case 'twitter_id':
                    $option_value = '';
                    break;
                case 'twitter_button':
                    $option_value = false;
                    break;
                case 'instagram_id':
                    $option_value = '';
                    break;
                case 'instagram_button':
                    $option_value = false;
                    break;

                case 'page_loading':
                    $option_value = true;
                    break;
                case 'fixed_header':
                    $option_value = false;
                    break;
                case 'display_top_sidebar':
                    $option_value = false;
                    break;
                case 'sidebar':
                    $option_value = 'left-set';
                    break;

                case 'display_h_item_slide':
                    $option_value = false;
                    break;

                case 'display_info':
                    $option_value = false;
                    break;
                case 'info_cat':
                    $option_value = wcct_get_info_default();
                    break;
                case 'info_num':
                    $option_value = 1;
                    break;
                case 'display_topics':
                    $option_value = false;
                    break;
                case 'topics_cat':
                    $option_value = wcct_get_info_default();
                    break;
                case 'topics_num':
                    $option_value = 5;
                    break;
                case 'display_cat':
                    $option_value = false;
                    break;
                case 'display_cat_title':
                    $option_value = 'Category';
                    break;
                case 'display_cat_slide':
                    $option_value = false;
                    break;
                case 'display_pickup':
                    $option_value = false;
                    break;
                case 'pickup_cat':
                    $option_value = wcct_get_info_default();
                    break;
                case 'pickup_num':
                    $option_value = 3;
                    break;
                case 'display_pickup_slide':
                    $option_value = false;
                    break;

                case 'display_soldout':
                    $option_value = true;
                    break;
                case 'display_inquiry':
                    $option_value = true;
                    break;
                case 'display_inquiry_text':
                    $option_value = __( 'Contacting this item', 'welcart_basic_beldad' );
                    break;
                case 'display_produt_tag':
                    $option_value = true;
                    break;

                case 'cart_button':
                    $option_value = __( 'Add to Shopping Cart', 'usces' );
                    break;
                case 'display_zaiko_text':
                    $option_value = false;
                    break;
                case 'display_soldout_text':
                    $option_value = __( 'At present we cannot deal with this product.', 'welcart_basic_beldad' );
                    break;
                case 'inquiry_text':
                    $option_value = __( 'Inquiries about this product', 'welcart_basic_beldad' );
                    break;
                case 'review':
                    $option_value = false;
                    break;

                case 'continue_shopping_button':
                    $option_value = false;
                    break;
                case 'continue_shopping_url':
                    $option_value = '';
                    break;
            }
        }
    }

    return $option_value;
}

get_terms() の引数指定方法を変更

テンプレート修正 : front-page.php 103行目あたり

$target_terms = get_terms( 'category', array( 'child_of' => usces_get_cat_id( 'item' ) ) );
$target_arg   = array(
    'taxonomy' => 'category',
    'child_of' => usces_get_cat_id( 'item' ),
);
$target_terms = get_terms( $target_arg );

テンプレート修正 : inc/theme-customizer.php 1878行目~1881行目あたり

$target_arg   = array(

    'hide_empty'   => false,
    'exclude_tree' => usces_get_cat_id( 'item' ),
);
$target_terms = get_terms( 'category', $target_arg );
$target_arg   = array(
    'taxonomy'     => 'category',
    'hide_empty'   => false,
    'exclude_tree' => usces_get_cat_id( 'item' ),
);
$target_terms = get_terms( $target_arg );

カテゴリー画像選択時、ログインユーザー以外がアップロードした画像を選択できない不具合を修正

テンプレート修正 : inc/term-customized.php 153行目~164行目あたり

file_frame = wp.media.frames.file_frame = wp.media({
    title: '<?php esc_html_e( 'Front page', 'welcart_basic_beldad' ); ?>',
    library: {
        type: 'image',
        author: userSettings.uid
    },
    button: {
        text: '<?php esc_html_e( 'Set the category image', 'welcart_basic_beldad' ); ?>',
        close: true
    },
    multiple: false
});
file_frame = wp.media.frames.file_frame = wp.media({
    title: '<?php esc_html_e( 'Front page', 'welcart_basic_beldad' ); ?>',
    library: {
        type: 'image',

    },
    button: {
        text: '<?php esc_html_e( 'Set the category image', 'welcart_basic_beldad' ); ?>',
        close: true
    },
    multiple: false
});

ロゴ画像を削除した際、サイトタイトルが表示されない不具合を修正

関数追加 : inc/template-functions.php

/**
 * Save blank values
 *
 * @param string $input Text.
 * @return string
 */
function welcart_basic_callback_esc_url_raw( $input ) {
    return ( '' === $input ) ? '' : esc_url_raw( $input );
}

テンプレート修正 : inc/theme-customizer.php 23行目あたり

$wp_customize->add_setting(
    'basic_type_options[logo]',
    array(
        'default'           => '',
        'type'              => 'option',
        'capability'        => 'edit_theme_options',
        'sanitize_callback' => 'esc_url_raw',
    )
);
$wp_customize->add_setting(
    'basic_type_options[logo]',
    array(
        'default'           => '',
        'type'              => 'option',
        'capability'        => 'edit_theme_options',
        'sanitize_callback' => 'welcart_basic_callback_esc_url_raw',
    )
);

キービジュアルスライダーの矢印位置を修正

CSS追加 : style.css

#main-visual  .flex-nav-next .flex-next {
    text-align: center;
}

【WCEX Auto Delivery】定期購入ボタンの表示崩れを修正

CSS追加 : usces_cart.css

#memberinfo .header_explanation .gotoedit a {
    display: inline-flex;
    align-items: center;
    height: 46px;
}
@media screen and (min-width: 62.5em) {
    #memberinfo .header_explanation .gotoedit a {
        height: 56px;
    }
}