Hyperlinks have been the link mainstay for years but they have two problems:
- A hyperlink is linked to a target but doesn’t “know” what its target actually is. For example, the hyperlink in the image above points to the “Frappe” target topic. If I change that topic’s title to “Milkshake,” the hyperlink still works but the wording is wrong. To fix this, I need to change the word “frappe” in the link to “Milkshake.” This is easy to do with search and replace, but it’s just one more thing to worry about.
- A hyperlink works fine in online outputs and even for print outputs like a PDF. But what happens if users print a PDF? The link obviously doesn’t work; users have to find the target via the table of contents or the index, if you created one. Otherwise, users have to flip through the pages to find the right content. The only solution is for you to change each hyperlink to a page reference by hand, which doesn’t even bear thinking about.
Cross-references, also known as “xrefs,” solve both these problems nicely and add several other benefits.
An xref “knows” what it’s linked to because it links to the target topic’s title. This means that you don’t have to type the text of the link, as you do with a hyperlink. Instead, the xref grabs the title of the target topic and automatically uses it as the link text. And if the target topic’s title changes, the link text changes automatically. For example, if I change the name of the target topic in the example above from “Frappe” to “Milkshake,” Flare changes the wording of the xref to match, as shown in the image below (where the wording of the hyperlink is now wrong). This makes link maintenance more efficient.
I like use this also!
After editing i seen in my layout.htm
I use this in my XML editor
-[MadCap:xref href="layout.htm"/]
but in my text editor i donot see the right name but
- [MadCap:xref][MadCap:xref]
when i use the PREVIEW function the right text (of H1 name) is shown.
note : the Sign Great and Lower is not shown (in this editor) there i use []
Posted by: Beaver | July 07, 2017 at 06:24 AM
I came to Flare already familiar with cross-references to locations within a document but having used hyperlinks only to link to web URLs. To me, the ability to have the text displayed for a hyperlink be different from the linked topic title is a benefit. I use hyperlinks rather than cross-references for places where I want the text to say something like "click here" or "next step." I could create a separate cross-reference style for each piece of text I want to have as a link, but I find it easier just to use a hyperlink. If the topic is used in both Help and PDF outputs, I include both the hyperlink and a cross-reference and then conditionalize them as HelpOnly or PrintOnly, respectively. (Yes, I know I could create a cross-reference style that has the text for the default medium and the cross-reference format for the print medium, but I prefer not to proliferate my cross-reference styles more than I already have.)
Posted by: Lisa | July 07, 2017 at 08:47 AM