FAQ Database Discussion Community


Library or API for inferring country/location based on submitted string?

python,django-models,geolocation,input-sanitization
I'm retroactively sanitizing a bunch of data for the Offer Drive product (http://offerletter.io/drive.html). I'm trying to normalize a freeform "location" field to determine if submitted locations fall in the United States (or not). Values may vary in granularity, but all are "real", e.g. San Francisco, CA Milwaukee Bangalore My question...

PHP - remove http/www from message (except for the host domain) to disable clickable links

php,html,url-parsing,input-sanitization
I have a simple message board, let's say: mywebsite.com, that allows users to post their messages. Currently the board makes all links clickable, ie. when someone posts something that starts with: http://, https://, www., http://www., https://www. then the script automatically makes them as links (ie. adds the A href.. tag)....

safest way to take user input, put it on database, and the output it using php [closed]

php,codeigniter,xss,sanitization,input-sanitization
this is the most confusing part i encountered today, i'm using codeigniter, but it's xss filter doesn't seem to work properly as we expect, so we tried using htmlentities while saving the data into the database, but i read somewhere, we should never change/edit the user inputed data into database,...

Wordpress Core Data Validation Functions not working

php,wordpress,security,wordpress-theming,input-sanitization
I'm developing a Custom Theme for a Wordpress site and I want to use Wordpress Core Data Validation Functions to validate the info from some forms. Every time I try to use the sanitize_text_field() function I get this error: Fatal error: Call to undefined function sanitize_text_field(). I've read many posts...