Announcement

Collapse
No announcement yet.

Add Product Image to OUSM

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Add Product Image to OUSM

    I am wondering if anyone has modified the OUSM (Checkout: Upsell Product Multiple) page to include the upsell product image and hyper link to the product page? I can't seem to get it to work. Any help would be great! Thanks


    OUSM Page:

    <mvt:item name="html_profile" />
    <head>
    <mvt:if expr="NOT ISNULL l.settings:page:title">
    <title>&mvt:page:title;</title>
    <mvt:else>
    <title>&mvt:store:name;: &mvt:page:name;</title>
    </mvt:if>
    <mvt:item name="head" param="head_tag" />
    </head>
    <body id="js-&mvte:page:code;" class="<mvt:eval expr="tolower(l.settings:page:code)" /> single-column">
    <mvt:item name="hdft" param="global_header" />
    <div class="row hdft-header">
    <h2 class="align-center">Special Offers<small class="show">Offer valid for this order only</small></h2>
    <mvt:item name="hdft" param="header" />
    </div>
    <div class="row bg-white bottom-shadow main-content-row product-information">
    <form method="post" action="&mvte:urls:OSEL:secure;">
    <input type="hidden" name="Action" value="AUPM" />
    <input type="hidden" name="Attributes" value="Yes" />
    <input type="hidden" name="Upsell_Product_Count" value="&mvte:global:Upsold_Product_Count;" />
    <mvt:item name="tax" />
    <div class="column whole cart-contents">
    <div class="row hide medium-show basket-header-row">
    <div class="column one-eighth align-center">Buy</div>
    <div class="column half">Product</div>
    <div class="column one-eighth align-right">Regularly</div>
    <div class="column one-eighth align-right">Special</div>
    <div class="column one-eighth align-right">Save</div>
    </div>
    <mvt:foreach iterator="upsold_product" array="upsale">
    <div class="row basket-product-row">
    <div class="column one-fifth medium-one-eighth align-center">
    <mvt:if expr="l.settings:upsold_product:selected">
    <input type="checkbox" name="Upsell_Selected[&mvt:upsold_product:index;]" value="Yes" checked />
    <mvt:else>
    <input type="checkbox" name="Upsell_Selected[&mvt:upsold_product:index;]" value="Yes" />
    </mvt:if>
    <input type="hidden" name="Product[&mvt:upsold_product:index;]:code" value="&mvte:upsold_product:code;" />
    </div>
    <div class="column four-fifths medium-half">
    &mvt:upsold_product:name;<br />
    SKU: &mvt:upsold_product:code;
    </div>
    <div class="breaker clear medium-all-hidden"></div>
    <div class="column one-third medium-one-eighth align-right"><span class="show medium-hide small">Regularly</span>&mvt:upsold_product:formatted_price;</div>
    <div class="column one-third medium-one-eighth align-right"><span class="show medium-hide small">Special</span>&mvt:upsold_product:formatted_upsell_price;</div>
    <div class="column one-third medium-one-eighth align-right"><span class="show medium-hide small">Save</span>&mvt:upsold_product:formatted_upsell_savings; </div>
    </div>
    </mvt:foreach>
    </div>
    <div class="breaker clear"></div>
    <p class="column whole align-right"><mvt:item name="buttons" param="Continue" /></p>
    </form>
    </div>
    <div class="row hdft-footer">
    <mvt:item name="hdft" param="footer" />
    </div>
    <mvt:item name="hdft" param="global_footer" />
    </body>
    </html>

    #2
    The code you supplied is not from Shadows. However, to bring in the image, you will need to add a couple of MVT:DO calls. I have updated your code with them. As for the link, it would not be recommended as if a custom clicked it, they would be removed from the checkout process which could lead to lost sales.

    Code:
    <mvt:item name="html_profile"/>
    <head>
        <mvt:if expr="NOT ISNULL l.settings:page:title">
            <title>&mvt:page:title;</title>
            <mvt:else>
                <title>&mvt:store:name;: &mvt:page:name;</title>
        </mvt:if>
        <mvt:item name="head" param="head_tag"/>
    </head>
    <body class="<mvt:eval expr=" id="js-&mvte:page:code;" tolower(l.settings:page:code)" /> single-column">
    <mvt:item name="hdft" param="global_header"/>
    <div class="row hdft-header">
        <h2 class="align-center">Special Offers<small class="show">Offer valid for this order only</small></h2>
        <mvt:item name="hdft" param="header"/>
    </div>
    <div class="row bg-white bottom-shadow main-content-row product-information">
        <form action="&mvte:urls:OSEL:secure;" method="post">
            <input name="Action" type="hidden" value="AUPM"/>
            <input name="Attributes" type="hidden" value="Yes"/>
            <input name="Upsell_Product_Count" type="hidden" value="&mvte:global:Upsold_Product_Count;"/>
            <mvt:item name="tax"/>
            <div class="column whole cart-contents">
                <div class="row hide medium-show basket-header-row">
                    <div class="column one-eighth align-center">Buy</div>
                    <div class="column half">Product</div>
                    <div class="column one-eighth align-right">Regularly</div>
                    <div class="column one-eighth align-right">Special</div>
                    <div class="column one-eighth align-right">Save</div>
                </div>
                <mvt:foreach array="upsale" iterator="upsold_product">
                    <div class="row basket-product-row">
                        <div class="column one-fifth medium-one-eighth align-center">
                            <mvt:if expr="l.settings:upsold_product:selected">
                                <input checked name="Upsell_Selected[&mvt:upsold_product:index;]" type="checkbox" value="Yes"/>
                            <mvt:else>
                                <input name="Upsell_Selected[&mvt:upsold_product:index;]" type="checkbox" value="Yes"/>
                            </mvt:if>
                            <input name="Product[&mvt:upsold_product:index;]:code" type="hidden" value="&mvte:upsold_product:code;"/>
                        </div>
                        <div class="column four-fifths medium-half">
                            <mvt:do name="l.success" file="g.Module_Library_DB" value="ProductImage_Load_Type(l.settings:upsold_product:id, 1, l.settings:imagetype)" />
                            <mvt:do name="l.success" file="g.Module_Library_DB" value="Image_Load_ID(l.settings:imagetype:image_id, l.settings:imagedata)" />
                            <mvt:if expr="NOT ISNULL l.settings:imagedata:image">
                                <div class="img-left"><img src="&mvte:imagedata:image;" alt="&mvte:upsold_product:name;" style="max-width: 8rem;"></div>
                            </mvt:if>
                            &mvt:upsold_product:name;<br/>
                            SKU: &mvt:upsold_product:code;
                        </div>
                        <div class="breaker clear medium-all-hidden"></div>
                        <div class="column one-third medium-one-eighth align-right">
                            <span class="show medium-hide small">Regularly</span>&mvt:upsold_product:formatted_price;
                        </div>
                        <div class="column one-third medium-one-eighth align-right">
                            <span class="show medium-hide small">Special</span>&mvt:upsold_product:formatted_upsell_price;
                        </div>
                        <div class="column one-third medium-one-eighth align-right">
                            <span class="show medium-hide small">Save</span>&mvt:upsold_product:formatted_upsell_savings;
                        </div>
                    </div>
                </mvt:foreach>
            </div>
            <div class="breaker clear"></div>
            <p class="column whole align-right">
                <mvt:item name="buttons" param="Continue"/>
            </p>
        </form>
    </div>
    <div class="row hdft-footer">
        <mvt:item name="hdft" param="footer"/>
    </div>
    <mvt:item name="hdft" param="global_footer"/>
    </body>
    </html>
    Matt Zimmermann

    Miva Web Developer
    Alchemy Web Development
    https://www.alchemywebdev.com
    Site Development - Maintenance - Consultation

    Miva Certified Developer
    Miva Professional Developer

    https://www.dev4web.net | Twitter

    Comment

    Working...
    X