Jump to content

Can one combine functions and variables?


VirusDoctor

Recommended Posts

<?php
$strip_html[1] = strip_tags (sql_safe(trim($_POST["name"])));
?>

 

Would this be valid?

 

Firstly as you can see, strip_html[1] is a variable.

 

sql_safe is a sql injection prevention function.

 

What I would like to know is, can one create a variable like this, using strip_tags, trim and the function in one?

Link to comment
https://forums.phpfreaks.com/topic/78439-can-one-combine-functions-and-variables/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.