Analgiins Posted February 6, 2007 Report Share Posted February 6, 2007 Rādās, ka PHP 5.1.6 neļauj statiskai metodei piekļut pie $this mainīgā, izmet erroru: Fatal error: Using $this when not in object context in <path-to-file> on line 782, lai gan objekts jau sen ir izveidots. Noņem static keywordu - viss aiziet! Tas ir pareizi vai kā?? Link to comment Share on other sites More sharing options...
v3rb0 Posted February 6, 2007 Report Share Posted February 6, 2007 javā ar tā ir, tad gan jau ka tā jābūt. Link to comment Share on other sites More sharing options...
bubu Posted February 6, 2007 Report Share Posted February 6, 2007 Statiska metode taču neizpildās kāda konkrēta objekta kontekstā. Tāpēc tai jau nemaz nevar būt $this mainīgais. Link to comment Share on other sites More sharing options...
Recommended Posts