• Hi Kazuya Takami,

    First of all, thanks for the great plugin..!

    I have found an issue that when i enabled the output for the Homepage only then it checks 2 things.

    1. is_home()
    2. is_front_page()

    These 2 are different things. I need some of the SCHEMA only on the Frontpage not for the Blog’s Homepage.

    It would be great if you can add 2 different checks on Admin section so, users can choose if they want the SCHEMA on both Frontpage as well as Blog’s homepage or vice versa.

    In my case, i need “Local Business” SCHEMA for the Frontpage only.

    Thanks,
    Yasir

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Yasir

    (@yasglobal)

    Hi Kazuya Takami,

    I have not heard from you, I believe you are busy with other things so decided to go in some more detail about my request.
    At the moment, there is a single check for Front Page and Blog’s Homepage. Can you please add 2 checks on backend.

    Front Page
    Blog’s Homepage

    By default, these checks can be enabled so, those users who wants to disable any check can do that and if it looks difficult so, you can add a simple filter in wp-structuring-display.php which helps user to make these changes from their functions.php file.

    Just replace line no. 94 with the following lines in wp-structuring-display.php:

    `

    $filter_data = apply_filters( ‘structuring_markup_schema’, ‘__true’, $output, $row->type );

    if ( array_key_exists( $output, $output_args ) && ‘__false’ != $filter_data ) {

    
    
    This filter allows user to disable any schema on the specific pages as shown here:
    

    function yasglobal_markup_schema( $value, $arg1, $arg2 ) {

    if ( ‘home’ == $arg1 && ‘local_business’ == $arg2 && ! is_front_page() ) {

    return ‘__false’;

    }

    }

    add_filter( ‘structuring_markup_schema’, ‘yasglobal_markup_schema’, 10, 3 );

    `

    I hope, you can apply any of the above mentioned change in the coming version or anything else which give us ability to stop the SCHEMA on specific pages specially for the Front Page and Blog’s homepage. In this way, we can use your plugin with the updated release otherwise we need to stop your plugin updates for our site.

    yigalj

    (@yigalj)

    Hi Kazuya Takami,

    Would like to follow up with you on this request. The setup for Organization, Local Business, and WebSite schema.org using your plugin allows Output on selection of
    All Pages (In Header)
    Homepage
    Posts
    Pages

    However, when the selection is only Homepage, then they will also be outputted on blog page as well. Is there a way to fix this issue, so that the schema for these three will be added to the homepage only?

    Thanks,
    Yigal

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Condition for Homepage also works on the Blog Homepage’ is closed to new replies.