i wont to know why we have to equal this variabel what is theri meaning
$contact_name = $_POST['contact_name'];
$contact_email = $_POST['contact_email'];
$contact_text = $_POST['contact_text'];
i wont to know why we have to equal this variabel what is theri meaning
$contact_name = $_POST['contact_name'];
$contact_email = $_POST['contact_email'];
$contact_text = $_POST['contact_text'];
That is an assignment, not an equality operator (which is ==
).
That's a requirement. If you won't do that, the compiler won't compile the source code.
With all due respect, I'm rather confused by the previous reply (and its up-voting), as it is flat out incorrect. Compiler? PHP is originally an interpreted language. Yes there are compilers, but they are not required for running PHP scripts. Further, the code the OP posted is most likely not required to run a script.
Usually the purpose of the code you posted, andyy121, is to provide short-named variables for the values stored in $_POST['___']
. So instead of having to always type $_POST['contact_name']
every time you want to refer to this value, you can refer to $contact_name
. Further, now if you have to modify this value you can do so without changing the values stored in the $_POST superglobal variable.
~ EF
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.