Skip Navigation

[Resolved] li adding to template

The Toolset Community Forum is closed, for technical support questions, please head on to our Toolset Professional Support (for paid clients), with any pre-sale or admin question please contact us here.
This support ticket is created 7 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the community support forum for Types plugin, which is part of Toolset. Toolset is a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients and people who registered for Types community support can post in it.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 12 replies, has 2 voices.

Last updated by CommMgr 7 years, 5 months ago.

Assisted by: Shane.

Author
Posts
#537180
li_adding_p_screenshot.JPG
content_template_set_manual_p.JPG

The content template is adding <p></p> within my (li)(/li) and it will not accept any css styling so I am unable to adjust the line-height for that section. (see screenshot below)

Here is my raw code for reference:

<!-- LEARNING OBJECTIVES -->
<div style="font-size: 16px; font-weight: 600; color: #5b8703; padding: 20px 0 5px; line-height: 1.5em;">LEARNING OBJECTIVES</div>
<ul>
  <li>[types field='learning-objective-1'][/types]</li>
  <li>[types field='learning-objective-2'][/types]</li>
  <li>[types field='learning-objective-3'][/types]</li>
  <li>[types field='learning-objective-4'][/types]</li>
</ul>

I have the "manual paragraphs" option selected in my content template settings...so that is not it. (see screenshot)

Wordpress does not add the <p> tags within my (li) anywhere else on my site...so this is a Toolset issue.

Thanks for your assistance.
CommMgr

#537229

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Chris,

Thank you for contacting our support forum.

No auto paragraph should be added to the elements. Just to ensure some other plugin isn't automatically doing this would you mind temporarily disabling all the non-toolset plugins for me and try again ?

Once you have done this please let me know the results.

Thanks,
Shane

#537234

Hi, Shane...

As I have mentioned in previous support threads, turning off plugins on my Divi site will cause major issues with the site functionality. So that is not an option. You may remember you made a duplicate copy of my site recently to help troubleshoot the issue of toggles not closing. Perhaps that duplicate can help with this <p> issue as well.

CommMgr

#537322

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Chris,

Thanks for reminding, I still have this duplicator setup.

Could you let me know which view is having this issue ?

Thanks,
Shane

#537332

Hi, Shane...

It is Template for SESSIONS. I'm not sure the template was on the site when you duplicated it. I have been working on it for the past 2 days.

CommMgr

#537807

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Chris,

I was able to replicate this issue even in a fresh the duplicator package.

We have a shortcode that should help to remove the auto paragraphs, could you try using this and let me know if it helps.
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-noautop

Please let me know if this helps.

Thanks,
Shane

#539187
li_adding_p_screenshot2.JPG

Hi, Shane...

Thank you for the shortcode suggestion. It did not help. It is still adding the (p) to the (li) code (see screenshot).

And this is only happening in the (li) section.

For reference, here is my code that includes your suggested shortcode:

<!-- LEARNING OBJECTIVES -->
<div style="font-size: 16px; font-weight: 600; color: #5b8703; padding: 20px 0 5px; line-height: 1.5em;">LEARNING OBJECTIVES</div>
<ul>
  [wpv-noautop]
  <li>[types field='learning-objective-1'][/types]</li>
  <li>[types field='learning-objective-2'][/types]</li>
  <li>[types field='learning-objective-3'][/types]</li>
  <li>[types field='learning-objective-4'][/types]</li>
  [/wpv-noautop]
</ul>

Thank you for your continued assistance.
CommMgr

#539194

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Chris,

I have one more scenario for you to test before I escalate this issue.

Try doing it like this.

<li>[wpv-noautop]shortcode[/wpv-noautop]</li>

Thanks,
Shane

#539231

Hi, Shane...

Unfortunately, still didn't work. This is the code:

<!-- LEARNING OBJECTIVES -->
<div style="font-size: 16px; font-weight: 600; color: #5b8703; padding: 20px 0 5px; line-height: 1.5em;">LEARNING OBJECTIVES</div>
<ul>
  <li>[wpv-noautop][types field='learning-objective-1'][/types][/wpv-noautop]</li>
  <li>[wpv-noautop][types field='learning-objective-2'][/types][/wpv-noautop]</li>
  <li>[wpv-noautop][types field='learning-objective-3'][/types][/wpv-noautop]</li>
  <li>[wpv-noautop][types field='learning-objective-4'][/types][/wpv-noautop]</li>
</ul>

CommMgr

#539262

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Chris,

Since this is text data could you add output='raw' as an attribute to the shortcodes. The reason is that I would like to ensure that this was not something that was added by our development team.

Hopefully using the raw output will remove the p tags.

Thanks,
Shane

#539283

Hi, Shane...

Could you show me the exact code to use? I'm still learning about conditional coding.

Thanks...
CommMgr

#539288

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Chris,

Sure it should be like this types field='learning-objective-1' output='raw'][/types]

Thanks,
Shane

#539640

Hi, Shane...

The output=raw worked. I wound up having to use the raw code in another section as well to alleviate the added (p).

I appreciate your help.
CommMgr

The forum ‘Types Community Support’ is closed to new topics and replies.