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 3496994
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T12:19:00+00:00 2026-05-18T12:19:00+00:00

I am yet to find an actual solution to this problem. In FCKeditor 2,

  • 0

I am yet to find an actual solution to this problem.

In FCKeditor 2, when using PHP integration method, any html element that is passed to the editor will have the css styling stripped form it.

Therefore this:

<div style="color:#000;background:blue">hello</div>

will end up as this:

<div>hello</div>

I can confirm that the editor will pass the styling correctly upon saving it, but if you load it into the editor, it is stripped out and thus on 2nd save, is removed.

The only 2 solutions, which unfortunately aren’t solutions for me, are to either use Javascript Integration, which doesn’t work with my coding structure or to turn off Magic Quotes. While I would like to turn off magic quotes as its not recommended to rely on it, I don’t have the time at the moment to go through my rather large code base to ensure that doing this won’t break something somewhere else.

So, I am asking how this can be resolved with FCKeditor 2 using PHP integration with magic quotes enabled? I have already removed ‘style’ from FCKConfig.RemoveAttributes in fckeditor.js

Please don’t offer solutions like “upgrade to CKeditor”, “use javascript integration” and “turn off magic quotes” as that would defeat the purpose of this post. Thank you for any help and hopefully it finding a solution will help many others with the same problem.

David

  • 1 1 Answer
  • 3 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-18T12:19:01+00:00Added an answer on May 18, 2026 at 12:19 pm

    To be more direct than @Marek’s answer –

    Instead of turning off magic quotes, on the PHP side you can detect if magic quotes are enabled using get_magic_quotes_gpc(), and use stripslashes() to undo them if they are.

    $html = $_POST['html']; // as an example
    if (get_magic_quotes_gpc()) $html = stripslashes($html);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This is a fairly common problem to which I have yet to find an
I have searched online for a solution, but have yet to find one that
This is a simple question yet I was unable to find any information at
I'm still yet to find a decent solution to my scenario. Basically I have
I know this has been asked many times but i'm yet to find a
yet I didnt find a jquery function that validate value to be a future
I did not find any suitable questions answered yet, so I'd like to know
I have yet to find a good resource that doesn't include GLUT as it's
I have encountered a problem that I have not come accross yet when setting
This is a design problem I face regularly and I'd like to find some

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.