Error: TinyMCE add p tag to smarty tag {}
Error: TinyMCE add p tag to smarty tag {}
When user add smarty tag to TinyMCE editor put smarty code in p tag, it's not good practise.
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
Re: Error: TinyMCE add p tag to smarty tag {}
This has been discussed before and is common knowledge.
TinyMCE is a text editor, it does not know if you are embedding a link with a {cms_selflink} or a time/datestamp or a block tag.
i.e:
{News} is a block
{$smarty.now|date_format:'%x %X'} is an inline tag. it is perfectly fine for that to be within <p> tags.
So. For users that are embedding smarty tags, they probably should know the difference between an inline and block tag, and should NOT use the wysiwyg editor for those pages.
For users that are not embedding smarty tags, they can have the WYSIWYG editor.
TinyMCE is a text editor, it does not know if you are embedding a link with a {cms_selflink} or a time/datestamp or a block tag.
i.e:
{News} is a block
{$smarty.now|date_format:'%x %X'} is an inline tag. it is perfectly fine for that to be within <p> tags.
So. For users that are embedding smarty tags, they probably should know the difference between an inline and block tag, and should NOT use the wysiwyg editor for those pages.
For users that are not embedding smarty tags, they can have the WYSIWYG editor.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
- Rolf
- Dev Team Member
- Posts: 7825
- Joined: Wed Apr 23, 2008 7:53 am
- Location: The Netherlands
- Contact:
Re: Error: TinyMCE add p tag to smarty tag {}
In TinyMCE you can disable it by unclicking: "Force paragraph on line break"
https://www.tiny.cloud/docs/configure/c ... root_block
But also has its disadvantages...
https://www.tiny.cloud/docs/configure/c ... root_block
But also has its disadvantages...
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Re: Error: TinyMCE add p tag to smarty tag {}
Not with me.calguy1000 wrote:This has been discussed before and is common knowledge.
What if I want to put form tag in content block? We have a situation with two p tag and form in p... If I want to resolve this problem, I have to make three content block... UX over 100%...calguy1000 wrote: TinyMCE is a text editor, it does not know if you are embedding a link with a {cms_selflink} or a time/datestamp or a block tag.
i.e:
{News} is a block
{$smarty.now|date_format:'%x %X'} is an inline tag. it is perfectly fine for that to be within <p> tags.
...probably should know...calguy1000 wrote: So. For users that are embedding smarty tags, they probably should know the difference between an inline and block tag, and should NOT use the wysiwyg editor for those pages.
It's not default solutions.calguy1000 wrote: For users that are not embedding smarty tags, they can have the WYSIWYG editor.
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
Re: Error: TinyMCE add p tag to smarty tag {}
If you are putting tags like {FormBuilder}, {CGBetterForms} or {YourCustomModule} into a content page then that content page is part of the application, not part of the content.
You should either disable the WYSIWYG editor for that page, or block... and preferably not let your content editors edit that page.
You should either disable the WYSIWYG editor for that page, or block... and preferably not let your content editors edit that page.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.