why is $ sign used before variables in Php? what does it means? | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
0

why is $ sign used before variables in Php? what does it means?

what does that $ sign means actualy?

14th Aug 2019, 7:22 PM
Anurag Kasudhan
1 ответ
+ 2
The use of the $ sign results from historical reasons. PHP was originally developed as a replacement for the Perl language. Variables in Perl also use a $ sign. Perl, in turn, originates from miscellaneous Unix-scripting languages. Those Unix shell variables typically used (and still use) the $ sign as prefix, to access their values.
14th Aug 2019, 7:47 PM
Michael
Michael - avatar