Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

Any chance of a blurb ext?

edited July 2006 in Vanilla 1.0 Help
An ext that will show a little preview of the discussion posted by the original starter? get me? like u see on dig would be awsome!

Comments

  • Options
    blizeHblizeH ✭✭
    :(
  • Options
    ):
  • Options
    thank for the help...
  • Options
    edited July 2006
    I have not looked, at how extensions are handled in Vanilla 1, and I only briefly took at look at them in 0.9.x, so I can't say for sure. Don't mind those people. I am sure it is possible, and the beauty of having it as an extension is that they don't have to use it :P Give them a chance guys. Stick around, and I am sure that Mark, or another extension developer will tell you if it is possible, and might give you some direction on how to tackle the problem. You might want to read the docs also. There could be something there.
  • Options
    The Discussion object has a $FirstCommentID field, but I don't know any way to get the comment text from an ID other than a raw database query.

    Maybe there's a way and I'm just missing it, but from what you have to work with in the discussion templates, it would be pretty hard.
  • Options
    MarkMark Vanilla Staff
    edited July 2006
    No, you can do this no problem. It might require that I add a delegate or two to the source, but that's not a problem either. Basically you attach to a delegate in the discussionmanager class and alter the GetDiscussionBuilder method so that it joins to the comment table on the FirstCommentID (as bergamot said). Then you'd attach to a delegate on the DiscussionGrid control to render that extra bit of information for each discussion, and finally you'd add a stylesheet to style your new bit of xhtml. I'm pretty sure you'd need a new delegate in the themes/discussion.php template file, but there should already be a delegate for you to use in the DiscussionManager class.
  • Options
    What might be even cooler is to use a tooltip-like ability to display the synopsis in a hovering DIV. Would cut down on clutter.
  • Options
    Mark you seem to know what you are doing, if you have time could you make it?
  • Options
    i'm looking in other extensions' code how i could make this and the DiscussionCounters ext adds this delegate:

    $Context->AddToDelegate("DiscussionGrid", "PostDiscussionOptionsRender", "DiscussionGridView_Add");

    but i can't find where this 'PostDiscussionOptionsRender' delegate is called. i only see PreRender and PostRender but this must be something between both, am i blind?
  • Options
    edited July 2006
    I posted some example code of how I do this here:

    http://lussumo.com/community/discussion/2960/blogging-extension-question/#Item_19

    never quite finished though...
  • Options
    tarninc Jul 5th 2006

    Mark you seem to know what you are doing, if you have time could you make it?
    :( ):
This discussion has been closed.