title: PHP Plugin loader which creates instance of plugins in a specific directory and which impelements plugin interface
body: <p>how can i create with php an instance of all plugins which implements the plugin interface an which are saved in a specific plugin directory.</p>
  
  <p>I did something in c# like that</p>
  
  <pre><code>Assembly assembly = Assembly.LoadFrom(pFileName);
  foreach (Type type in assembly.GetTypes()){
  if (type.IsPublic){
  if (!type.IsAbstract){           
  Type typeInterface = type.GetInterface(pTypeInterface.ToString(), true);
  if (typeInterface != null){
  try{
  object plugin = Activator.CreateInstance(pluginInterfaceType);
  </code></pre>
  
  <p>Is there a way to translate this in php?</p>
  
  <p>Whats the easiest and securest way to realise this?</p>
  
  <p>greetings</p>