title: Create a PHP Object using an Array List dynamically
body: <p>I want to create an Object in PHP using, as element, a list of fields taken from an array list obtained from a function outside the class. I need to do that dinamically, cause I have to compile the array from a DB and this list of data could change. Is this possible?
  I've a function called:</p>
  
  <pre><code>public $classKeyword = "contratti";
  public $arrayList = getDbTableStructure($classKeyword);
  </code></pre>
  
  <p>And this function return me the array list and I'll cicle it to build the object. This function work in all other the project (not using class), but seems not working if I call it from a class... I'm losing something?</p>