Fork me on GitHub
Current releases are 2.1 (gold) and 2.0.18.11 (security patch for 2.0)
Ready for 2.1? Find out if your favorite plugins are compatible.
The 2.0 branch will no longer receive updates after Dec 2014.

Vanilla developer kickstart

6apxat6apxat New
edited March 2013 in Questions

Hi. First of all I want to thank Vanilla team and the community for great work on this project. Vanilla finally brings common sense to forum software and it's exactly what forum should look like.

However the problem that we encountered during the work on our project was lack of full documentation for developers.

We're currently building an online social game community and need to develop a custom theme for our forums and also add some custom functionality which is not included in the basic package or plugins. Our team didn't find the required information in the documentation area so we had to purchase a few custom premium themes to disassemble them and see how they're made. Basically we're now reading the source code and trying to figure out how things work.

My questing for the team and dev community is how does a vanilla developer get started?

Where to refer when basic CSS editing is not enough?

Any tips would be appreciated. Thanks!

UnderDog

Best Answers

  • whu606whu606 I'm not a SuperHero; I just like wearing tights... Moderator
    edited May 2012 Answer ✓

    Have you checked through this:

    http://vanillawiki.homebrewforums.net/index.php/Main_Page

    I've made css changes to my theme for the most part, with a bit of php fiddling thrown in.

    I think taking something that works and adapting it to your needs is pretty much the way most Vanilla developers have gone about things.

    UnderDogchinacode
  • Answer ✓

    Yeah, I know, I just wonder how "stuff that works" was made.

    @6apxat,

    I've also had some challenges with the documentation. The Wiki referenced above is a nice start, but there's still not much available there. One thing I suspect is happening is that a handful of developers have worked long and hard developing their niche of expertise, and have built a cottage industry around "premium" flavors of Vanilla. I also think Vanilla is putting a lot of effort into its hosting and wants more people to move that way. Unfortunately, both of these "trends" (if they are really happening) could destroy an awesome Open Source platform and community.

    Vanilla isn't my "core business", so if you have any questions about how to do something specific, feel free to @ me in your post or message me directly. I'm not ten percent as knowledgeable as @x00, @Mark, and a dozen others here, but I've been hacking away at Vanilla for more than a year now.

    I may have enough notes to do a "How to Get Started Hacking Vanilla" presentation. It might even be fun!

    UnderDogfh1116apxat
  • peregrineperegrine ☯ hasta luego :) In-Flight MVP
    edited May 2012 Answer ✓

    6apxat said: Drop it guys, let's just focus on the discussion:>

    I did drop it. I said I was dropping it.

    So yeah, the Wiki has some basic information on how to get started with plugin development and even write a simple HelloWorld plugin :) It also describes some fundamentals (like routing, controllers etc.) which might help understand the whole Vanilla architecture. But still there's much mystery about this (even though I'm quite familiar with MVC architecture).

    1) How do I know the correct event function names (e.g. DiscussionsController_AfterDiscussionTitle_Handler) to include inside my plugin? Where's the list of all of them?>

    grep -r FireEvent *

    2) A deeper understanding of the $Sender concept is needed and how to pass data between controllers.>

    var_dump($Sender);

    3) A comprehensive list of Garden functions is required (to know for example, how Gdn_Format::Url() works).

    http://www.vanilla-wiki.info/vdocs/annotated.html

    If you find any of these answers useful - feel free to add them to the wiki - if you want to add to the wiki - maybe create How To Get Started Title - and maybe people will add to it.

    Monetary Donations will be appreciated if you use my plugins. Thanks in Advance.
    As a waiter gets a tip for a good meal, tips for successful solutions appreciated as well. Peregrine

    UnderDog6apxat
«1

Answers

  • 6apxat6apxat New
    edited May 2012

    Hey, thanks for the reply.

    Yeah, I know, I just wonder how "stuff that works" was made.

    UnderDogCurtisOden
  • UnderDogUnderDog Moderator

    Anything you find, please add it to the Vanilla Wiki.

    Make a start page and document all the things you needed. We'll help you find the information as long as you want to document it.

    6apxat
  • UnderDogUnderDog Moderator

    What I don't understand is the following:

    You guys are working at a Vanilla site. You are wondering things, so look in the documentation (Wiki!). Something is missing, meaning the documentation is lacking.

    Why on earth aren't you adding that to the Wiki?

    Maybe this thread isn't the right place to ask this, but it's a start and we might split the thread if necessary.

    Just add a piece of text to the Wiki that you're missing documentation on... and ... (maybe add it to the forum as well). Someone will have the answer and add your answer to the Wiki. That's the exact functionality of the Wiki. Anyone can join, so that won't have to be a problem. Anyone can type their question (and hopefully their solution), so that won't have to be a problem either.

    It's nice that @CurtisOden has his notes, but if you want to share them, I think the Wiki is the right place to share those notes.

    6apxat
  • @UnderDog try googling "vanilla forums custom theme" (probably first thing every new developer does after looking through the documentation), the Wiki mentioned above is not among first 20 results and those results themself are not too helpful.

    I think most fresh devs like me are looking for some kind of "recipes" or step-by-step guides.

    UnderDog
  • 6apxat6apxat New
    edited May 2012

    Maybe the reason for the lack of information is that Vanilla is quite a young project.

    I agree that we should share knowledge, as it can really stimulate the popularity of the product.

  • @UnderDog

    I'm happy to add to the Wiki, but does it really need comments like:

    • If you're building your own theme, don't. Steal, borrow, or exercise some Open Source license on a theme you like that's structurally close to what you want to do. Use Find/Replace (at least in Dreamweaver) to change all instances of the theme name. And don't forget to rename any files that contain the them name. Oh, don't forget to give yourself credit for your new awesome theme in the "about.php".

    • Smarty is a pain in the (self censored) for PHP developers (even if some designer somewhere said he/she loves it). When building your own custom theme, delete deafault.master.tpl from your theme's "views" directory and replace it with a copy of default.master.php (found in the "/[your-vanilla-root]/applications/dashboard/views" directory)

    • Vanilla's stylesheet "strategy" can get messy fast. Create a "custom.css" in the "[your-theme]/design/" directory. As you modify classes, copy the whole class you want to use from "/[your-vanilla-root]/applications/dashboard/design/style.css".

    • When trying to build a simple plugin on a tight deadline, sometimes it's easier just use ten lines of PHP to query the database and echo the results where your want them, rather than using a few hundred lines across several files to build to MVC design patterns.

    • Milk and popcorn don't go together, but chocolate milk and Cracker Jacks do.

    • If you can't figure out where the (self censored) Vanilla is adding a particular element (embedded deep within a module, inside of an enigma, wrapped in a mystery), don't be afraid to commit CSS assassination (visibility: hidden !important). Just remember to come back to it once you've done your product demo.

    If these kind of notes belong in the Wiki, I'll be happy to drop them in today!

    UnderDog
  • peregrineperegrine ☯ hasta luego :) In-Flight MVP

    I offered to do a step by step - but it requires some work by the user.

    see: http://vanillaforums.org/discussion/20160/ignore-discussions#latest

    surprisingly or not so surprisingly - the person on the other end didn't have time - which is a valid reponse - the other person on the other end - said "nowhere near that organized"

    this would have been a kickstart. I am nowhere as adept as x00 and a lot of other here but the plugins do end up working and not crashing and burning your system (at least I haven't seen any comments that indicate so).

    My gut feeling is alot of questioners don't really have the time to invest in learning, they want it to appear by magic, or by someone else's sweat.

    Monetary Donations will be appreciated if you use my plugins. Thanks in Advance.
    As a waiter gets a tip for a good meal, tips for successful solutions appreciated as well. Peregrine

    UnderDog
  • 6apxat6apxat New
    edited May 2012

    @peregrine of course we all have deadlines :)

    I agree that any product requires that you invest some time in learning it. But let's face it: for many devs building a forum isn't a typical daily routine. I personally come from a frontend world and I feel that my programming skills might not be deep enough to use Vanilla's advanced features. This is where a little help would be useful.

    I mean it's not a bad thing to expect the software to be easy to use. For example Wordpress or Drupal appear more friendly to new developers. With Vanilla as @CurtisOden mentioned above it's more "hacking" than "building from blocks".

  • peregrineperegrine ☯ hasta luego :) In-Flight MVP

    For example Wordpress or Drupal appear more friendly to new developers Wordpress is harder to write a plugin than vanilla in my opinion. so I would say vanilla is easier for developers. however, it is easier to drag boxes in wordpress, but i wouldn't call that developing that's end-user stuff.

    So, in wordpress lets say I want to build a form and write to the database and do someother thing that a lot of users request here - it is just as hard if not harder in wordpress, not to mention the insane way of executing php in wordpress.

    Monetary Donations will be appreciated if you use my plugins. Thanks in Advance.
    As a waiter gets a tip for a good meal, tips for successful solutions appreciated as well. Peregrine

    altious
  • @peregrine Maybe you're right. Can't say exactly as I've never developed any plugins for wordpress. At least I've had an impression that it was well documented and if I had to, I would be able to.

    I'm going to post a topic soon where I'll describe my current task and I hope I'll get some directions on that :)

  • UnderDog said: What I don't understand is the following:

    You guys are working at a Vanilla site. You are wondering things, so look in the documentation (Wiki!). Something is missing, meaning the documentation is lacking.

    Why on earth aren't you adding that to the Wiki?

    Well, there's a bit of a catch-22 there. If you're looking for an answer to a question, you need information, and don't have something to show other people, kind of by definition. So going to the wiki or here to look for something means that you don't really have information to add. I mean, I understand what you're saying about adding a stub to the wiki, but, for me at least, it's often the case that I not only don't know how to do something, I'm not exactly sure how to get started, and wouldn't know what kind of stub or where to add to the wiki. Kind of a waste of everyone's time, and I worry that things like that would degrade the usefulness of the wiki for everybody, and make more work for people who then have to go in and clean up.

    That said, I will try in future, personally, to add things to the wiki if I have potentially useful things to add.

    In terms of Wordpress, I've been developing on WP for years, slightly longer than I've been working with Vanilla, building custom plugins and themes and all the rest, and perhaps it's me, but I find it extremely easy to work with compared to Vanilla -- that may be familiarity more than anything else, perhaps, and the huge number of code examples available all over the web, as well as the relatively comprehensive documentation available. But regardless of the reason, whenever I dive in to the guts of Vanilla, I tend to come away utterly mystified and frustrated. So it goes, though. It's all opinions at the end of the day.

    peregrine said: My gut feeling is alot of questioners don't really have the time to invest in learning, they >want it to appear by magic, or by someone else's sweat.

    That's pretty unfair to a lot of people. This is the kind of snide, unnecessary comment I've mentioned seeing too often before, here (and it's particularly annoying because it is apparently at least partly directed at me, despite my attempts to be friendly about it despite your rather preremptory statement of your 'terms'). That sort of thing isn't helping anyone. Also, if you're going to talk about me in threads I'm not participating in, a courtesy @ mention would be appreciated. Thanks.

    UnderDog
  • 6apxat said: Maybe the reason for the lack of information is that Vanilla is quite a young project.

    Not so much, actually, although the 2.x Monster Rewrite is only, what, a couple of years old now?

    I've been running a fairly busy site on Vanilla 1.x (and am here these days trying to find solutions to issues related with moving to 2.x and preserving user-expected functionality, because it seems like 2.x is getting close to being able to do that now, without too much pain in the process) since I think 2007. So, yeah, Garden is relatively young, but Vanilla itself has been around in its various incarnations for a fairly long time in Internet Years.

    UnderDog
  • peregrineperegrine ☯ hasta luego :) In-Flight MVP

    peregrine said: My gut feeling is alot of questioners don't really have the time to invest in learning, they >want it to appear by magic, or by someone else's sweat.

    That's pretty unfair to a lot of people. This is the kind of snide, unnecessary comment I've mentioned seeing too often before, here (and it's particularly annoying because it is apparently at least partly directed at me, despite my attempts to be friendly about it despite your rather preremptory statement of your 'terms'). That sort of thing isn't helping anyone. Also, if you're going to talk about me in threads I'm not participating in, a courtesy @ mention would be appreciated. Thanks.>

    @stavthewonderchicken Buddy, "you've got a chip on your shoulder." Tell you what this is directed to you, but I will not reply to you or mention you again, If you want to do like wise - feel free. I'm finished responding to you, so don't expect one. If they put ignoreuser plugin on this site - you would be the one I would add to it. No offense, just the way it is.

    Monetary Donations will be appreciated if you use my plugins. Thanks in Advance.
    As a waiter gets a tip for a good meal, tips for successful solutions appreciated as well. Peregrine

    UnderDog
  • edited May 2012

    That's just worryingly weird, man. Really. But: fair enough. I appreciate your slightly-demented honesty, but am bewildered by your over-the-top aggro.

    I mean, you really did specifically mention me in that comment, so I'm not sure how I have a chip on my shoulder.

    surprisingly or not so surprisingly - the person on the other end didn't have time - >which is a valid reponse - the other person on the other end - said "nowhere near that >organized"

    Heck, I was just being honest -- I'm not that organized. You can say whatever you like about me, that's cool, but painting other users with a broad brush, that they 'want [things] to appear by magic, or by someone else's sweat', you know, that's not so cool.

  • 6apxat6apxat New
    edited May 2012

    Drop it guys, let's just focus on the discussion:

    So yeah, the Wiki has some basic information on how to get started with plugin development and even write a simple HelloWorld plugin :) It also describes some fundamentals (like routing, controllers etc.) which might help understand the whole Vanilla architecture. But still there's much mystery about this (even though I'm quite familiar with MVC architecture).

    For example, disassembling a simple plugin Front Page Discussion Pagination by @stavthewonderchicken I've noticed some dark spots which aren't just described anywhere:

    1) How do I know the correct event function names (e.g. DiscussionsController_AfterDiscussionTitle_Handler) to include inside my plugin? Where's the list of all of them?

    2) A deeper understanding of the $Sender concept is needed and how to pass data between controllers.

    3) A comprehensive list of Garden functions is required (to know for example, how Gdn_Format::Url() works).

    UnderDog
  • 6apxat said:

    A comprehensive list of Garden functions is required (to know for example, how Gdn_Format::Url() works).

    This is EXACTLY what is needed. In the Documentation, all of the developer documents seem to be abstracts of what a larger chapter should be discussing. Is someone at Vanilla writing a book and just holding out on us?

    Oh, I hat being so cynical, especially about the best Open Source (or black box) forum platform I've found.

    UnderDog
  • peregrineperegrine ☯ hasta luego :) In-Flight MVP

    glad you "liked it"

    Monetary Donations will be appreciated if you use my plugins. Thanks in Advance.
    As a waiter gets a tip for a good meal, tips for successful solutions appreciated as well. Peregrine

  • UnderDogUnderDog Moderator
    edited May 2012

    6apxat said: I've noticed some dark spots which aren't just described anywhere:

    I love your humor!

    1) How do I know the correct event function names (e.g. DiscussionsController_AfterDiscussionTitle_Handler) to include inside my plugin? Where's the list of all of them?

    http://vanillawiki.homebrewforums.net/index.php?title=List_of_Functions&action=edit&redlink=1 (yes, it's an empty page, just fill the page after the list is found)

    2) A deeper understanding of the $Sender concept is needed and how to pass data between controllers.

    3) A comprehensive list of Garden functions is required (to know for example, how Gdn_Format::Url() works).

    We have 2 pages regarding functions and classes:

    Functions:
    http://vanillawiki.homebrewforums.net/index.php?title=List_of_Functions&action=edit&redlink=1

    Classes: http://vanillawiki.homebrewforums.net/index.php/Classes

    I think all I can say is : The VanillaWiki is all that we have. We can generate documentation from the sourcecode (phpdocumentor, doxygen?) and dump it in the Wiki, problem is it gives a lot of extra HTML which needs to be stripped first, no real converter available.

    I would love it if everyone would join the Wiki and Pitch in where he can.

    @CurtisOden Yes, please create a Wiki page with the interesting points you've listed.

    Just make up a nice page title like : Custom Theme Start Page (or something more appealing to the eyes)

    This is the link I always go to:

    http://vanillawiki.homebrewforums.net/index.php/Main_Page#The_Ultimate_Theme_Guide_for_Designers (but that's on the main page, I sense we need a special sub-page to send our users to)

    All the information on the Wiki Pages that is missing will get a red link I hope you understand what I mean by that. If not, just look at the Classes page :-) . Anyone who can fill the 'red link' pages with sensible information will be my personal hero.

    Olivaw
  • qwentyqwenty New
    edited May 2012

    whu606 said: Have you checked through this:

    http://vanillawiki.homebrewforums.net/index.php/Main_Page

    Laughing address! The address can kill the project! Why not a straightforward one, as in:

    www.vanillaWiki.com

    www.VanillaDocs.com

    ...

    If I were you, i didn't work at all on such rigmarole sub-domain! but on a beauty one, actually YES :)

    And it needs more thought, choosing the right wiki cms: MediaWiki? DukoWiki? github service? ...

  • UnderDogUnderDog Moderator

    My 2 cents : it's an intermediate work-in-progress Wiki. It needs to be merged with the real www.vanillaforums.org site anyway. We can work on any Url we like, but the work needs to be done. CSS specialists work on the Theming side of the VanillaWiki site. Programming specialists find all the functions in Vanilla using grep and someone needs to decide whether we scan the current source with phpdocumentor or whether we first update the source and then scan it.

    peregrine
  • hbfhbf wiki guy? MVP

    qwenty said:

    whu606 said: Have you checked through this:

    http://vanillawiki.homebrewforums.net/index.php/Main_Page

    Laughing address! The address can kill the project! Why not a straightforward one, as in:

    www.vanillaWiki.com

    www.VanillaDocs.com

    ...

    If I were you, i didn't work at all on such rigmarole sub-domain! but on a beauty one, actually YES :)

    And it needs more thought, choosing the right wiki cms: MediaWiki? DukoWiki? github service? ...

    @qwenty You want to pay to register the dns? Im hosting it for free to the community, why should i pay for a new domain? Especially when folks like yourself arent even willing to put in the effort to create a page. Makes little sense to me how you could be so critical, ive seen your contributions.

    Its hosted using media wiki... why? Its scalable and familiar to most people. If you would like to put more thought into it go ahead.

    UnderDog
  • qwentyqwenty New
    edited May 2012

    Its hosted using media wiki... why? If you would like to put more thought into it go ahead.

    MediaWiki is ok, If I were, it was at top of my list.

    http://vanillawiki.homebrewforums.net/index.php/Main_Page Is this domain memorizable? Is this short & upstanding? ...

    qwenty said:

    And it needs more thought, choosing the right wiki cms: MediaWiki? DukoWiki? github service? ...

    It should start as an official work, not as fun on a sub-domain of a disjointed domain. (irrelevant to Vanilla)

    My intention:

    1. pre-hypothesis: Users wants to ground up a wiki on a good domain.

    THEN:

    1. Teamwork: gathering volunteers 2. solving host problem {who want(s) to pay for that?} 3. Choosing a charmer domain 4. choosing the best cms for wiki 5. ...

    Its scalable and familiar to most people

    +1

    this is my intention, different idea for brain storm!

    hbf said:

    @qwenty why should i pay for a new domain?

    It was my opinion. you have your idea, third party has his/her idea! :-)

    In my opinion a straightforward domain name will help more! even a free on can be better: www.VanillaDocs.tk (.co.cc, ...).

    Especially when folks like yourself arent even willing to put in the effort to create a page.

    Folks? It should be a team-work by staffs. Am I a Vanilla expert? Today I'm just a newbie! do you now how many days I'm familiar to Vanilla?

    Maybe tomorrow... If I try to learn as much as possible.

    ive seen your contributions.

    For example?

  • hbfhbf wiki guy? MVP

    qwenty said:

    ive seen your contributions.

    For example?

    my point exactly.

    as for the domain name:

    register a better domain name and have it redirect to my site if you want a cleaner URL. Like i said, i'm hosting it out of my domain/server as a service to everyone here. I've offered to package the whole thing up and hand it over to the vanilla core team any time they want to re-host.

    but if the domain name is why you think that people should not contribute to the wiki then im saddened by your complete lack of appreciation for what i and other people around here are trying to do for the community.

    You can't rely on the core team to take care of everything.

    UnderDog
  • peregrineperegrine ☯ hasta luego :) In-Flight MVP

    I honestly think she means well. I think and hope she will produce something comprehensive when she is ready.

    @hbf - Thanks for all of your work in setting the wiki up.

    Monetary Donations will be appreciated if you use my plugins. Thanks in Advance.
    As a waiter gets a tip for a good meal, tips for successful solutions appreciated as well. Peregrine

    UnderDogqwenty6apxat
  • UnderDogUnderDog Moderator

    qwenty said: It should be a team-work by staffs.

    We are the staffs. The community is. We can use all the help we can get (volunteers, yes). I understand that you say that you are a newbie, but we even could use your help.

    Would you like to help?

    Step 1 is for every time you wonder something and you cannot find it on the current Wiki, just add a page with the thing you're wondering.

    Step 2 is browsing the Wiki for information that needs adding. I know that you're a CSS expert, so look at the CSS pages. Do they need work?

    Step 3 is look for all the unanswered pages (red links) and see if you can add information

    Step 4 is transfer content from the actual forums of VanillaForums.org to the Wiki. Hint : I've been adding [Documentation] prefixes and 'documentation' tags to every discussion that ended in showing an answer to the user that had a question PLUS that was documented enough to put on the Wiki.

    Who else can help?

    qwenty
  • qwentyqwenty New
    edited May 2012

    UnderDog said:

    Hint : I've been adding [Documentation] prefixes and 'documentation' tags to every discussion that ended in showing an answer to the user that had a question PLUS that was documented enough to put on the Wiki.

    You solved one of my question: how [Documentation] prefix is added to some discussion?

    you do that manually by editing the first post? (respectable)

    Isn't better to create a new category called "Wiki candidates", then moving these discussion into it?

    You can't rely on the core team to take care of everything.

    right!

    if the domain name is why you think that people should not contribute to the wiki then im saddened by your complete lack of appreciation for what i and other people around here are trying to do for the community.

    @hbf

    Misapprehension! I never said that, did I? this is my phrase: If I were you, i didn't work at all on such rigmarole sub-domain! but on a beauty one, actually YES

    It was a suggestion for getting a bare domain. However, your work is really worthwhile.

«1
Sign In or Register to comment.