Jump to:

3461 Posts in 1065 Topics by 740 members

Data Model Questions

SilverStripe Forums » Data Model Questions » Site search using page tags

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

Page: 1
Go to End
Author Topic: 477 Views
  • NETim
    Community Member
    24 Posts

    Site search using page tags Link to this post


    I have been trying to put together a search system that will search for pages that have been given certain tags.

    The basic principle is that I have a type of page that can have any number of tags applied to it. The tags are controlled through modelAdmin so we build up a list of tags that could be applied to any of the tagable page types. What I am trying to achieve is the ability to search for pages which match all of the selected tags.

    For example:

    We have multiple pages for cars which have tags based on the car they are describing:

    car page 1 tags: Red, 4 wheels, Soft top

    car page 2 tags: Blue, 4 wheels, soft top, fast

    car page 3 tags: Blue, 4 wheels, slow

    on our search page we would have a list of all of the unique tags as checkcboxes so that the user could find a car that matches their needs:

    4 wheels,
    soft top,

    My intention is that if a user searched for the tags Blue and 4 wheels, they would see cars 2 and 3. If they then added 'fast' they should only see car 2.

    Any ideas?



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.