Custom hardcoded search

Hello.

In one of my projects I'm trying to customize printAlbumMenu function to print only albums tagged with tag "menu".

I use this code
`

$searcher=new SearchEngine();

$searcher->setSearchParams(urlencode("menu"));

$albums = $searcher->getSearchAlbums();

`

I have two dynamic albums tagged with "menu", but $albums array comes out empty. Did I miss anything here?

Thanks,
Alexey

Comments

  • I think you need to specify the search params as a URL-encoded string - instead of urlencode("menu"), I think you need urlencode("searchfields=menu").
  • altert Member
    thanks. Tried also "words=menu" but no luck so far
  • Oops, I meant "searchfields=tags&words=menu".
  • altert Member
    ok, thanks. That didn't do the trick either, but I've found another way to do what I wanted, using dynamic albums as subalbums
Sign In or Register to comment.