There’s:
$myvar="somthing";
and:
define('myvar', 'something');
I know the first one is defining a variable and I thought the second one was too, until someone told me its not…
Whats the difference between the two? They both do the same things right?
The second one creates a constant. Syntactically, it’s a lot like a variable, except that it can’t be varied.
See http://php.net/manual/en/function.define.php, or more generally http://www.php.net/manual/en/language.constants.php.