PHP 7.2
Apache 2.4
Beim versuch des Impirts (Doppelklick auf Icon) kommt jedoch folgender Fehler:
Code: Alles auswählen
supplied for foreach() in /volume1/web/homehub/app/Components/autoload.php on line 18
Code: Alles auswählen
<?php
// Load all custom files
foreach (glob(__DIR__.'/custom/*.php') as $file) {
require_once($file);
}
// Load standard files based on export.txt
$config_file = realpath(__DIR__.'/../Config/export.json');
if(file_exists($config_file)) {
$str = file_get_contents($config_file);
if (strlen($str) > 0){
$export = json_decode($str, true);
$components = array_unique(array_column($export['channels'], 'component'));
foreach($components as $component) {
$func = str_replace('-', '_', $component);
if(!function_exists($func)) {
$component_file = __DIR__.'/'.$component.'.php';
if(file_exists($component_file)) {
require_once($component_file);
}
}
}
}
if(!function_exists('Program')) {
require_once(__DIR__.'/Program.php');
}
if(!function_exists('SysVar')) {
require_once(__DIR__.'/SysVar.php');
}
}