Ok to apply condition to snippet, then again inside a topic?

This forum is for Single-Sourcing your Flare content to multiple outputs.
Post Reply
kearnine
Jr. Propeller Head
Posts: 5
Joined: Thu Feb 14, 2019 11:39 am

Ok to apply condition to snippet, then again inside a topic?

Post by kearnine »

We have some snippets that are conditioned for different things. It's a bummer that the color of a conditioned snippet doesn't appear on the snippet when you insert it into a topic. Our team wants to continue conditioning an entire snippet and we want to then apply the condition again on the snippet after it's inserted into a topic so we can see the color there, too. Is there any drawback to applying a condition twice like that? Just want to make sure....
Chicago_HPT
Sr. Propeller Head
Posts: 133
Joined: Sun Feb 03, 2013 6:01 pm

Re: Ok to apply condition to snippet, then again inside a to

Post by Chicago_HPT »

It sounds like you may want to take a look at Snippet Conditions. Once I got the hang of them, I started using them extensively. They're extraordinarily useful.

I hope that helps,
-jeff
ChoccieMuffin
Senior Propellus Maximus
Posts: 2630
Joined: Wed Apr 14, 2010 8:01 am
Location: Surrey, UK

Re: Ok to apply condition to snippet, then again inside a to

Post by ChoccieMuffin »

Are you applying a condition to the entire snippet in File Explorer? If so, what is your reasoning for doing so? In this case you're right, when you insert a snippet where the condition has been applied at the file level (if you look at the snippet in a text editor the condition is in the <html> line) into a topic, the condition doesn't show up. If, on the other hand, you apply the condition to the content of the snippet, then the condition does show up.

As for whether it's a problem, I can only see a problem if you decide at some stage to change how you want to use the snippet, and that at some stage the double conditions might come back to bite you when you can't figure out why it's not showing up.

I think Chicago_HPT has a very valid point, and snippet conditions sound like something well worth investigating for you. Good luck.
Started as a newbie with Flare 6.1, now using Flare 2023.
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
kearnine
Jr. Propeller Head
Posts: 5
Joined: Thu Feb 14, 2019 11:39 am

Re: Ok to apply condition to snippet, then again inside a to

Post by kearnine »

Thanks, both of you. I wound up calling Madcap Support and we decided that snippet conditions aren't quite the thing for this, which is too bad because our team has been looking for ways to use those.

We have been applying the conditions to the snippet file purely because the colors help us identify them more easily in the Content Explorer. Maybe a dumb reason because it's not a best practice. I think that's the lesson learned here. We'll just apply the condition once we bring it into the topic.

I appreciate your thoughts and help very much!
ChoccieMuffin
Senior Propellus Maximus
Posts: 2630
Joined: Wed Apr 14, 2010 8:01 am
Location: Surrey, UK

Re: Ok to apply condition to snippet, then again inside a to

Post by ChoccieMuffin »

kearnine wrote: ...
We have been applying the conditions to the snippet file purely because the colors help us identify them more easily in the Content Explorer.
....
Another suggestion for you is to develop a naming convention for your snippets which will help you identify them, rather than using conditions that might trip you up elsewhere.
Started as a newbie with Flare 6.1, now using Flare 2023.
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
RStreets
Propeller Head
Posts: 63
Joined: Wed Apr 19, 2017 8:37 am
Location: Cambridge, UK

Re: Ok to apply condition to snippet, then again inside a to

Post by RStreets »

kearnine wrote:We have been applying the conditions to the snippet file purely because the colors help us identify them more easily in the Content Explorer.
Maybe you could create subfolders in the snippets folder for the different condition names and place the snippets in these?
Rae Streets (Flare user since 2017, now on Flare 2023; Central user from 2020)
kearnine
Jr. Propeller Head
Posts: 5
Joined: Thu Feb 14, 2019 11:39 am

Re: Ok to apply condition to snippet, then again inside a to

Post by kearnine »

That’s a great idea, too. Thank you!
Post Reply