0

i use certain suffix in my variable name, a combination of an underscore and a property. such as :

$variable_html = variable that will be parse in html code.

$variable_str = string variable

$variable_int = integer variable

$variable_flo = float variable.

Do you have other visual clues? Maybe something you write for variable, function name, class strucure, or other stuff that helps others to read and not only for compiler ?

skaffman
  • 398,947
  • 96
  • 818
  • 769
justjoe
  • 5,454
  • 9
  • 44
  • 64
  • possible duplicate of [Do people use the Hungarian Naming Conventions in the real world?](http://stackoverflow.com/questions/5428/do-people-use-the-hungarian-naming-conventions-in-the-real-world) – Gordon Aug 09 '10 at 14:49
  • Just a note; PHP is an interpreted language, there is no compiler here. – user254875486 Aug 09 '10 at 14:49

2 Answers2

5

You're describing Hungarian Notation: Do people use the Hungarian Naming Conventions in the real world?

There's lots of discussion on Stack Overflow about people's feelings on the topic.

Community
  • 1
  • 1
Scott Stafford
  • 43,764
  • 28
  • 129
  • 177
1

It nearly is Hungarian Notation, but when you use Hungarian Notation it is more common to use a prefix instead of a suffix.

0x90
  • 293
  • 2
  • 9