I was able to reproduce a similar issue on the XenForo demo. The first line was rendering/appearing, but the image URL had some garbage characters in it, so the image showed as a big red X.
In
library/vw/XenForo/BbCode/Formatter.php, find:
Code:
return parent::renderValidTag($tagInfo, $tag, $rendererStates);
Replace with:
Code:
if ($this->vwParserEntry)
{
$this->_vwFromWikiTag = array(
'tag' => $tag['tag']
);
}
$retval = parent::renderValidTag($tagInfo, $tag, $rendererStates);
$this->_vwFromWikiTag = false;
return $retval;
Find:
Code:
$compileTags = $this->parser->get('_vwCompileTags');
Replace with:
Code:
$compileTags = $this->parser->get('_vwTemplateTags');
This change corrected the issue as it was occurring for me. Example here:
https://www.vaultwiki.org/xf-wiki/in...dered-Template
You should also make sure that the page where you use the template has "Automatically parse links in text" NOT checked; or you could end up with something like:
Code:
[img][url]avatar-url[/url][/img]
which will probably not work.
If you must use that checkbox for some reason, or if the checkbox is missing, you must wrap the URL in PLAIN tags. This is only necessary when passing in a fully-qualified URL in order to workaround XenForo's automatic link parsing behavior. Alternatively, if you construct your template to handle partial/relative URLs (such as if all images are located in the same folder), then it will probably not trigger automatic link parsing.