Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

[Share Me] v1.03 update concerns

edited January 2011 in Vanilla 2.0 - 2.8
Thanks to Tim, I've learned a bit more about developing a plugin for Vanilla. I've rewritten a good portion of it, so it works a little different. I've experimented with the share icon links in a few different places; at the right of the title, at the end of the page, and as a panel in the sidebar. I'm not sure how to make this configurable yet, so I'm left with the sidebar panel version, as it allows for some text and more share icons, for future updates or unless someone else takes over. The only way around this until I can figure it out, is if I were write and maintain three different versions of this. So please don't update the plugin to version 1.03 (coming soon), if you prefer the share icons at the bottom of the discussion page instead of the sidebar panel.


  • Options
    TimTim Operations Vanilla Staff
    edited January 2011
    If I were you I'd set a config variable based on the user's choice of where to put the plugin's output. Then when your plugin loads (for example, inside the __construct()), read that config into a property of your object.

    $this->OutputLocation = C('Plugins.ShareMe.OutputLocation', 'panel');

    Hook into all the possible events your plugin supports (title, panel, footer, etc), and based on the value in $this->OutputLocation, either return immediately from the event without producing output, or continue and call your output method.

    Make sense?

    Vanilla Forums COO [GitHub, Twitter,]

  • Options
    edited January 2011
    Makes sense. I'll see what I can whip together.

    I'm using Base_Render_Before to do the panel.
    DiscussionController_BeforeDiscussion_Handler to float right in the opening post.
    I haven't figured out the controller for the footer or end of the comments on the page yet.

    Thank you.
  • Options
    I use the plugin. it works okay for me but;
    1. when i submit to twitter its not a text with spaces, it comes with hyphens in between words, instead. hope this is solved this time.
    2. ability to place it by top and bottom of the discussions will be great.

    i am not sure if its as useful on the side bar.
  • Options
    edited January 2011

    1. That's only the URL, or should be, which is correct and does use hyphens, not spaces.
    2. It'll take a little longer for me to have time to make the position selectable.

    This is what I meant by in the sidebar panel.
  • Options
    If there were 6 categories and few bookmarks on side bar the share buttons cannot be seen.

    If share buttons can be placed underneath the discussion topic, sharing can follow just after reading it, the same advantage if it follows the comments

    right sidebar will have very less relevance within a fully running site.

    how about by the left side of 'add comments' link.
  • Options
    edited January 2011
    shah, I agree and I've got a version of this that works in a few different places. I just haven't combined them into a selectable version yet.

    digibomb is writing a Share This plugin soon probably, and it'll undoubtably work much better since he knows his way around the Vanilla code way better than I do.
Sign In or Register to comment.