<![CDATA[ [SOLVED] Ajaxsearch with TVs - MODX Community Forums]]> https://forums.modx.com/thread/?thread=96539 <![CDATA[ [SOLVED] Ajaxsearch with TVs]]> https://forums.modx.com/thread/96539/ajaxsearch-with-tvs#dis-post-522519
I have run the following snippet:

[!AjaxSearch? &ajaxSearch=`0` &ajaxSearch=`0` &showIntro=`0` &showResults=`0` &landingPage=`9` &advSearch=`allwords`!]


And my landing page has this snippet call:

[!AjaxSearch? &ajaxSearch=`0` &parents=`4` &tvPhx=`legoImages` &whereSearch=`content` &order=`pagetitle` &extract=`2:longtitle,introtext` &showPagingAlways=`1`!]


My TV has a value of `image` and is named legoImages. The results when called return a pagetitle and summary, but the image appears as a tiny empty square. Looking at the page source it shows
<img src="" height="" />


I have amended result.tpl to:

<div>
<a href="[+as.resultLink+]" title="[+as.longtitle+]">[+as.pagetitle+]</a>
<div>
<img src="[+as.LegoImages+]" height="[+as.legoImages:imgmaxheight=`120`+]" />
</div>
[+as.extractShow:is=`1`:then=`
<div><p>[+as.extract+]</p></div>
`+]
[+as.breadcrumbsShow:is=`1`:then=`
<span>[+as.breadcrumbs+]</span>
`+]
</div>


My search results dont appear to pull the image in? Can anyone see any obvious mistakes?
Regards,
SB]]>
distant_smile Mar 13, 2015, 06:26 PM https://forums.modx.com/thread/96539/ajaxsearch-with-tvs#dis-post-522519
<![CDATA[Re: Ajaxsearch with TVs]]> https://forums.modx.com/thread/96539/ajaxsearch-with-tvs#dis-post-522520 ]]> distant_smile Mar 13, 2015, 06:31 PM https://forums.modx.com/thread/96539/ajaxsearch-with-tvs#dis-post-522520