Active links only when topic is included in TOC?

This forum is for all Flare issues related to PDF, eBook, Microsoft Word, Adobe FrameMaker, XPS, and XHTML book targets.
Post Reply
CATERAF
Sr. Propeller Head
Posts: 103
Joined: Mon Mar 18, 2013 10:19 pm
Location: Perth, Australia

Active links only when topic is included in TOC?

Post by CATERAF »

Hi,

I have many pdf manuals which contain the same set of topics.
Each topic contains links to other topics (whether or not the topics are included in the TOC).
However, I don't want these links to be active for one of the TOCS because I'm not including the additional topic(s).

Example:
One topic (featured in all manuals) says 'Go to the Maintenance Procedure 'abc' for more information'
In Manual #1 I want the term 'abc' to be linked to the topic 'ABC' (and topic ABC is included in Manual #1's TOC)
In Manual #2 I want the term 'abc' to just look like regular text with no link to the topic 'ABC' (because the topic ABC is not in Manual #2's TOC).

Is there a way to ask Flare to not use a cross-reference to a topic if that topic is not included in the manual/TOC?
If not, how do you suggest I go about doing this please? I don't really want to have to have the cross reference written twice (one with a link and one not linked) with conditions applied to each.

There may also be a very simple way that I've completed overlooked.

Any help is handy! :)

Thanks,
Avril
SteveS
Senior Propellus Maximus
Posts: 2090
Joined: Tue Mar 07, 2006 5:06 pm
Location: Adelaide, far side of the world ( 34°56'0.78\"S 138°46'44.28\"E).
Contact:

Re: Active links only when topic is included in TOC?

Post by SteveS »

Hi Avril,

Not sure if this is what you mean, but...

I'd be inclined to apply a conditional tag to the links you want to exclude. You may have to create a new conditional tag for this purpose.

I'd then create a new TOC for the 'modified' project.

Finaly I'd create a new target, excluding the conditional tag. You can also use the target/ TOC and conditional tagging to exclude the 'other' topics entirely from the build if it is for HTML/ CHM etc.

HTH
Image
Steve
Life's too short for bad coffee, bad chocolate, and bad red wine.
CATERAF
Sr. Propeller Head
Posts: 103
Joined: Mon Mar 18, 2013 10:19 pm
Location: Perth, Australia

Re: Active links only when topic is included in TOC?

Post by CATERAF »

Thanks Steve -- I've ended up using a condition and applying the 'exclude' and 'unbind' technique.

Thinking about submitting a feature request though so that when a link is broken, the link is removed from the output. Otherwise you could accidentally send a customer a broken link.

Thanks again for your help!
SteveS
Senior Propellus Maximus
Posts: 2090
Joined: Tue Mar 07, 2006 5:06 pm
Location: Adelaide, far side of the world ( 34°56'0.78\"S 138°46'44.28\"E).
Contact:

Re: Active links only when topic is included in TOC?

Post by SteveS »

I don't have access to Flare at the minute, so maybe someone can chime in...

Flare includes some basic project analysis tools and I'm pretty certain one checks for broken links. Worth using before you send stuff to customers.
Image
Steve
Life's too short for bad coffee, bad chocolate, and bad red wine.
Msquared
Propellus Maximus
Posts: 848
Joined: Mon Aug 06, 2012 10:19 am
Location: Southampton, UK

Re: Active links only when topic is included in TOC?

Post by Msquared »

There is a tool to spot broken links, but that will only spot links to files that aren't in the project. I don't think that will spot links to files that are in the project, and will be referenced in a specific target but won't be included at build time in that target. I think those will only show up as build time errors (but I may be wrong).

Once upon a time, I did manage to get links to missing content converted to text, and I've been struggling to remember what I did to cause this. But, don't get too excited, as I do remember that this wasn't the behaviour I actually wanted at that point, and it was either a consequence of something I'd done wrong, or a Flare bug. However, if it comes back to me, and appears to be useful, I'll let you know.
Marjorie

My goal in life is to be as good a person as my dogs already think I am.
pbrooks
Jr. Propeller Head
Posts: 2
Joined: Tue Mar 06, 2012 12:27 pm
Location: Indiana

Re: Active links only when topic is included in TOC?

Post by pbrooks »

Hello Avril:

Did you ever find a solution to this issue? We run into this problem as well and would love a simple feature or solution other than the use of a condition.

Thanks for sharing!

Patty
CATERAF
Sr. Propeller Head
Posts: 103
Joined: Mon Mar 18, 2013 10:19 pm
Location: Perth, Australia

Re: Active links only when topic is included in TOC?

Post by CATERAF »

Hi Patty,

I thought I had found a solution to this but it's currently not doing what I need. I'll explain what it's doing so you know if this is what you need. Unfortunately it does use conditions - but it could be quite simple (as far as conditions go).
It works well if you have a cross-reference that you want unbound while retaining the formatting of the cross-reference. If you don't want the cross-reference format, this is not what you need.

For example, my cross-references for pdf all need the page number so the links say '[Name of Place to Link to] (page xx)'.
I've managed to condition the items so that the I can have the link unbound but, it does a literal 'unbind' and becomes ''[Name of Place to Link to] (page 1)' without the link. It always says page 1 even I've asked it to unbind the xref. I just want it to show the title which is what the xref would be without the xref.

So, with that in mind, I have found a solution provided the xref formatting is what you're after, just with no linking functionality.
If that's what you're after, the way I did it was:
For every link that is for a topic that is not included in my TOC, I add a conditional tag. The condition tag has the 'unbind if excluded' function applied. Then, when I'm selecting the condition tags for the Target, I either tick include or exclude for the condition depending on whether I need all those links to hyperlink or not.

This definitely works but as I said before, it keeps the xref formatting which is not what I need and I'm yet to find another solution. If anyone has any ideas how to force an unbind to remove the xref formatting that would be great!!

Avril
CATERAF
Sr. Propeller Head
Posts: 103
Joined: Mon Mar 18, 2013 10:19 pm
Location: Perth, Australia

Re: Active links only when topic is included in TOC?

Post by CATERAF »

Hmm.. on closer inspection, what I just posted (xref keeping formattig but losing the link) may be a bug. I will investigate further with Tech Support and will try to keep you posted.
Post Reply