CP Plain Text is wrapping content with p tags

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
Post Reply
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

CP Plain Text is wrapping content with p tags

Post by update »

I'm observing that the content of CP "Plain Text" is wrapped between p-tags. Has this been this way before ore do some changes take place?
Version used: 248 compared with version DEC 2007
This is some behavior which is now disturbing some of my older layouts, inserting these tags, which are then wrapping a Custom_blocks div. Not so good...
I wonder how I can circumvent this....
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: CP Plain Text is wrapping content with p tags

Post by update »

Thanks for clarifying :)
But this is rendering nasty output now (example - see p wrapping div):

Code: Select all

<div class="redBox">
<div class="redBoxHead">
<h3>more</h3>
</div>
<div class="redBoxContent">
<p><div class="articleText"><p>test</p></div></p>
</div>
......
</div>
Only chance would be to style .redBoxContent p {..... but it will still throw a warning that it's an empty tag.... hmmm
Really overlooked this one - plain text isn't plain text anymore... Sh..
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: CP Plain Text is wrapping content with p tags

Post by update »

Wouldn't it be much simpler to just insert the p tag into the plain text template thus wrapping {TEXT} and nothing else? Then it would be possible to delete it if not needed...
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
flip-flop
Moderator
Posts: 8178
Joined: Sat 21. May 2005, 21:25
Location: HAMM (Germany)
Contact:

Re: CP Plain Text is wrapping content with p tags

Post by flip-flop »

You are right, please insert a new issue. -> http://code.google.com/p/phpwcms/issues/list
>> HowTo | DOCU | FAQ | TEMPLATES/DOCS << ( SITE )
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: CP Plain Text is wrapping content with p tags

Post by update »

done... ;)
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: CP Plain Text is wrapping content with p tags

Post by Oliver Georgi »

Issue was rejected - it is a feature and can be solved by user very easy using simple css.

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: CP Plain Text is wrapping content with p tags

Post by Oliver Georgi »

claus wrote:

Code: Select all

<div class="redBox">
<div class="redBoxHead">
<h3>more</h3>
</div>
<div class="redBoxContent">
<p><div class="articleText"><p>test</p></div></p>
</div>
......
</div>
This is false HTML - so think twice when you have something like this:

Code: Select all

<p><div></div></p> - will always fail.
This is no problem

Code: Select all

<div class="articleText"><p>test</p></div>
Summary:
<p> tag cannot wrapped around <div>
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: CP Plain Text is wrapping content with p tags

Post by update »

Oliver Georgi wrote:<p><div></div></p> - will always fail.
This is correct - but it isn't my own input. This is a result of the new automatically-p-tags-wrapping feature and is occurring when I put a CUSTOM_BLOCK into the plain text CP (this one will be wrapped with that p-tag) and fill it with another CP then, which itself is already wrapped with a div automatically.
Then you will see this output plopping up...
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
User avatar
Oliver Georgi
Site Admin
Posts: 9892
Joined: Fri 3. Oct 2003, 22:22
Contact:

Re: CP Plain Text is wrapping content with p tags

Post by Oliver Georgi »

a custom block in CP plain text is false!!!

You must use HTML then because it can deliver HTML!

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
User avatar
update
Moderator
Posts: 6455
Joined: Mon 10. Jan 2005, 17:29
Location: germany / outdoor

Re: CP Plain Text is wrapping content with p tags

Post by update »

I will rebuild them all - but have been thinking that it would be a good idea, because plain text can be templated.... anyway - I'm on the road of changing it already :)
(btw this has been my private "yaml" column input technique before yaml and almost the same as described by Santcho now and basically it's cool - and will become even cooler, when I'm finished changing it ;) [I hope :lol: ])
It's mostly all about maintaining two or three customer's sites Still supporter for the band Mykket Morton. Visit Mykket Morton on FB. Listen Mykket Morton and live videos on youtube.
Now building a venue for young artists to get wet on stage, rehearsal rooms, a studio, a guitar shop - yes I'm going to build some guitars.
Post Reply