0

what is $ in php ?

13th Feb 2017, 3:17 AM
hossy
hossy - avatar
6 Answers
+ 5
MONEY BRUH!!!! Nah, seriously. They mean variables. $name = "hossy"; and that is a variable with your name.
13th Feb 2017, 3:19 AM
Nahuel
Nahuel - avatar
+ 5
Exactly. You don't use "var" in PHP, instead you use $ with no space between the var name.
13th Feb 2017, 3:33 AM
Nahuel
Nahuel - avatar
+ 2
$ is used to declare a variable. Like in C++ you would use int x you use $x. Or in JavaScript var x.
13th Feb 2017, 3:47 AM
Andre van Rensburg
Andre van Rensburg - avatar
+ 1
ahaa. tnx like this var name =" hossy" in JavaScript
13th Feb 2017, 3:25 AM
hossy
hossy - avatar
0
it use to declare variables
25th Feb 2017, 12:56 PM
Ayesha Sardar
Ayesha Sardar - avatar
0
$ in PHP can be used to declare a variable. (example: $w = "Hello World!";)
2nd Mar 2017, 2:22 AM
Jamie