Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2013-08-17 18:58:06
- webmaster123
- New Member
- Registered: 2013-06-02
- Posts: 2
<txp:body /> without <p> tags
Hi Everybody,
I’m starting with my first textpattern website. But now i have a big problem, I have already search on this forum, but i can’t find the solution.
So, i have an article in textpattern, like this:
this is text in an article, more text in this article, this is text in an article, more text in this article, this is text in an article, more text in this article
<h2>title text</h2>
this is text in an article, more text in this article, this is text in an article, more text in this article, this is text in an article, more text in this article
<ul>
<li>test</li>
<li>test</li>
</ul>
this is the end of the article.
So, i used <p><txp:body /></p> to show the article, but now there is something wrong :(. If i look to the source i see textpattern placed a few <p> tags? I don’t now how i can fix this. Now is my source code:
<p><p>this is text in an article, more text in this article, this is text in an article, more text in this article, this is text in an article, more text in this article</p>
<p><h2>title text</h2></p>
<p>this is text in an article, more text in this article, this is text in an article, more text in this article, this is text in an article, more text in this article</p>
<p><ul>
<li>test</li>
<li>test</li>
</ul></p>
<p>this is the end of the article. </p></p>
How can I solve this problem? Many, many, many thanks for the solution!
Best Regards,
Helena
Edit. added code formatting -Gocom
Last edited by Gocom (2013-08-17 19:21:37)
Offline
#2 2013-08-17 19:19:38
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,315
Re: <txp:body /> without <p> tags
You’ve applied superfluous HTML tags in several places:
Remove the <p>
s around the body tag. Don’t use HTML in articles.
Or, if you can’t avoid using HTML in articles, set the “Article markup” menu to “Leave text untouched”. Edit: (Doesn’t save you, though, from removing the <p>
s around <txp:body />
)
But I recommend learning Textile: there’s a small cheat sheet already top left hand side of the Write panel, “Textile help”. Textile outputs correct markup and is faster to write than HTML. In Textile, your input would look like this:
this is text in an article, more text in this article, this is text in an article, more text in this article, this is text in an article, more text in this article
h2. title text
this is text in an article, more text in this article, this is text in an article, more text in this article, this is text in an article, more text in this article
* test
* test
this is the end of the article.
I’ve used spaces before h2 and the list items just to not let this forums Textile function swallow the Textile commands. So if you copy the code remove these spaces before saving the article.
Last edited by uli (2013-08-17 19:26:59)
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
Offline
Pages: 1