Jump to:

23476 Posts in 18941 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » Toggle dropdown box

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 385 Views
  • michael_geeky
    Community Member
    10 Posts

    Toggle dropdown box Link to this post

    Hi all,

    I am new to SS. I have utilised the existing blog module to manage the blogposts on my site. However, I want to have a dropdown box on the BlogHolder page (list of blogs) where you can select blogs by category. I do not want to touch blog module as it's maintained by someone else, so I want to add another controller action that can be called via Ajax when dropdown box is toggled. So far I have only found extensions that I can add to add more fields to data models, but in this case I don't need to change structure of any blog pagetype. How should I add more controls to existing modules?


  • IOTI
    Community Member
    189 Posts

    Re: Toggle dropdown box Link to this post

    Do you plan on using the already existing tag(s) field as categories or do you want to use a separate managed list of categories?

    If its the latter you could try using a module I made: https://github.com/IOTI/silverstripe-blogcategories. It does not have a built it dropdown for selecting a category on the front end but you could build one yourself. If you don't want or have need of the module you could look at my code and see how i added extra controller actions to the blog holder i.e it uses

    "yoursitelink.com/blog/category/category-name" for filtering blog posts by a selected category.

Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.