Thread tagged as: Question, Problem, Configuration

Filter Dataselect items from other pages

Ok, so I just can't seem to setup the filter I want;

I'm using this tag in my region. It correctly offers a dropdown of content from the region Messages on page /messages.php - all good so far.

<perch:repeater id="pdfsAvailable">
     <perch:content id="message" type="dataselect" label="Message" page="/messages.php" region="Messages" options="text" values="text" help="Select a Message" />

However, when using perch_content_custom() I just can't figure out what kind of filter to apply.

I tried this last;

    $imageLib = perch_content_custom('Image Library', array(
            'filter' => 'pdfsAvail',
            'match' => 'eq',
            'value' => 'Genuine Fuel Pumps',
        'skip-template' => true

I assume what I want is possible, but I just need to set the correct 'filter' value, but I can't form the life of me figure out what it should be. I have seen in runway collections that filters have a '.' between 2 words, possibly I need to do something like that?

Either way, any help would be hugely appreciated, as I find the documentation on filters to be a little bit lacking (it's great, but since you can do a LOT with perch, I more extensive tutorial would be handy).


Matthew Lymer

Matthew Lymer 1 points

  • 5 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

I assume what I want is possible

What are you trying to do?

No worries - I achieved what I wanted using some basic php array filtering (they will be fairly small queries and arrays, so I think the speed drawbacks of doing it this way should be negligible).