[Plugin: NextGEN Gallery] Need Direction: Filter Gallery by Keywords
First off, I’m a big fan of the plugin. I’ve used it on a number of projects and its always proved to be one of our client’s favorite features. A little custom styling and jQuery and you have some great user-control carousels and cycles too.
Today I’m looking to find direction on how to extend the functionality of the plugin a little bit.
Here’s what I’m trying to do:
– Create a large photo gallery on a single page.
– Link to the page from another page, passing a keyword in the url.
– Load the gallery page, but only display the images inside the gallery that contain the keyword in their title or description fields.
I know something similar could be done with an album, and links to the specific gallery, but we’re looking to eliminate that process and keep it as a singular gallery that isn’t broken into sections when the viewer accesses the page without using a keyword filter.
The problem is I’m not exactly sure how I should go about it.
Here’s what I was thinking:
– Pass the variable in the url like you do with search …/?s=keyword
– Use PHP to pull the keyword out and put it in a variable
– Update the NextGen loop to check if each photo contains the variable in the innerHTML as it posts it to the page.
– If it doesn’t, add a css class that hides that picture/link.
I’m not sure this is the best way to go about it though. It seems like a lot of potentially unecessary work. Plus it may mean altering NextGen plugin files – which I really don’t like doing. I’ve poked around in the forums, and through the NextGen gallery plugin extensions and haven’t found anything that can give any added direction though.
Thanks for any advice.
- The topic ‘[Plugin: NextGEN Gallery] Need Direction: Filter Gallery by Keywords’ is closed to new replies.