I am creating a review site that will have somewhere around 80 different categories. Each review will contain a CCK field called "category" where I will select how the review should be categorized. For a test I created a views page to display nodes with the cck field "category" that equals "computers". This works great for showing all of the reviews for that category, but I don't want to create 80 instances of that view. I was hoping that there was a way of executing an argument to re-use the same view based on the URL.
So for example:
?q=categories
would be the base link to the view
?q=categories&cat=computer
would display the view showing only nodes with a category field of "computer"
Does anyone have the answer to this situation?
Comments
Comment #1
pkej commentedLook into arguments. search google for views, drupal, arguments
Comment #2
nevets commentedProbably easier if you use taxonomy for categorizing, but the concept should be the similar. First think in terms of the views path (in this case 'categories' and the argument added as categories/computer where 'computer' is the argument. When edit the view you can argument handlers.
Comment #3
shadow_jh commentedThanks, this was a big help. Im not sure why I overlooked taxonomy!
Comment #4
farald commented