0

Taxonomy page will have sidebar which will have taxonomy menu items and grid layout with image and brief details.

For example, taxonomy items have brand by certain names, price range, etc. User click on brand name, the grid layout will auto load the brand products without have going to /products/brand_name. On page, it will be /products, and then every brand name will show different products automatically loading on same page.

Is there such a way to do this? Or there is a module which can do that?

Example I found is http://www.cynosure.com/products/

Click on any from menu on left column, you will see the products reloaded by menu click.

0

This can be achieved using exposed filters feature of the Views module. Here is an article explaining this process in detail.

http://www.bryanbraun.com/2013/08/06/drupal-tutorials-exposed-filters-with-views

You would also need the Better Exposed Filters(BEF) module for displaying the filters as links.

  • thanks. so it will work with menu together? or I can use taxonomy menu block in the left column while in right column use view? – joe Mar 24 '15 at 14:10
  • The left part is the exposed filter of the view and right part displays the results. There is no menu or menu block required. Add your taxonomy term fields as filters and expose them to the users. Using BEF module display the filters as menu/links instead of a select box. – Bhuvana Mar 25 '15 at 4:21
  • tried BEF but couldnt find "menu/link on BEF" - where do you see that? – joe Mar 26 '15 at 16:02
0

Views module will do this for you. If the items in the column is limited and you know what they are, you can create different pages for every one, each page indicates certain filtering. but you need Ajax call to load information in the same page. if your View name is product and then you need some thing like this

        $.ajax({
            url: Drupal.settings.basePath + 'views/ajax',
            type: 'POST',
            dataType: 'json',
            data: 'view_name=product&view_display_id='+view_display_id,
            success: function(response) {
              var output = response[1].data;
              $("#A_CONTAINER_TO_DISPLAY_CONTENT").html(output);
            },
            error: function(data) {
                $("#A_CONTAINER_TO_DISPLAY_CONTENT").css("display","none");
                alert('An error occured!');
            }
          });

view_display_id is the machine name in here:

enter image description here

And don't forget to set the use Ajax to yes

  • thanks, but where I put the example code in? – joe Mar 24 '15 at 14:09
  • This Ajax function should be in the click event of the links in the left column. This is javascript code code, so foreach link you need to set view_display_id value – M a m a D Mar 24 '15 at 14:49
  • sorry where is click in left column? Is it in view? – joe Mar 24 '15 at 14:55
  • No, There is a list of titles in the left column of products, right? When each one is clicked its relevant content should be loaded via Ajax. So for every link in the list you should raise an on click event. – M a m a D Mar 24 '15 at 15:02
  • Oh. I dont quite get it but I will try checking and see if i can get it – joe Mar 24 '15 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.