Best way to use Tags to categorise Data

Most of the threads about using Tags to categorise data seem to be from 2016, so I wanted to just ask the question afresh to avoid going down some blind alleys.

The content on Minnnis has grown quite a bit, and it makes sense to categorise the Projects, e.g. manufacturer>game>race

What would be the best way to implement that, that doesn’t end up with me having a mess of similar and misspelt tags. Creators would be allowed to add up to three or four tags per project. Theoretically the tags should be hierarchical, but I guess that is not 100% necessary, unless maybe in the “search” page.

Interested to hear people’s thoughts and suggestions!

3 Likes

Hello!

Create an object named tag

Add a list of tags to the project object

A tag can be an options set or an actual data type. If you build an admin dashboard for an admin user to manage your data then data type is the way to go because the admin can create/deactivate tags there.

Tag should have a field to assign them as active or inactive when needed (to be managed from the admin dashboard by admin users). A yes/no field should do the job.

In the UI make them visible and functional only for tags “active?“ is “yes”

Use repeating groups or multi dropdown inputs in the UI to show/manage them as needed

You can complement the system with this interesting technique by @TipLister for lean and simpler searching:

Hope this helps :+1:t2:

Hi @cmarchan - that is the route I have started going down, following one of @romanmg 's video: How to Let Users Create Their Own Options for Multiselect Dropdowns - YouTube which uses the Multiselect Dropdown plugin.

However, the problem I am facing is that in the Multiselect, we have the type of choice as “text”, which allows the user to add more Interests. However, when we save the page we want to save these tags to a list of Interests, but Bubble thinks they are texts so won’t save them to the Project. So we have added the tags to the Interests, but can’t add them to the Project itself.

You are describing a dB structure issue

You have to be consistent. If the dB has a data type “tag” then the UI element needs to be of type “tag” and get tags as a data source

Please consider that when I said “object” it is interchangeable with “data type”

I know, but that means either I have the data type as “text”, which means users can add new Interests themselves, which then get added to the Interests table, or I have the data type as Interests, which means I can then add them to the Project, but users can’t add their own extra Interests in the Multiselect Dropdown.


(Interests = Tags in my app)

to be clear, going down the Data Type route as per Gaby’s video so that users can add their own Tags/Interests…

So this is what I have done so far. Using this approach I can add one Tag to a Project, but if I try to add two or more, then none get added. I don’t understand why. Would I have to do this via a API workflow?

OK, I finally got this to work by having a workflow that searches for each text in the Tags then saves it to a State, then when I save my project I set my List of Tags, to be the List that is saved to the State.

this must have been about 4 hours of trial and error today!

1 Like

Continuing the general theme that I clearly don’t really know what I am doing, I discovered that the above works to add Tags, but once they are saved to the State, I cannot remove them. I guess I have no way of telling Bubble what to remove.

I would guess that the workflow should be something like, when input changes (removed tag), then Minus everything from the State, except those Tags which are still in the Multiselect, but I can’t work out how to do that.

Or is there a better approach?

I refer you back to my suggested approach

Hi Carlos, that is indeed what I am trying to do. Problem becomes because I am trying to use @romanmg 's approach to let users create their own tags, then the tags as they are added have to be text (which then creates the actual Tag in the Tag table). So then to add the texts tags from the Multiselect means I have to do a Search for the Tags matching the name text in the Multiselect input.

Gaby’s approach is geared towards a productive use of the multi dropdown element.

Tags could be chosen and selected via repeating groups.

1 Like

That would only work with a limited number of tags through, right? If there are hundreds of potential tags you want some kind of autocomplete, which the Multiselect gives you. And it would make it difficult for users to add their own tags - at least with Gaby’s approach?

OK, maybe I need to start afresh on this! :sweat_smile: Thanks for suggestions @cmarchan

Yeap.

Now that you plan to start fresh … consider building a system for each user to create/assign/delete their own tags for their content. This way tags will not be common tags … they will be user-specific tags for their own content.

Things is the Tags really do have to be common - this is more about helping other people find content later, rather than replying on search.

OK, let’s see if I can do this…

Oh if tags need to be common then forget about my suggestion.

They will be more like categories then instead of tags

Hi major_groove,
just in case you did not see my latest bubble tutorial video, as there are some similarities of what you seem to want to do.

3 Likes

Any chance you could link to an editor with this in it please? I always find it easier to implement by looking at it in the editor after watching a video.

Am I correct in thinking that this approach allows users to both select existing tags and create new tags?

hi, that is right you can either use existing tags or create new tags.
I am sorry, cannot share the link, as this is an app I am working on with other people.

1 Like

kein Ding!

I’ll see how I get on and maybe ping you if I run into problems. Thanks for making the video!