Support » Plugins » Hook for when comment added to blog post

  • Hi,

    I’m trying to write a plugin that pops up a message window when a comment is posted to a blog post. At the moment I’m using the action hook

    add_action("wp_insert_comment", "function_name");
    function function_name(){
        echo "<script>
                  mywindow ='', ' ',     'width=300,height=500');

    [Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum’s parser.]

    When I post a comment to a blog post I expect the twitter window to pop up but nothing happens. Any help will be appreciated.



  • The topic ‘Hook for when comment added to blog post’ is closed to new replies.