1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

HTML markup importing

Discussion in 'Troubleshooting and Problems' started by Judo, Apr 29, 2011.

  1. Judo

    Judo Member

    I am trying to import some HTML from another forum, however linebreaks and paragraphs are being rendered as code on the page - ie showing <p> and <br /> tags. Is there a way to convert these?

    I took a look at the text inserted into the message field of the xf_post table but I cant figure out what character(s) are used to denote line breaks...

    Also, the post_date field in xf_post - is this in ticks?

  2. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    You can install this addon to cleanup imported posts:


    This requires some regex ability though.

    It's a unix timestamp:

  3. Judo

    Judo Member

  4. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

  5. Judo

    Judo Member

    Thanks, but that looks a little scary allowing any html tags between [parsehtml] - I just needed to do this once on the import. A solution seems to be to render the html before running the sql insert - this scrubs tags like <em> but at least removes them and <p> and <br> tags work out fine.

Share This Page