Member-only story

PHP Late Static Binding Explained

Atakan Demircioğlu
Jotform Tech
Published in
2 min readJul 4, 2023

Here’s an interesting topic that I learned about in a surprising way while coding.

Late static binding

Before we start, let’s clarify some terms:

  • Late static binding (LSB) is the combination of late binding and static binding, two different concepts.
  • Static, in a very short summary, refers to making static calls when you don’t need any object creation.
  • Static binding (early binding) happens at compile time.

What is Static Binding?

Static binding refers to the process of resolving static method calls at compile-time. When a method is declared as static, it means that the method belongs to the class itself rather than an instance of the class.

Static binding is used when the method is called and is known at compile-time, based on the class from which the call is made. The decision of which method to call is made during the compilation phase, and the appropriate method is bound to the call.

What is PHP late static binding?

When a static method is called from a subclass that overrides the method, the static binding refers to the class where the method is called, rather than the class in which it is defined.

Create an account to read the full story.

The author made this story available to Medium members only.
If you’re new to Medium, create a new account to read this story on us.

Or, continue in mobile web

Already have an account? Sign in

Published in Jotform Tech

Welcome to Jotform official tech blog. Read about software engineering and how Jotform engineers build the easiest form builder.

Written by Atakan Demircioğlu

Passionate about blogging and sharing insights on tech, web development, and beyond. Join me on this digital journey! 🚀

No responses yet

What are your thoughts?