// ob_end_clean();
// $this->compiler->log("##### Multimedia Link getHTMLContent ID: {$this->id} | {$this->to} ######\n\n!!!! BACKTRACE !!!!!\n$trace\n===============\n");
- foreach ($this->_config['inject'] as $i) {
- $infos = ['path' => 'data/links/' . str_replace('.', '_', $this->to) . '/'];
- $i = str_replace('$id', '"#l_' . $this->id . '"', $i);
- $i = str_replace('$path', '"' . $infos['path'] . '"', $i);
- $i = str_replace('$init', Json::encode($infos), $i);
- // Key the array with the ID so we don't get duplicates even when this function is called multiple times
- $this->compiler->HTMLMultimedia[$this->id] = $i;
+ if(isset($this->_config['inject'])) {
+ foreach ($this->_config['inject'] as $i) {
+ $infos = ['path' => 'data/links/' . str_replace('.', '_', $this->to) . '/'];
+ $i = str_replace('$id', '"#l_' . $this->id . '"', $i);
+ $i = str_replace('$path', '"' . $infos['path'] . '"', $i);
+ $i = str_replace('$init', Json::encode($infos), $i);
+ // Key the array with the ID so we don't get duplicates even when this function is called multiple times
+ $this->compiler->HTMLMultimedia[$this->id] = $i;
+ }
}
+
if (isset($this->_config['injectcss'])) {
foreach ($this->_config['injectcss'] as $i) {