Untitled UI logotext
Solutions
WebsitesEcommerceMobile AppsWeb AppsProduction Support & Maintenance
Our work
Company
About usBlogPodcastContact us
Book a free consultation

PHP self Keyword

Olivia Rhye

The self keyword is one I hadn't learned. It's equivalent to using $this in a static context, so: self::callStaticMethod();.

I had classes where I was using Classname::getConn(); and having to change Classname every time I change classes. This allows me to do so without that change.

Ready to start a project?

Book a free consultation
Untitled UI logotext
Our work
About us
Blog
Careers
Submit a ticket
Agency Partnerships
Contact
© 2024 fjorge. All rights reserved.
Privacy