We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 19192
    • 6 Posts
    Hi everyone, i need to solve this problem because it makes me dizzy for some last days.
    My problem is when I write html code that have quote sign (""), after I click save button, my code will generated automatically with backslash (\). Indeed when I save more than one, the backslash also will add directly.

    !DOCTYPE html PUBLIC \\\\\\\\\\\\\\\"-//W3C//DTD XHTML 1.1//EN\\\\\\\\\\\\\\\" \\\\\\\\\\\\\\\"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd\\\\\\\\\\\\\\\">
    <html xmlns=\\\\\\\\\\\\\\\"http://www.w3.org/1999/xhtml\\\\\\\\\\\\\\\">
    <head>
    <meta http-equiv=\\\\\\\\\\\\\\\"Content-Type\\\\\\\\\\\\\\\" content=\\\\\\\\\\\\\\\"text/html; charset=utf-8\\\\\\\\\\\\\\\" />
    <title>Untitled Document</title>
    <style>


    Above code is the example after I click save button more times, anyone please answer the possibilities. It happened because of virus on my server or what? Because when I config using another server, MODx won’t appear this suck code.

    Please reply..thank you so much smiley
      • 3749
      • 24,544 Posts
      You need to disable magic_quotes_gpc.

      http://php.net/manual/en/security.magicquotes.disabling.php
        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
        • 19192
        • 6 Posts
        Thank you Bob. I’ll try to call my host admin to turn it off for me, because when I tried to adding "php_flag magic_quotes_gpc Off" in .htaccess I got Internal Server Error instead.
        But, thank you for the enlightenment, I don’t know about magic quotes before.
        Thx smiley