Are business directories possible in drupal?

They have: 18 posts

Joined: Feb 2009

I've been using drupal for all recent web projects and I've found it's suitable for almost everything. So when I came to set up a business directory last week, I assumed it would be straightforward - I even had a mental blueprint of the view I would set up for the taxonomy terms. But in the end it turns out to be difficult in the extreme. The drupal forums are bursting at the seams with questions about Business Directories, but without any solutions. Google search draws a blank, there is no useful guidance or information anywhere. Experiments wth modules lead to dead-ends and chronic frustration. This is one common task too hot for views to handle. The node view, which would leave room for a node attachment, only renders a duplicate term for every node categorised with that term and 'Distinct' doesn't help.

All I want is a category index in a block at the top of the page with entries listed beneath.

So I turned to panels, in the hope of a workaround. Then ran into trouble when I couldn't make the panel apply to all pages along one particular path. Only the index page worked. Pages deeper than that opened as normal pages with no panels and so no category index or second view I had made for the listings (with the taxonomy: term argument to pull out the appropriate category).

I've toyed with every option and every function. I've posted questions in the drupal forum, all of which are ignored, and through the drupal business directory group run into another poor sod who's been working fruitlesly at this for weeks.

So in desperation, I'm throwing myself at the mercy of everyone here. I am sure you've all got better things to do, but I'm equally sure there are members here with enough expertise in drupal to clarify once and for all whether or not it's possible to build a functional business directory like this with drupal, without having to write PHP.

Can it be done? Am I missing something simple?

All the best.

JeevesBond's picture

He has: 3,956 posts

Joined: Jun 2002

Doesn't look like you're having much luck, generally if no-one answers your questions it means they don't have the answers. Sad

It's possible to make Panels override system default pages, use Panels 3 and select the 'Or customize a system page...' option at the bottom of the admin page. I'd do it by overriding 'Taxonomy term view', although Panels isn't going to help if your underlying View isn't working.

This might make you sick, but I just got it to work on Drupal 6 with Panels 3 and Views 2. Although Panels 3 seems little buggy in places, once you get something working it seems to stay that way. Smiling

Try importing nodes_by_tax.txt and taxonomy_terms.txt into Views and panel_taxonomy_view.txt into Panels to see what I did (note: it's very rough).

Once you've imported those, go to example.com/taxonomy/term/1 and the Panel will take over. Note: you could make that URL your site's home page, to make things easy.

It is of course possible that you've been there and tried what I just did, in which case let me know exactly what happens -- and roughly why, if you can.

a Padded Cell our articles site!

They have: 18 posts

Joined: Feb 2009

Thanks so much Jeeves - I really appreciate the trouble you've taken. I'll test it out when I'm in front of my production machine tomorrow morning and let you know how I get on. If it worked for you I'm optimistic. Cheers! Smiling

JeevesBond's picture

He has: 3,956 posts

Joined: Jun 2002

Well, let's hope so! There may well be something about how you've got your site set up that I'm not taking into account... Difficult to predict. Smiling

They have: 18 posts

Joined: Feb 2009

It works!

I mistakenly tried importing panel_taxonomy_view as a custom panel rather than a task handler - and could have wailed until I realised my mistake. Smiling

One question, how did you generate the arguments in the 'summary of contexts'? Argument 1 in particular is quite busy - but clicking on 'add context' there doesn't seem to be the options to generate that amount of detail. Does it pull in data from the view?

Thank you so much for settling this question for me. You're the man.

JeevesBond's picture

He has: 3,956 posts

Joined: Jun 2002

I mistakenly tried importing panel_taxonomy_view as a custom panel rather than a task handler - and could have wailed until I realised my mistake.

Wow, I never would have guessed the import routines were in different places in the interface. That's a nasty problem.

One question, how did you generate the arguments in the 'summary of contexts'? Argument 1 in particular is quite busy - but clicking on 'add context' there doesn't seem to be the options to generate that amount of detail. Does it pull in data from the view?

I didn't! Panels automatically did that stuff because it realised we were overriding the taxonomy term page.

Glad it fixed the problem for you. Smiling

a Padded Cell our articles site!

They have: 1 posts

Joined: Aug 2009

Hi and thanks for this info on setting up a business directory. Could you please give instructions on how to import panel_taxonomy_view as a task handler - I've been trying to find out where for the last hour without much luck Sad Tried latest recommended versions as well as dev versions of panels/views/ctools.

Many thanks in advance...

They have: 1 posts

Joined: Jul 2009

I've followed this group for awhile, because I have created a lot of business directories outside of Drupal, and have wondered if it could be done easier and quicker within Drupal and it's vast amount of contrib modules. Well, I think it can, now that I do 90% of website development work in Drupal.

They have: 18 posts

Joined: Feb 2009

Hi ghaugen, I'm sorry I haven't seen this sooner!

Panels was updated soon after I posed my question, and the changes in the new version are sweeping. 'Variants' can now be added to task handlers, making them significantly more versatile. Unfortunately I would guess this probably breaks the code Jeeves Bond generated. I'll investigate this evening and get back to you.

Victor, you've deleted your question, but here's an answer anyway. Business directories are very easily pulled off in Drupal - and they can take any shape or format and follow any logic you desire. Development can also be tremendously fast - but there are many blind alleys that can cost tremendous amounts of time and frustration. A guide to making a business directory in drupal would need to focus almost as much on courses to avoid as courses to follow. When I have more time, I'll list a few of these wild geese you mustn't chase.

They have: 1 posts

Joined: Apr 2012

Hi

This is a long time since, but check this out: http://drupal.org/node/1435330

Here is the site: http://www.webnetwork.com.au

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.