[support] Using Views to find "content created by user from same town as viewing user"

Neil Coghlan neil at esl-lounge.com
Fri Nov 19 22:17:01 UTC 2010


I've actually managed to do half of this already. I have a content type 
that I use as a profile which included the taxonomy vocabulary 
"location". Each user chooses a country.

I now have two views called "local content" and "local users". The first 
shows all content across the site that also shares the same taxonomy 
term and the second view shows all other users who share that same 
taxonomy term. Both use default arguments injected into the view by php 
code (an sql query)

Now I'd like to create a final view where a user who has filled out a 
profile can see content created by other users who share the same 
taxonomy term - a sort of hybrid of the two I already have.

I can't see how I could use arguments for this one...it seems more 
likely I'll have to play around with filters, but how can I use php/sql 
in filters?

Has anyone else managed to do this type of thing with Views?

Neil


More information about the support mailing list