MarcomCentral (PTI) and FusionPro User Communities

MarcomCentral (PTI) and FusionPro User Communities (http://forums.pti.com/index.php)
-   FusionPro® VDP Server (API) (http://forums.pti.com/forumdisplay.php?f=8)
-   -   Tagged Text File (http://forums.pti.com/showthread.php?t=5909)

ReminderVDP February 24th, 2020 02:51 PM

Tagged Text File
 
1 Attachment(s)
I'm trying to format a disclaimer for a customer we work with who needs bold text on some lines of the disclaimer. I have been able to get tagged data files to work with different fonts, but not a separate text file the data calls for.

I'm attaching my separate text file that would go into the layout. I feel like it's mostly tagged correctly but it previews as Arial and none of the bold lines work.

Dan Korn February 24th, 2020 03:59 PM

Re: Tagged Text File
 
I see a few problems.

First, watch out for curly quotes in tagged markup, especially for tag attributes. This:
Code:

<f name=“Minion Pro Bold“>
should be:
Code:

<f name="Minion Pro Bold">
You should make sure that whatever editor you're using for these files has the option to convert straight quotes to curly or "smart" quotes turned off.

Second, there's no such thing as an ending </f> tag. If you want to apply the font change just to a particular range of text, and revert to the previous font after, you can use a <span> tag pair, either like so:
Code:

<span><f name="Minion Pro Bold">some text in Minion Pro Bold </span>and revert to previous font
or:
Code:

<span font="Minion Pro Bold">some text in Minion Pro Bold </span>and revert to previous font
Third, I don't have your font, but 90 percent of the time in FusionPro, you don't call out a font with both the family name (i.e. Minion Pro) and the style name (i.e. Bold). Instead, you probably need to just call out the family by name, then apply the bold style, like so:
Code:

<f name="Minion Pro"><b>
or:
Code:

<span font="Minion Pro" bold=true>
Following up on that, if all you're really trying to do is turn the text bold, then you shouldn't really need to specify the font name at all. You should be able to simply use a <b> tag, or <span bold=true>, to take whatever the running font family is and turn it to its bold style.

That said, though, I wonder why you feel the need to use a tagged markup file for this in the first place. You could simply add a Formatted Text Resource, define all the fonts and styles in the Text Editor, and call that Formatted Text resource out in a rule instead of the tagged markup file, and not have to muck about with tags at all. I mean, it's fine to use tagged markup, but as you can see, you have to get the tagging right, which can be a bit tricky.

I suspect there are other ways to reduce the complexity of this job, such as using Text Replacement to directly convert text such as [bank name] to a data field value without having to write some kind of regular expression replacement code, but I would need to see the job to offer more specific suggestions.

Finally, for problems like this, always do a regular composition instead of a Preview, so that you can view the log file and look for relevant messages.

ReminderVDP February 25th, 2020 06:57 AM

Re: Tagged Text File
 
Dan,
Thanks for the couple tips there. I won't be able to make the text file a resource because the names of the banks and companies would be specific to certain customers and all the disclaimers will be different. The name of the text file gets called out in the data and FusionPro grabs it from the server location where it is used in the layout.



The </f> on the font tag worked in the data fields, that's why I used it here. If I don't need it though, I'll remove it. I think I could just use the bold tag though since those couple lines will be bold and the rest Minion Pro Regular.


I think I made it more complex than it needed to be.


All times are GMT -7. The time now is 12:52 AM.

Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
(c) 2011, PTI Marketing Technologies™, Inc.