We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 22656
    • 121 Posts
    Im using this for custom fields which go into a custom database - actually $modx->db->escape($modx->stripTags($_POST[’my_value’]));
    Problem is this keeps adding backslashes to special characters, ie if the POST var contains

    Rob’s Title

    it will be inserted as Rob/’s Title

    How do I avoid this whils still retaining the protection against SQL injection?