Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Matt Bliss 176 posts 234 karma points c-trib
    Nov 19, 2011 @ 12:50
    Matt Bliss
    0

    CartStep01.xslt not rendering

    I am constructing a site with Tea Commerce by taking parts from the Starter Pack and then copying them into my own site bit by bit. I have all the product and basket (top right of all pages) logic working and am now moving on to displaying the basket and the checkout process.

    Any ideas what would cause the cart_step01.xslt file to render as follows?

    <?UMBRACO_MACRO macroalias="CartStep01" /> <?UMBRACO_MACRO macroAlias="CartStep01" /> 0

  • Matt Bliss 176 posts 234 karma points c-trib
    Nov 20, 2011 @ 15:45
    Matt Bliss
    0

    I've discovered the answer to the problem. The template in the XSLT macro applies a second template based on the $currentPage. This means it applys the template whos name matches the document type alias of the node containing the macro (in this case "CartStep").

    My problem was that I had given my document type the name and alias of "Basket Step" / "BasketStep" and therefore the second template which contains all the logic would never get called.

      <xsl:template match="/">
        
        <xsl:apply-templates select="$currentPage" />

      </xsl:template>

      <xsl:template match="CartStep">
    ... 

    Updating the last line above to match my doc type alias solves the problem.

  • Rune Grønkjær 1372 posts 3103 karma points
    Nov 21, 2011 @ 08:03
    Rune Grønkjær
    0

    Cool, good thing you figured it out. Busy weekend over here :)

    /Rune

  • Matt Bliss 176 posts 234 karma points c-trib
    Nov 21, 2011 @ 10:22
    Matt Bliss
    0

    Thanks Rune,

    I didn't really expect any response at the weekend, but thought I'd post it just in case anyone else was mad enough to be working too!

    Matt

Please Sign in or register to post replies

Write your reply to:

Draft