Messageboard to River

with the Messageboard mod enabled, is there a way to have the actual messageboard post appear in the river, rather than 'A' posted on 'B's' messageboard?

I think this would be extremely valuable for users to create more content with less jumping around, especially with mods like rivercomments.

I've looked into the create and add files but haven't found a way to display the actual comment in the river.

Any ideas?

Thanks,

Tri

  • Ok, after mimicking the Groups create view, here's my new addition to the river/object/messageboard/create view:

        //grab the annotation, if one exists
        if($vars['item']->annotation_id != 0)
            $annotation_object = get_annotation($vars['item']->annotation_id)->value;

        echo $string . $annotation_object;

    But still nothing!!!  I cannot figure out why the actual messageboard post will NOT appear in place of the default 'A' posted on 'B's' Messageboard!?

    Please help, I"ve been battling with this for a week, any fresh input will be a relief!

  • I've been trying to do the same thing. I wrote essentially the same code you have and it doesn't work for me either. I was looking through the 1.7.2b code and noticed that the add_to_river function sends the annotation_id to the river, so it might be easier with 1.7.2 when its released, i just haven't gotten the chance to set it up and try it. Personally, I think the messageboard needs a rewrite to use elgg_objects so that there can be commenting on messageboard posts. I'd like to take on the project and make an enhanced messageboard, but I really need to better learn the inner workings of elgg first. I wish there was more documentation, maybe an writing elgg plugins for dummies book.

  • @triout, you are trying to display the annotation object rather than the annotation data. Try

    $annotation_object->value

    As Brett pointed out earlier...

  • Thanks for writing RPGRealms, so am i adding: $annotation_object->value to:

    //grab the annotation, if one exists
        if($vars['item']->annotation_id != 0)
            $annotation_object = get_annotation($vars['item']->annotation_id)->value;

    or am i adding it to:

    echo $string . $annotation_object;  ???

    Is the code i've written above even correct? Ah, this is driving me nuts.

  • echo $string . $annotation_object->value;

  • hmm, i've added that...still no results. 

    Maybe this part i've written is getting in the way, does this look correct:

    //grab the annotation, if one exists
        if($vars['item']->annotation_id != 0)
            $annotation_object = get_annotation($vars['item']->annotation_id)->value;

     

  • This comment was removed by an administrator because it contained advertising.

  • Thanks.

    I'm obviously getting very close, and this group is a learning/teaching environment, I am simply looking for more detailed help...like how to pass the annotation_id to the create file.  Just paying someone to get the job done will not teach me anything.  I appreciate your help so far, any other instruction you can give is appreciated.

  • What you are looking for is someone to tell you how to do it, which you would get by hiring someone to write the code.

    If you are wanting to learn, you've been given more than enough info to figure it out if you bother to look around at the example, tutorials, and other references on this site.

  • I've been staring at examples from generic comments, group topic posts and annotations, I haven't yet figured out how to bring them all together for this solution.  Clearly I am new to elgg and php.  Like I said, thank you for your help so far.