The following JavaScript is used here to rotate the featured product every 30 seconds. I will leave the implementation of the JSON-emitting REST api for another post.
<!--mce:0--> <!--mce:1--> <!--mce:2--> <div class="outerbox"></div> <textarea> <div class="outerbox"> <div class="box featured"> <h2 > Featured</h2> <div class="item"> <div class="bord-se"> <div class="bord-ne"> <div class="bord-s"> <a href="/store/Product.aspx?ProductId={$T.ProductId}&utm_source=Homepage&utm_medium=FeaturedProd&utm_term=Widget&utm_campaign=Featured_Widget" mce_href="/store/Product.aspx?ProductId={$T.ProductId}&utm_source=Homepage&utm_medium=FeaturedProd&utm_term=Widget&utm_campaign=Featured_Widget" id="A1"> <img class="FeaturedProduct" src="{$T.ThumbnailUrl}" mce_src="{$T.ThumbnailUrl}" alt="featured" style="border-width:0px;" mce_style="border-width: 0px;" /> </a> </div> </div> </div> </div> <h4> <a href="/store/Product.aspx?ProductId={$T.ProductId}&utm_source=Homepage&utm_medium=FeaturedProd&utm_term=Widget&utm_campaign=Featured_Widget" mce_href="/store/Product.aspx?ProductId={$T.ProductId}&utm_source=Homepage&utm_medium=FeaturedProd&utm_term=Widget&utm_campaign=Featured_Widget">{$T.Name}</a></h4> <span>Author: </span> <a href="/store/search.aspx?m={$T.AuthorId}" mce_href="/store/search.aspx?m={$T.AuthorId}">{$T.Author}</a> <span class="Price"> ${$T.Price}</span> {$T.Summary} <a class="more" href="/store/New-Products-C52.aspx" mce_href="/store/New-Products-C52.aspx">view all…</a> </div> </div> </textarea> |