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

suit4’s picture

Does your view create a page or a block?

Nico_0’s picture

a page

Nico_0’s picture

Status: Active » Closed (fixed)

I did not give a title to the view, so I did not see it in the list....

jan2004’s picture

the 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

jan2004’s picture

Status: Closed (fixed) » Active

can anybody help?

suit4’s picture

Did 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?

NewZeal’s picture

It 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...

tommo’s picture

I 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').

tommo’s picture

Perhaps altering: ln 35 taxonomy_menu.inc

$views_list[$view['name']] = $view['page_title'];

to

$view['page_title'] != '' ? $views_list[$view['name']] = $view['page_title'] : $views_list[$view['name']] = $view['name'];
fallsemo’s picture

Thanks 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?

summit’s picture

Subscribing, greetings, Martijn

KrisBulman’s picture

subscribing, same thing here

bneel’s picture

the answer si here : http://drupal.org/node/274009

westbywest’s picture

Subscribing

NewZeal’s picture

Status: Active » Fixed

Both these issues fixed in 1.04

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.