php - Not using a form to send form data -


to prevent spam i'm thinking of removing <form>and send data input fields ajax instead.

on php side use make safer:

$clean = strip_tags($html, '<p><br>');

any pitfalls?

myself use ajax instead sometimes, downside me ajax have not been able send files (e.g. images) @ least without jquery.

so, if don't need send files ok or @ least sometimes, although reason say: spam, don't


Comments

Popular posts from this blog

php - Invalid Cofiguration - yii\base\InvalidConfigException - Yii2 -

How to show in django cms breadcrumbs full path? -

ruby on rails - npm error: tunneling socket could not be established, cause=connect ETIMEDOUT -