Filter field mapping


Thanks….



I'll clean it up.
Here's an example I just tested:
m_username=Their Username,Interests=Their Interests
Comma-separated lists of something=somethingElse. Where something is either a f_members column name or the title of your CPF, and somethingElse is just the label you want on the filter.
Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon
- If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
- If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
- If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
- If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.


Yes, I can see where your example above works but I tried all of these:Chris Graham said
Here's an example I just tested:
m_username=Their Username,Interests=Their Interests
Comma-separated lists of something=somethingElse. Where something is either a f_members column name or the title of your CPF, and somethingElse is just the label you want on the filter.
From “Post #6,695”, 12th May 2020, 3:33 am
State=State
Address: State=State
cms_state=State
field_32=State
and all returned: Unknown field xxxx. Skipping filter for this field.


32=State
Sorry this is a tricky case. field_32 should have worked but there's a bug. In the ideal world "Address: State" would also have worked except the colon messes up the Filtercode syntax being used internally.
Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon
- If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
- If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
- If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
- If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.


Chris Graham said
This should work:
32=State
Sorry this is a tricky case. field_32 should have worked but there's a bug. In the ideal world "Address: State" would also have worked except the colon messes up the Filtercode syntax being used internally.
From “Post #6,698”, 12th May 2020, 4:53 am
Perfect! Does the job….



I currently have this filters_row_a="36=Last name (at HHS),m_username=Username,usergroup=Usergroup" in the main_members block and it works great. I've not been able to figure out the syntax for accomplishing the same thing via editing the CNS_MEMBER_DIRECTORY_SCREEN.tpl file. Suggestions appreciated.
Thanks...


{$BLOCK,block=main_members,block_id=md,max={$CONFIG_OPTION,members_per_page},sort={$CONFIG_OPTION,md_default_sort_order},display_mode=listing,filters_row_a=36=Last name (at HHS)\,m_username=Username\,usergroup=Usergroup}
Or you can do…
Code
{$COMCODE,your regular block Comcode goes here}
The latter isn't ideal though as it has to load up the Comcode parser on every page view.
Become a fan of Composr on Facebook or add me as a friend. Add me on on Mastodon. Follow me on Minds (where I am most active). Support me on Patreon
- If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
- If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
- If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
- If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.


Perfect….I figured it needed some kind of escape sequence but couldn't figure it out. Works great. Thanks…Chris Graham said
Try:
{$BLOCK,block=main_members,block_id=md,max={$CONFIG_OPTION,members_per_page},sort={$CONFIG_OPTION,md_default_sort_order},display_mode=listing,filters_row_a=36=Last name (at HHS)\,m_username=Username\,usergroup=Usergroup}
Or you can do…
The latter isn't ideal though as it has to load up the Comcode parser on every page view.Code
{$COMCODE,your regular block Comcode goes here}
From “Post #6,807”, 13th June 2020, 4:57 pm