• Resolved patsky

    (@patsky)


    Is it possible to use paragraph tags or html in the tab content? It doesn’t seem to be working for me.

Viewing 1 replies (of 1 total)
  • Thread Starter patsky

    (@patsky)

    [edit] have solved this but for anyone else I’m adding this for completeness.

    I have a setup that uses custom post types created with PODS. I added tabbed content with three tabs to a custom template using [su_tabs]. This pulls in data from the content field and two custom fields created as PODS WYSIWIG fields.

    The content data formatted correctly into paragraphs but the data in the PODS fields did not. Manually adding paragraph tags in the editor correctly displayed on first save but any amendments to the text and the para tags disappeared.

    Looking at the PODS field options I noticed a tick box for wpautop output. It didn’t change anything but gave me a clue so I added wpautop() to my template code and success!! I’m not an expert programmer by any means so feeling chuffed with my efforts! Hope this helps someone else.

    Here’s what the code in the template looked like:

    changed from
    $my_tabshortcode .= $witness_bio;
    to
    $my_tabshortcode .= wpautop($witness_bio);

    • This reply was modified 1 year, 8 months ago by patsky.
    • This reply was modified 1 year, 8 months ago by patsky.
    • This reply was modified 1 year, 8 months ago by patsky.
Viewing 1 replies (of 1 total)
  • The topic ‘html in tab content?’ is closed to new replies.