WordPress add a traditional callback

add_filter( 'simple_page_ordering_limit', function($number) { return 5; } );

This example uses PHP 5.3+ callback functions, so if you’re still on
PHP 5.2, you’ll need to add a traditional callback.

Read More

Can someone help to convert it to traditional callback ?

Related posts

1 comment

  1. It uses an anonymous function which is obviously not supported. You can do it like this;

    function callback_function($number) {
        return 5;
    }
    
    add_filter( 'simple_page_ordering_limit', 'callback_function');
    

Comments are closed.