Add Reviews to Buy Product Dialog with NVelocity
Posted: Fri Sep 14, 2012 8:39 am
I've tried a few different approaches without any success. Due to structure/layout requirements, I need to add reviews to the BuyProductDialog,ascx file. Adding the reference itself is fine. The challenge is how to do this while still using the #if statements normally found in the Show Product 1.htm file. Does anyone have any ideas for how I can still use conditional statements when referencing the reviews conlib as a user control? Thanks!!
From Show Product 1.htm:
#if($store.Settings.ProductReviewEnabled != "None")
#if($store.Settings.ProductReviewEnabled == "Registered")
#if($customer.IsAnonymous == false)
[[ConLib:ProductRatingImage]] <a href="#reviews">reviews</a>
#end
#end
#if($store.Settings.ProductReviewEnabled == "Anonymous")
#if($customer.IsAnonymous == true)
[[ConLib:ProductRatingImage]] <a href="#reviews">reviews</a>
#end
#end
#if($store.Settings.ProductReviewEnabled == "All")
[[ConLib:ProductRatingImage]] <a href="#reviews">reviews</a>
#end
#end
From Show Product 1.htm:
#if($store.Settings.ProductReviewEnabled != "None")
#if($store.Settings.ProductReviewEnabled == "Registered")
#if($customer.IsAnonymous == false)
[[ConLib:ProductRatingImage]] <a href="#reviews">reviews</a>
#end
#end
#if($store.Settings.ProductReviewEnabled == "Anonymous")
#if($customer.IsAnonymous == true)
[[ConLib:ProductRatingImage]] <a href="#reviews">reviews</a>
#end
#end
#if($store.Settings.ProductReviewEnabled == "All")
[[ConLib:ProductRatingImage]] <a href="#reviews">reviews</a>
#end
#end