/** * Gets a string representation of the array * @param type $value_on_field_to_be_outputted * @param string $schema, possible values are ',', others can be added * @return string */ function prepare_for_pretty_echoing($value_on_field_to_be_outputted, $schema = null) { switch ($schema) { case 'print_r': $pretty_value = print_r($value_on_field_to_be_outputted, true); break; case 'as_table': $pretty_value = EEH_Template::layout_array_as_table($value_on_field_to_be_outputted); break; default: $pretty_value = implode(", ", $value_on_field_to_be_outputted); } return $pretty_value; }