Selecting multiple taxonomy terms in blog Drupal 7 - drupal

I've just started learning Drupal 7 and while I was creating a blog I wanted to give it a relation but it must be related to multiple articles through taxonomy terms.
In the Blog content type, I created a relation field, set the Field Type to Term Reference and Widget to Check boxes/radio buttons.
Here is a snapshot http://varunsharmak2.com/blog-content-type.png
Now when I create a blog entry, it shows all the Taxonomy terms as radio buttons in Relation section.
Here is a snapshot of it. http://varunsharmak2.com/relation.png
I want checkboxes in place of radio buttons.
How can I get check boxes?

When you edit that field there should be an option to select how many tags can be selected? Default is one, but you can select 2,3... and finally unlimited. That field is drop-down field. Select unlimited.
Your second screenshot is not working btw.

Related

Relating different content types in Drupal 7

I've just started learning Drupal 7 and I'm stuck on a problem.
I want to relate different content types using taxonomy. For example, how can I display blogs related to an article?
I know how to relate articles and basic pages but I don't know how can I relate blogs with articles?
Please help me.
Use reference field in blogs content type
like
field name is: related with
field type is reference
set reference type node
set node type is article
optional multivalued true
Now you have a relationship field in blogs
Now you can do every thing with this relationship
Hope this make sense
Thanks
You would create your taxonomy vocabulary and supply it with terms. On its own, this doesn't do anything, you need to add a field to each of your content types that are using this taxonomy.
If you go back to your content types, structure > content type > article. Here you would create a new field of type term reference. Inside the settings of the field you'd select your vocabulary and then also the widget eg. select list. You can re-use this field on the other content types where you want to share this vocabulary.
If you go back to your content for the types you added this field for and populate them with selections, when you view that page by default the term will appear as a link. If you click this link it will take you to a page view that will list all the other nodes that have that term form that vocabulary.
More information on taxonomies: https://www.drupal.org/docs/7/organizing-content-with-taxonomies/about-taxonomies
If you are creating a view and want to know how to pull in different tagged content there, I'd recommend reading this post which outlines the steps to do so https://drupal.stackexchange.com/questions/205921/how-do-i-show-related-content
The process:
Basic stages:
Create a “Content” view-block.
Add a contextual filter: “Has taxonomy term ID”.
Choose “provide a fixed value”.
(From type): “Taxonomy term ID from URL“.
Checking:
• Uncheck “Load default filter from the term page”. • Check “Load
default filter from node page, that’s good for related taxonomy
blocks”.
• Check “Limit terms by a vocabulary”. • Check your desired
vocabulary.
Select “Filter to items that share any term”.
Go down and check “Reduce duplicates”: This will several terms that relate to the same page – To appear. Only one will of them will.

Drupal 7 - Term reference field: how to add new term?

I have some texonomies in my Drupal website. Some of them have additional fields. I have some fields of type Term reference in my content-types.
When I am creating a new node of a content-type, I would like to have the ability to add a new term to the taxonomy while I'm filling the form of the Content-Type (with an "add item" link/popup...).
I can do that if I use Entity Reference fields, but I cannot using Term reference field. Could you help me, please?
Thanks
UPDATE: I installed "Taxonomy access fix" module (https://www.drupal.org/project/taxonomy_access_fix) and it allows me to set capabilities per each taxonomy based on user role. Now I only need to add a new term to a Taxonomy on a form level using Term reference field (I canno use autocomplete because I need the user to see all possible values like with a dropdown).
Any help?
If you change your widget to the autocomplete widget, it will let you add new values.
I agree with #Dark FlameS, in fact we are using the autocomplete widget for some of our students to add types of trees in the biology lab and they tag each with the scientific name.
And since we dont know these scientific terms, we let them add taxonomy terms to the list.
Slight difference however, we use the module Autocomplete Deluxe. Works like magic for us.
You are able to see what taxonomy terms are already available by clicking into the text area.
And as you type a taxonomy term, you will see what other terms are similar. If a tag is new, it will be added. one thing, dont allow them to delete your tags. We learned this the hard way.
See the image below on what it looks like as you add a tag.
Above is what you will see when you are adding the taxonomy field in your content type, this is after you install the Autocomplete Deluxe module
Above is What the user sees when they add or select a taxonomy tag.

Drupal Commerce Multiple Product Listing

I am currently working on a project based on drupal + drupal commerce module.
I made a products node (Product Display) using the product reference and inline entity form - Multiple Values.
Now the problem is, I want to list products in a "div" rather than listing them through select box.
To be more clear:
It does list out multiple products, but shows only 1 product at a time. I have to select a product from the drop-down list.
As you can see here:
http://i.stack.imgur.com/EO8if.jpg
Please note: Table panel and bottle box are products.
What I want is:
All the products should be listed without the need of a drop-down select box selection.
Thanks & Regards
Is there a reason why you have used only one node of type "product display" for two diferent products "Table Panel" and "Bottle Box"?
If you create one node for each product its easier do display them as a list.
In my understanding, I wasn't doing it in the right way. I found out the way. I can make product displays and then render them as a VIEW. And style it accordingly. Again many thanks for your input, it really helped me to think, why am I doing this way.
Thanks nimbfire.

How to create taxonomy term count block?

I have a blog in Drupal 7 where the blog content type has a multi-select box (select drop-down box) for tagging that uses a specific taxonomy vocabulary. As such, any blog entry can have multiple tags from the vocabulary by control-clicking the terms. What I need is a block that lists the terms with the count of the number of times the term has been used
Ex:
Drupal (21)
Views (15)
Panels (18)
I also need each list item to link to a page that lists the blog titles associated with the term. I thought the first part would be simple using views with aggregation but, so far, no luck. Any idea how to do this?
Thanks
Create Taxonomy Views.
Add relationship to the node.
Enable grouping (or "Use aggregation" toggle in D7, then set the "Aggregation Settings" for each field)
Add new field 'Node: NID' and set Group type to: Count
Regards.

Drupal: View with exposed Taxonomy filter.. 2 questions

I'm using Views module and an exposed taxonomy based filter, to allow users to select a subselection of articles.
I need to further customize my filter:
I want the user able to order the tags alphabetically by clicking a checkbox (if this checkbox is unchecked the default order is reset.
I want all tags selected in the beginning to show my user all the articles. (Additional tags can be added by the user later, so I cannot just select all the tags in Views settings, because the new ones would be uncovered).
thanks
1) jquery script that adds check-box (or link as text or pic) and if it is checked, rearranges menu or list
2) rephrase question, i have no whiskey at home
what about the other way round?? -> selected tag means "show".
how do your filters work?? You don't use http://drupal.org/project/faceted_search ?
i am starting with it and like it.

Resources