Codeigniter - Disable XSS filtering on a post basis

后端 未结 7 1762
予麋鹿
予麋鹿 2020-12-03 03:25

I\'m trying to set up a CMS on the back of a site but whenever post data has a in it the post data gets scrapped.

I\'ve got $config

7条回答
  •  遥遥无期
    2020-12-03 03:43

    Yes, the extension to Input with the post method replacement was very useful, as was the astute reader who notice that it should be return parent::post($index, $xss_clean). I was getting errors and didn't think about that obvious error. Fixed it and I'm off and running.

    We're using it to escape post data for use in sql statements. Although CI's db methods are nice, we have some large sql statements that are easier to code by hand.

提交回复
热议问题