Embedding a Product in a Post

If you want to display a product in a post, this is possible by creating a new view and embedding that view into the post. Here's how.

  1. Create a new Custom View.  Name it something like Embedded Product. Give the view the following settings in View Properties:
  2. Add a Product detail module to this view.
  3. Add the following code to the template area of the Product detail module:
    <div class="embedded fl">
    	<div class="t1">
    		<div class="bdr">
    			<h2><a href="[product.link]" title="[product.name]">[product.name]</a></h2>
    			<div class="thmb">
    				<a href="[product.link]" title="[product.name]"> <img alt="[product.name]" class="thmb1" src="[product.image]" /></a>
    			</div>
    			<div class="prc">
    				[product.currency mode="sign"][product.price]
    			</div>
    			<div class="btns">
    				<a class="dfbutton dforange dfmedium" href="[product.link]" title="View details [product.name]">Details</a> 
    				<a class="dfbutton dforange dfmedium" href="[product.url direct='0']" title="Buy [product.name]">Buy</a>
    			</div>
    			<div class="clearingdiv">   </div>
    		</div>
    	</div>
    	<div class="clearingdiv">   </div>
    </div>
  4. Update your store's settings here: WordPress Admin Area > Tools > Datafeedr.
  5. To add this view to a specific post, add this shortcode to your post where 123456 is the product's ID you want to embed. [DFR:Embedded Product?p=123456]