when to use self over 24this

Solutions on MaxInterview for when to use self over 24this by the best coders in the world

showing results for - "when to use self over 24this"
Alina
16 Apr 2017
1class X {
2    private $non_static_member = 1;
3    private static $static_member = 2;
4
5    function __construct() {
6        echo $this->non_static_member . ' '
7           . self::$static_member;
8    }
9}
10
11new X();
similar questions
queries leading to this page
when to use self over 24this