For the longest time, this worked perfectly (Copy and pasting here may make it look broken - I hate that):
Now it refuses to display the "main" image, period.
Now what is interestingly odd, this code still works (again ignore any breaks that copy & paste may have caused):
I thought maybe I should try some of the code I have posted in the past (something that worked in 2019 and again ignore any spaces in the coding...):
There are a number of Toolkit functions that we all have come to rely on that now are dying a slow painful death. I'll be happy to continue posting ones that need to be converted because I know there are others out there that need this stuff too.
Code:
<mvt:item name="toolkit" param="footsteps|fcount|9" /> <mvt:if expr="g.fcount GT 0"> <div class="row bottom-shadow product-carousel nm"> <div class="column whole h3"><span class="uppercase">You Recently Viewed</span></div> <div id="js-footsteps-products-carousel" class="column whole float-none whats-popular-carousel"> <mvt:foreach iterator="footstep" array="footsteps"> <mvt:if expr="l.settings:product:customfield_values:custom fields:product_flag NE 'none'"> <mvt:assign name="l.settings:product:flag" value="'flag--' $ tolower(l.settings:product:customfield_values:customfields:product_flag)" /> </mvt:if> <div class="category-product"> <a href="/&mvta:footstep:code;.html"><span class="flag flag--price" data-flag="$&mvt:footstep:price;"> <mvt:item name="toolkit" param="customimage|ipath|l.all_settings:footstep:id|main|200|150|" /> <mvt:if expr="g.ipath"> <img src="graphics/00000001/loading.gif" data-src="&mvt:global:ipath;" alt="&mvt:footstep:name;" style="height:150px;" /> <mvt:elseif expr="NOT ISNULL l.settings:footstep:thumbnail"> <img src="graphics/00000001/loading.gif" data-src="&mvt:footstep:thumbnail;" alt="&mvt:footstep:name;" style="height:150px;" /> <mvt:else> test: no image found </mvt:if></span> <span class="breaker"></span></a> <div class="revstars"> <mvt:item name="productreviews" param="stars|footstep:id" /> <mvt:if expr="g.ReviewStars"> &mvt:global:ReviewStars; <a class="openreviews" href="/&mvta:footstep:code;.html#reviewbox"><span style="font-weight:normal;">(&mvt:global:Total_Reviews;)</span></a></mvt:if> </div> </div> </mvt:foreach> </div> </div> </mvt:if><!-- end of footsteps -->
Now what is interestingly odd, this code still works (again ignore any breaks that copy & paste may have caused):
Code:
<mvt:item name="toolkit" param="visitors|vcount|'9'|'prod'|1" /> <mvt:if expr="g.vcount GT 0"> <div class="row bottom-shadow product-carousel nm"> <div class="column whole h3"><span class="uppercase">Shoppers Are Viewing</span></div> <div id="js-visitors-products-carousel" class="column whole float-none whats-popular-carousel"> <mvt:foreach iterator="visitor" array="visitors"> <mvt:if expr="('prod' CIN l.settings:visitor:screen) GT 0"> <mvt:if expr="l.settings:product:customfield_values:custom fields:product_flag NE 'none'"> <mvt:assign name="l.settings:product:flag" value="'flag--' $ tolower(l.settings:product:customfield_values:customfields:product_flag)" /> </mvt:if> <div class="category-product"> <a href="/&mvt:visitor:code;.html"><span class="flag flag--price" data-flag="$&mvt:visitor:price;"> <mvt:item name="toolkit" param="customimage|ipath|l.all_settings:visitor:id |main|200|150|" /> <mvt:if expr="g.ipath"> <img src="graphics/00000001/loading.gif" data-src="&mvt:global:ipath;" alt="&mvt:visitor:name;-main" style="height:150px;" /> <mvt:elseif expr="NOT ISNULL l.settings:visitor:thumbnail"> <img src="graphics/00000001/loading.gif" data-src="&mvt:visitor:thumbnail;" alt="&mvt:visitor:name;-legacy" style="height:150px;" /> <mvt:else> test: no image found </mvt:if></span><span class="breaker"></span></a> <div class="revstars"> <mvt:item name="productreviews" param="stars|visitor:id" /> <mvt:if expr="g.ReviewStars"> &mvt:global:ReviewStars; <a class="openreviews" href="/&mvta:visitor:code;.html#reviewbox"><span style="font-weight:normal;">(&mvt:global:Total_Reviews;)</span></a></mvt:if> </div> </div> </mvt:if> </mvt:foreach> </div> </div> </mvt:if><!-- end of visitors -->
<mvt:item name="toolkit" param="footsteps|fcount|9" />
<mvt:if expr="g.fcount GT 0">
<div class="row bottom-shadow product-carousel nm">
<div class="column whole h3"><span class="uppercase">You Recently Viewed</span></div>
<div id="js-footsteps-products-carousel" class="column whole float-none whats-popular-carousel">
<mvt:foreach iterator="footstep" array="footsteps">
<mvt:if expr="l.settings:product:customfield_values:custom fields:product_flag NE 'none'">
<mvt:assign name="l.settings:product:flag" value="'flag--' $ tolower(l.settings:product:customfield_values:cust omfields:product_flag)" />
</mvt:if>
<div class="category-product">
<a href="/&mvta:footstep:code;.html"><span class="flag flag--price" data-flag="$&mvt:footstep:price;">
<mvt:item name="toolkit" param="customimagec|ipath|l.all_settings:footstep: code|main|200|150|" />
<mvt:if expr="l.settings:toolkitadditionalimages[1]:generated:image">
<img src="graphics/00000001/loading.gif" data-src="&mvt:global:imageroot;&mvte:toolkitadditional images[1]:generated:image;" alt="&mvt:footstep:name;-main" style="height:150px;" />
<mvt:elseif expr="NOT ISNULL l.settings:footstep:thumbnail">
<img src="graphics/00000001/loading.gif" data-src="&mvt:footstep:thumbnail;" alt="&mvt:footstep:name;-legacy" style="height:150px;" />
<mvt:else>
test: no image found
</mvt:if></span>
<span class="breaker"></span></a>
<div class="revstars">
<mvt:item name="productreviews" param="stars|footstep:id" />
<mvt:if expr="g.ReviewStars"> &mvt:global:ReviewStars; <a class="openreviews" href="/&mvta:footstep:code;.html#reviewbox"><span style="font-weight:normal;">(&mvt:global:Total_Reviews;)</span></a></mvt:if>
</div>
</div>
</mvt:foreach>
</div>
</div>
</mvt:if><!-- end of footsteps -->
<mvt:if expr="g.fcount GT 0">
<div class="row bottom-shadow product-carousel nm">
<div class="column whole h3"><span class="uppercase">You Recently Viewed</span></div>
<div id="js-footsteps-products-carousel" class="column whole float-none whats-popular-carousel">
<mvt:foreach iterator="footstep" array="footsteps">
<mvt:if expr="l.settings:product:customfield_values:custom fields:product_flag NE 'none'">
<mvt:assign name="l.settings:product:flag" value="'flag--' $ tolower(l.settings:product:customfield_values:cust omfields:product_flag)" />
</mvt:if>
<div class="category-product">
<a href="/&mvta:footstep:code;.html"><span class="flag flag--price" data-flag="$&mvt:footstep:price;">
<mvt:item name="toolkit" param="customimagec|ipath|l.all_settings:footstep: code|main|200|150|" />
<mvt:if expr="l.settings:toolkitadditionalimages[1]:generated:image">
<img src="graphics/00000001/loading.gif" data-src="&mvt:global:imageroot;&mvte:toolkitadditional images[1]:generated:image;" alt="&mvt:footstep:name;-main" style="height:150px;" />
<mvt:elseif expr="NOT ISNULL l.settings:footstep:thumbnail">
<img src="graphics/00000001/loading.gif" data-src="&mvt:footstep:thumbnail;" alt="&mvt:footstep:name;-legacy" style="height:150px;" />
<mvt:else>
test: no image found
</mvt:if></span>
<span class="breaker"></span></a>
<div class="revstars">
<mvt:item name="productreviews" param="stars|footstep:id" />
<mvt:if expr="g.ReviewStars"> &mvt:global:ReviewStars; <a class="openreviews" href="/&mvta:footstep:code;.html#reviewbox"><span style="font-weight:normal;">(&mvt:global:Total_Reviews;)</span></a></mvt:if>
</div>
</div>
</mvt:foreach>
</div>
</div>
</mvt:if><!-- end of footsteps -->
Comment