I am using CodeIgniter v 3.1.4. In one of the form, i have a text box to save urls (like https://stackoverflow.com/questions/ask, http://google.com etc.) into the MySql database.
Before save, i am sanitizing the urls like shown below:
Inside Constructor:
$this->load->helper('security');
Inside Add function:
$hlt_url = $this->security->xss_clean($this->input->post('txtHLnk'));
$hlt_hlines = $this->security->xss_clean($this->input->post('txtAreaHLine'));
When i enter simple/plain string in the textboxes, then the data gets saved in the DB, however when i enter url in the textboxes, the data is not saved in DB, neither does it show any error message.
Please explain with code whats i am doing wrong. Thanks