Keeping Titles Synchronized

This forum is for all Flare related Tips and Tricks.
Have a tip or trick you use while working in Flare? Share it here.
Post Reply
kathryngz
Propeller Head
Posts: 75
Joined: Wed May 14, 2014 11:31 am

Keeping Titles Synchronized

Post by kathryngz »

Here's how I set up my project so that a topic title only has to be updated in one place. I needed to keep the following synchronized:
  • The title at the top of the document (in an h1 tag)
  • The title in the HTML title tag
  • The Topic Title attribute on the Topic Properties tab of the Properties dialog
  • The topic title in any hyperlink in the project
I played around with different things, including using "Always use first topic heading" in Properties, but the HTML title tag wasn't updated when I changed the h1 title. This is what worked for me:
  1. Use the Topic Title attribute on the Topic Properties tab of the Properties dialog as the one place to specify the title. The HTML title tag uses this information if it exists. (In a topic, Ctrl-Shift-P* opens Properties.)
  2. For the title of the document in the h1 tag, insert the Title system variable. (Ctrl-Shift-V displays the variable sets. Choose System > Title.)
  3. For any links to the document, use xrefs. I created a style that just uses the {title} parameter. (Ctrl-Shift-R opens the Insert Cross-Reference dialog.)
Now, when I need to change a topic title, I just have to do two things and it's updated everywhere:
  1. Change the title in the Topic Properties, and it's changed in the HTML title tag and at the top of the page in the h1 tag.
  2. Update the xrefs to update all hyperlinks in the project (Tools > Update Cross-References)
Hope that's helpful to other users.

Kathryn

*Keyboard shortcuts are for Windows.
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Keeping Titles Synchronized

Post by NorthEast »

You don't actually need to do that - if you don't set the topic title, Flare will automatically set the topic title in the output to match the h1 heading.

If you do include a topic title - either by using topic properties, or by setting the HTML title tag (it's the same thing) - then the title you set will be used instead of the h1 heading.
kathryngz
Propeller Head
Posts: 75
Joined: Wed May 14, 2014 11:31 am

Re: Keeping Titles Synchronized

Post by kathryngz »

Dave, what you said is true--but I discovered by trial and error that if you don't set the topic title in Properties (i.e., if you leave it blank so it picks up the H1 tag), the HTML title tag is left blank. I needed the HTML title tag and the H1 title tag to stay synchronized. The only way I could discover to ensure that was to set the topic title in Properties.

If there's a different way to ensure that they stay synchronized, I'd be interested in hearing it. But so far what I described above is working great :) and I love how all my cross-reference hyperlinks throughout the project are staying synchronized too. It has eliminated some major maintenance headaches for me.

Kathryn
NorthEast
Master Propellus Maximus
Posts: 6359
Joined: Mon Mar 05, 2007 8:33 am

Re: Keeping Titles Synchronized

Post by NorthEast »

kathryngz wrote:Dave, what you said is true--but I discovered by trial and error that if you don't set the topic title in Properties (i.e., if you leave it blank so it picks up the H1 tag), the HTML title tag is left blank.
I don't quite understand - if the title "picks up the H1 tag" then how can it be "left blank" ?

Just to be clear, when you leave the topic title tag blank (either by editing the HTML code, or by using Topic Title in topic properties), it's the title tag in the output topic that will match your h1 heading title. I'm guessing you're looking at the source topic, but you'll only see this working by building the help and looking at the title tag in the output topic file.
Post Reply