Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter artek1

    (@artek1)

    the documentation includes both:
    Docs link

    `
    wc_pay_per_post_args

    This filter allows you to override the WP Query arguments for the shortcodes.

    Example:
    add_filter(‘wc_pay_per_post_args’, ‘my_theme_wc_ppp_args’);
    function my_theme_wc_ppp_args($args){
    $args[‘orderby’] = ‘menu_order’;
    return $args;
    }
    wc_pay_per_post_shortcode_has_access_no_posts

    This filter allows you to override the text “You have not have access to any protected posts.” in the Has Access shortcode

    Example:
    add_filter(‘wc_pay_per_post_shortcode_has_access_no_posts’, ‘my_theme_wc_pay_per_post_shortcode_has_access_no_posts’);
    function my_theme_wc_pay_per_post_shortcode_has_access_no_posts(){
    return ‘Your New Title’;
    }
    wc_pay_per_post_shortcode_purchased_no_posts

    This filter allows you to override the text “You have not purchased any protected posts.” in the Has Access shortcode

    Example:
    add_filter(‘wc_pay_per_post_shortcode_purchased_no_posts’, ‘my_theme_wc_pay_per_post_shortcode_has_access_no_posts’);
    function my_theme_wc_pay_per_post_shortcode_purchased_no_posts(){
    return ‘Your New Title’;
    }`

    All I do is copy the two examples available for the free version

    Website is under modification. There is no cache plugin.
    Caching in hosting is disabled

    Thread Starter artek1

    (@artek1)

    when i add this filter:

    add_filter('wc_pay_per_post_shortcode_has_access_no_posts', 'my_theme_wc_pay_per_post_shortcode_has_access_no_posts');
    function my_theme_wc_pay_per_post_shortcode_has_access_no_posts(){
        return 'Your New Title';
    }

    nothing happens (the text is not overwritten and there is no error)

    in this:

    add_filter('wc_pay_per_post_shortcode_purchased_no_posts', 'my_theme_wc_pay_per_post_shortcode_has_access_no_posts');
    function my_theme_wc_pay_per_post_shortcode_purchased_no_posts(){
        return 'Your New Title';
    }

    shows error

    screen:
    scr1

    scr2

    • This reply was modified 2 years, 9 months ago by artek1.

    Hello

    What is the difference between Entries screen and Advancerd entries screen?
    Is there any documentation for this plugin?

Viewing 3 replies - 1 through 3 (of 3 total)