Jump to content


Photo
- - - - -

Visual Editor stripping code when toggling


  • Please log in to reply
3 replies to this topic

#1 alisamski

alisamski

    Advocate

  • Members

  • 482 posts
  • Framework Version:DMS 2 | DMS 1 | Frameworks | Child Theme
  • Country: Country Flag

Posted 29 March 2013 - 08:55 PM

Implemented some css code inside a grid on the front page.

I have both divs and tables to achieve the grid...

 

Please Login or Register to see this Hidden Content

 

1. First of all, I cannot toggle between visual and html in the editor or else it strips out all table info. Then making the grid not work.

 

2.  the divs are not responsive, and wondered if anyone has any suggestions?

 

Editor plugin is Advanced Tinymce and the I did select (NOT to strip out <p> and <br/>

 

Thanks

 



#2 James B

James B

    Advocate

  • Members

  • 5126 posts
  • LocationSurrey - UK
  • Country: Country Flag

Posted 29 March 2013 - 09:09 PM

Hi there,

 

It could be the plugin editor is adding the additional breaks.

 

When using the wp editor I find that its best to put the html directly into the text view as if you go back and make edits on the visual view it can cause the display to alter.

 

Try wrapping your shortcode/html in [pl_raw] tags as per the demo on

Please Login or Register to see this Hidden Content

in the text view, this should hopefully stop the breaks from occurring.

 

If not, try disabling the tinymce plugin to see if it's conflicting and if the code works without it.



#3 alisamski

alisamski

    Advocate

  • Members

  • 482 posts
  • Framework Version:DMS 2 | DMS 1 | Frameworks | Child Theme
  • Country: Country Flag

Posted 30 March 2013 - 01:03 PM

Tried both... disabled plugins and tried adding the [pl_raw] before and [/pl_raw]after the table... still breaks when toggling...

 

More importantly... I cannot get this table to be responsive...

 

aarrgh.



#4 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 30 March 2013 - 01:55 PM

Hi,

 

The Text editor tab is where we recommend that the grid code or any HTML code be placed.  When swapping over to Visual Mode, you shouldn't see it -- only the results of the code, but going back to Text should not strip the code. It's possible some plugin is doing this, but I've tested it on my own site and have had no issues.

 

Is this an HTML 'table' or the our Grid found here? 

Please Login or Register to see this Hidden Content

 

It's possible that the editing plugin simple isn't designed to deal with the code you're using.  I'd recommend disabling it to see if it works without using that plugin.