• I am using punbb message board and I am wanting to connect it to my wordpress blog that when I post an entry in the blog, it is also posted in the forum for comments. Sort of what NP_PunBB does for nucleus. Does anyone know of a plugin that that might do the trick? If I new how to begin I would try to write a plugin, but I would not even know where to begin.

Viewing 2 replies - 1 through 2 (of 2 total)
  • start like this:

    function wp2punbb( $id )
    {
    global $wpdb;

    /*
    * fetch and process wp data
    **/
    $posts = $wpdb->get_results(“SELECT * FROM $wpdb->posts WHERE ID = ‘$id'”);

    if ( !$posts )
    return $id;

    $post = $posts[0];
    $title = apply_filters(‘the_title’, $post->post_title);
    $content = apply_filters(‘the_content’, $post->post_content);

    /*
    * insert into punbb as appropriate
    */

    // likely a simple insert query

    return $id;
    }

    add_filter(‘post_publish’, ‘wp2punbb’);

    Thread Starter joshmac

    (@parkstreet)

    Thank you very much. I will start working on this and hopefully come out with something good.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Punbb’ is closed to new replies.