What is a namespace?

In this article you will learn what a namespace is in PHP, how to create one and how to use it. So what is a namespace? Here is an intuitive way to think about namespaces: Imagine a filesystem on a computer. If functions and classes are files, then namespaces are directories. You can have tons …

Continue reading

Specified key was too long; Max Key Length is 1000 bytes

Fixing the error SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 1000 bytes is a very easy thing to do. That is, if you do not need to use the MyISAM storage engine. If you do not know the difference between MySQL’s storage engine MyISAM and InnoDB …

Continue reading

What is an Interface?

This article was written for beginners that may have programmed a while but have not yet encountered or found any use for interfaces. After this article the reader will have more knowledge about interfaces, what they’re actually good for and how to implement them.

Continue reading