WordPress.org

Ready to get started?Download WordPress

Forums

Antispam Bee
protect private methods… (2 posts)

  1. Michael Cannon
    Member
    Posted 1 year ago #

    I'd like to reuse Antispam Bee for protecting non-comment submitted materials. However, with methods like _verify_comment_request set as private, I'm not able to call the method unless I instantiate Antispam Bee's class entirely. I don't want to do that so that I can call only specific parts.

    Could you please review the Antispam_Bee class for your actual checking methods and create static public accessors?

    Thank you.

    @ref http://stackoverflow.com/questions/4361553/php-public-private-protected

    http://wordpress.org/extend/plugins/antispam-bee/

  2. Michael Cannon
    Member
    Posted 1 year ago #

    Something like this is what I mean. For now, this is my workaround.

    class Testimonials_Widget_Premium_Antispam_Bee_Base extends Antispam_Bee {
        public function verify_comment_request( $input ) {
            return self::_verify_comment_request( $input );
        }
    }

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.