Line break in a Snippet
-
- Propeller Head
- Posts: 28
- Joined: Wed Feb 15, 2006 12:58 pm
- Location: Chicago, IL
- Contact:
Line break in a Snippet
Is it possible to put an HTML line break (<br />) in a snippet? It currently ignores it and so all the lines are put together. It also ignores forced line breaks (shift-Enter). Hard returns are too widely spaced and I don't want to have a special style just to get it to work right.
Re: Line break in a Snippet
The behavior you are seeing depends on whether you are inserting the snippet as a snippetblock (by itself in a paragraph of the containing document - preserves paragraph breaks and such formatting) or a snippettext (in a paragraph of the containing document with other text - inserts only the text and inline formatting from the snippet).
-
- Propeller Head
- Posts: 28
- Joined: Wed Feb 15, 2006 12:58 pm
- Location: Chicago, IL
- Contact:
Re: Line break in a Snippet
Thanks.
Interesting. The breaks appear in a snippet as part of a list, but the list is preceded and followed by another paragraph each.
If I understand you correctly, in this case I won't be able to get the breaks to work properly?
Interesting. The breaks appear in a snippet as part of a list, but the list is preceded and followed by another paragraph each.
If I understand you correctly, in this case I won't be able to get the breaks to work properly?
-
- Senior Propellus Maximus
- Posts: 3672
- Joined: Thu Feb 02, 2006 9:57 am
- Location: Pittsford, NY
Re: Line break in a Snippet
devjoe is pointing you in the right direction. "It all depends" on whether you've inserted the snippet as "snippetText" or "snippetBlock".
How about if you post the bit of code that shows the list items, paragraphs, and snippet so we can see what's what?
(Off topic: So I see you are in Chicago. There are several Chicago area Flare users who are now congregating in the #illinois channel of the new Slack community dedicated to Flare user groups. If you're interested in joining the community, PM me the email address to which you'd like me to send the Slack invitation.)
How about if you post the bit of code that shows the list items, paragraphs, and snippet so we can see what's what?
(Off topic: So I see you are in Chicago. There are several Chicago area Flare users who are now congregating in the #illinois channel of the new Slack community dedicated to Flare user groups. If you're interested in joining the community, PM me the email address to which you'd like me to send the Slack invitation.)
Nita
RETIRED, but still fond of all the Flare friends I've made. See you around now and then!
RETIRED, but still fond of all the Flare friends I've made. See you around now and then!
Re: Line break in a Snippet
I'm not the original poster of this question, but I'm having the same issue. I feel like I'm close to figuring it out from reading this thread, but I still haven't solved it. Here's the code of the topic in which I've used the snippet:
<?xml version="1.0" encoding="utf-8"?>
<html xmlns:MadCap="http://www.madcapsoftware.com/Schemas/MadCap.xsd" MadCap:lastBlockDepth="6" MadCap:lastHeight="1052" MadCap:lastWidth="1389">
<head><title></title>
<link rel="stylesheet" href="../Resources/StyleSheets/rr demo style.css" type="text/css" />
</head>
<body>
<h1>Enabling Skype for Business in Prysm Go</h1>
<MadCap:snippetblock src="../Resources/Snippets/ConfigS4BInPrysmGoSnpt.flsnp" />
</body>
</html>
And here is a bit of code from the snippet. You can see a few <br /> tags here, which are being ignored when I place the snippet in the topic:
<ol>
<li>From the <strong>Deployments</strong> page, use the <strong>Search</strong> field to find the desired deployment, and click <strong>Edit.<br /></strong>The Edit Deployment page is displayed.</li>
<li>Click <strong>Enhancements.</strong></li>
<li>Click <strong>Skype For Business</strong>.<br />The Edit Skype For Business Settings page displays.<br /><img class="largeimages" src="../Images/SoftwareAdminGd/169721262.png" /></li>
I tested out changing MadCap:snippetblock to MadCap:snippettext, and that made the entire topic one long string of unbroken text.
Any more guidance you could give would be greatly appreciated. Thanks!
<?xml version="1.0" encoding="utf-8"?>
<html xmlns:MadCap="http://www.madcapsoftware.com/Schemas/MadCap.xsd" MadCap:lastBlockDepth="6" MadCap:lastHeight="1052" MadCap:lastWidth="1389">
<head><title></title>
<link rel="stylesheet" href="../Resources/StyleSheets/rr demo style.css" type="text/css" />
</head>
<body>
<h1>Enabling Skype for Business in Prysm Go</h1>
<MadCap:snippetblock src="../Resources/Snippets/ConfigS4BInPrysmGoSnpt.flsnp" />
</body>
</html>
And here is a bit of code from the snippet. You can see a few <br /> tags here, which are being ignored when I place the snippet in the topic:
<ol>
<li>From the <strong>Deployments</strong> page, use the <strong>Search</strong> field to find the desired deployment, and click <strong>Edit.<br /></strong>The Edit Deployment page is displayed.</li>
<li>Click <strong>Enhancements.</strong></li>
<li>Click <strong>Skype For Business</strong>.<br />The Edit Skype For Business Settings page displays.<br /><img class="largeimages" src="../Images/SoftwareAdminGd/169721262.png" /></li>
I tested out changing MadCap:snippetblock to MadCap:snippettext, and that made the entire topic one long string of unbroken text.
Any more guidance you could give would be greatly appreciated. Thanks!
-
- Sr. Propeller Head
- Posts: 210
- Joined: Mon Sep 19, 2011 2:06 am
- Location: Netherlands - Zoetermeer
- Contact:
Re: Line break in a Snippet
Hi,
In Flare all text formatting is best done using a p-tag, so use a p-tag like this:
<ol>
<li><p>From the <strong>Deployments</strong> page, use the <strong>Search</strong> field to find the desired deployment, and click <strong>Edit.</p>
<p></strong>The Edit Deployment page is displayed.</p></li>
<li><p>Click <strong>Enhancements.</strong></p></li>
<li><p>Click <strong>Skype For Business</strong>.</p><p>The Edit Skype For Business Settings page displays.</p><img class="largeimages" src="../Images/SoftwareAdminGd/169721262.png" /></li>
...
</ol> I hope you finish the <ol> also.
In Flare all text formatting is best done using a p-tag
This even shows the lines neatly formatted in the text editor view.
Greetings,
Rene Severens
In Flare all text formatting is best done using a p-tag, so use a p-tag like this:
<ol>
<li><p>From the <strong>Deployments</strong> page, use the <strong>Search</strong> field to find the desired deployment, and click <strong>Edit.</p>
<p></strong>The Edit Deployment page is displayed.</p></li>
<li><p>Click <strong>Enhancements.</strong></p></li>
<li><p>Click <strong>Skype For Business</strong>.</p><p>The Edit Skype For Business Settings page displays.</p><img class="largeimages" src="../Images/SoftwareAdminGd/169721262.png" /></li>
...
</ol> I hope you finish the <ol> also.
In Flare all text formatting is best done using a p-tag
This even shows the lines neatly formatted in the text editor view.
Greetings,
Rene Severens
"The numbers are strange today; they somehow do not seem to add up."
-
- Senior Propellus Maximus
- Posts: 2634
- Joined: Wed Apr 14, 2010 8:01 am
- Location: Surrey, UK
Re: Line break in a Snippet
Quick reply to ryanr: put your snippetblock inside a <p>, it should work after that.
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
Report bugs at http://www.madcapsoftware.com/bugs/submit.aspx.
Request features at https://www.madcapsoftware.com/feedback ... quest.aspx
Re: Line break in a Snippet
Thanks, everyone! Adding <p> tags instead of <br /> tags to break lines solved the problem. We have liked the spacing and had no problems before with avoiding <p> tags inside <li> tags and other such elements. But we might have to rethink our formatting.
Re: Line break in a Snippet
I have a similar problem - but my snippets do not use the <br /> tag. I have this snippet:
I add it like this:
But it comes out as just one paragraph, not two. I've tried most everything - removing head, body, html whatever from the snippet, I tried adding the div directly in the snippet, but it always comes as one paragraph.
Now why would that be?
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<html xmlns:MadCap="http://www.madcapsoftware.com/Schemas/MadCap.xsd" MadCap:lastBlockDepth="3" MadCap:lastHeight="130" MadCap:lastWidth="1344">
<head>
<link href="../../../Stylesheets/styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
<p><b>MVS (Market Value System)</b> is the <MadCap:variable name="General.ProductName" /> calculation core for performing insurance mathematics at tariff level. </p>
<p>The <b>MVS</b> core functionality offers tariff calculation of expected cash values, payments, etc. <b>MVS</b> offers a flexible modeling of calculation bases as well as the possibility to model transformations of calculation bases. Furthermore, <b>MVS</b> includes a framework for implementation of portfolio calculations, for instance for risk management and solvency assessments, as well as a framework for implementing rules-based creation and modification to assemble the tariffs required for the calculation of for instance policies.</p>
</body>
</html>
Code: Select all
<div class="intro">
<MadCap:snippetText src="../../../../Resources/Snippets/RN/IntrosUS/MVS.flsnp" />
</div>
Now why would that be?
-----
Flaring in Copenhagen, Denmark
Flaring in Copenhagen, Denmark
-
- Propellus Maximus
- Posts: 574
- Joined: Tue Oct 03, 2006 7:56 am
- Location: Seattle, WA
- Contact:
Re: Line break in a Snippet
Try replacing
MadCap:snippetText
with
MadCap:snippetBlock
MadCap:snippetText
with
MadCap:snippetBlock
Pamela Denchfield
http://www.pameladenchfield.com
http://www.pameladenchfield.com
Re: Line break in a Snippet
There you go. Thanks!
Funny, I never realized there was a difference. I always just assumed that if you added the snippet inline, it was inline, and if you added it as a separate paragraph, it was a block...
I am now the wiser, and I thank thee!
-Niels
Funny, I never realized there was a difference. I always just assumed that if you added the snippet inline, it was inline, and if you added it as a separate paragraph, it was a block...
I am now the wiser, and I thank thee!
-Niels
-----
Flaring in Copenhagen, Denmark
Flaring in Copenhagen, Denmark