Within a single class, I am able to use the _call/_callStatic functions to call a function before any function is actually run. However, I'm yet to find a solution that I can apply to the parent, and it will be inherited by the children.
The only method I can think of is putting a small snippet of code within each class that calls a function in the parent, which contains my code.
Are there any better solutions that I can implement?
__call
does get inherited by child-classes. And it doesn't get run 'before any function is actually run'. It is being called when the function you're actually calling doesn't exists (or is inaccessible in that scope). Your question isn't very clear to me. Can you add some demo-code?