Closed (fixed)
Project:
Taxonomy Menu
Version:
5.x-1.03
Component:
User interface
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
15 May 2008 at 14:05 UTC
Updated:
29 May 2009 at 04:20 UTC
I created a custom view which I would like to use with taxonomy menu.
But when I look under "Views available:" in the taxonomy menu admin pages I don't see my custom view.
What am i doing wrong?
Comments
Comment #1
suit4 commentedDoes your view create a page or a block?
Comment #2
Nico_0 commenteda page
Comment #3
Nico_0 commentedI did not give a title to the view, so I did not see it in the list....
Comment #4
jan2004 commentedthe same by me. mutch of views - but dont display in a list avaible views. how to make my views display in a list?
thanks
jan
Comment #5
jan2004 commentedcan anybody help?
Comment #6
suit4 commentedDid you give your view a title? And does it provide a block or a page?
Did you try to clear the views cache via admin/build/views/tools?
Comment #7
NewZeal commentedIt appears that the selected view is not being saved however it does. The problem with having select by view name is that if your view uses arguments then it cannot appear on this selection list and of course arguments are essential for a selection to be made.
Later: Problem solved: In taxonomy_menu.inc the view is accessed by $view['page_title']. Change this to $view['name']. Note that the default views are accessed via name.
// Get the list of User generated views
$views = db_query("SELECT * FROM {view_view}");
while ($view = db_fetch_array($views)) {
$views_list[$view['name']] = $view['name']; <-HERE
}
// Now get a list of default Views
foreach (_views_get_default_views() as $view => $viewdata) {
$views_list[$view] = $viewdata->name;
}
}
Now all that is needed is to understand how to use arguments to create the required effect. Simply selecting taxonomy TermID gets a listing of all terms no matter how deep you go. Watch this space for updates.
Later: Understanding reached. Isn't trial and error a great thing?
To successfully create a custom view you need to add TermID as an argument repeatedly. For a 3 level url like Locations/1/2/3, I needed to do it twice, one for arg(2) and one for arg(3), I guess, or maybe its arg(1) and arg(2). This will get a view of the categories in term 3. To ensure a view of do categories in Term 2 (url Locations/1/2) select Display all values or Summary or somesuch in the Default box.
More testing to come...
Comment #8
tommo commentedI spotted the view['page_title'] in the taxonomy_menu.inc too, I was having the same problem. It would make sense to alter this to view['name'] permanently as every view will always have a name but it's quite often the case that the 'page_title' is omitted. (or maybe have a conditional that checks to see if 'page_title' is set and if not use 'name').
Comment #9
tommo commentedPerhaps altering: ln 35 taxonomy_menu.inc
to
Comment #10
fallsemo commentedThanks tommo for this!
My custom views show up on the list now but when I select the one I want and submit, It doesn't save the setting and the "Views Available" drop down list shows a different view - not the one I selected.
I am using the newest version of the module ... something I'm doing wrong here?
Comment #11
summit commentedSubscribing, greetings, Martijn
Comment #12
KrisBulman commentedsubscribing, same thing here
Comment #13
bneel commentedthe answer si here : http://drupal.org/node/274009
Comment #14
westbywest commentedSubscribing
Comment #15
NewZeal commentedBoth these issues fixed in 1.04