WordPress.org

Support

Support » WP-Advanced » [Resolved] hook before comment commited

[Resolved] hook before comment commited

  • agharbeia
    Member

    @agharbeia

    Is there a hook in the API that allows action to be taken before a comment is inserted into the database?

    If I am sure I want to refuse certain comments, for example, based on their content or other criteria, instead of marking them as spam or hooking to comment_post and deleting them from the database causing unnecessary overhead and indexing?

Viewing 4 replies - 1 through 4 (of 4 total)
  • http://wphooks.flatearth.org/

    Maybe that will help?

    agharbeia
    Member

    @agharbeia

    Thank you, milkb.

    Is there a plan to incorporate that information in the codex?

    I mean, there’s nothing preventing this from happening except maybe the needed volunteered effort, no?

    A question (if you happen to know): Since the whole of the information there seems to be ‘unofficial’, does “undocumented” merely mean that there is no information about that specific hook/filter in there yet, or does it mean that the hook/filter is itself undocumented and using it is considered a hack?

    Regards,

    Undocumented just means no one’s typed up a description for it. Often it’s because it’s a rarely used hook or one that’s obvious.

    and using it is considered a hack?

    I don’t get what you mean…

    All hooks/filters were officially added and are officially supported.

    agharbeia
    Member

    @agharbeia

    All hooks/filters were officially added and are officially supported.

    This answers my question. Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Resolved] hook before comment commited’ is closed to new replies.