Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7557533
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T12:09:23+00:00 2026-05-30T12:09:23+00:00

I would like my tinymce editor to allow all the html elements, include some

  • 0

I would like my tinymce editor to allow all the html elements, include some nested kind.

I read the documents at tinymce: http://www.tinymce.com/wiki.php/Configuration:valid_elements

And also confirmed by this post on Stackoverflow: TinyMce Allow all Html tag

I use valid_elements :"*[*]", in my tinymce options:

$('.page-tinymce-editor').tinymce({ 
    theme: 'advanced',
    theme_advanced_buttons1: "fontsizeselect,bold,italic,justifyleft,justifycenter,justifyright,justifyfull,bullist,numlist,undo,redo,link,unlink,code,image,uploadimage,uploadattachment",
    theme_advanced_buttons2: "",
    theme_advanced_buttons3: "",
    theme_advanced_toolbar_location: "top",
    theme_advanced_toolbar_align: "left",

    width : "660px",
    height: "1200",
    body_id :"article",
    valid_elements :"*[*]",
    skin: "wp_theme",
    relative_urls: false,
    content_css: "http://" + location.host + "/assets/screen.css",
    plugins: 'uploadimage,uploadattachment'
})

But there’s a nest condition in my html is still remove by tinymce. I have a piece of html like the following:

<span class="text">
<p> Lorem Ipsum Lorem Ipsum Lorem Ipsum Lorem Ipsum Lorem Ipsum Lorem Ipsum  </p>
</span>

which becomes this :

<p> Lorem Ipsum Lorem Ipsum Lorem Ipsum Lorem Ipsum Lorem Ipsum Lorem Ipsum  </p>

Tinymce removes the span outside the p tag. Other span tag are all fine. I studied the tinymce over and over, but didn’t come out any idea to fix this.

Is there way to fix it?

Thanks a lot

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T12:09:24+00:00Added an answer on May 30, 2026 at 12:09 pm

    I think this could not be done on tinymce side. Here is the post talking about it at Tinymce forum: http://www.tinymce.com/forum/viewtopic.php?pid=98807#p98807

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to setup TinyMCE to allow literally any HTML without any cleaning
I would like to insert some shortcodes in the wordpress editor (v 3.3+) The
I would like to know how to delete all the texts in the TinyMCE
I want to embed some HTML on my website... I would like that: SEO
I would like to make tinymce work in my CMS with IE but i
I have a tinyMCE instance and I would like to know when the user
I would like to add onMouseOver and onMouseOut events to an editor instance within
I have a page that has multiple TinyMCE editors on it. i would like
I would like to add a class to my formatselect options of the tinyMCE
I'm using the Edit-in-Place JQuery plugin, JEditable: http://www.appelsiini.net/projects/jeditable . I would like to use

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.