Announcement

Collapse
No announcement yet.

Comma Delimited SKU on INVC Page (4Cite)

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

    Comma Delimited SKU on INVC Page (4Cite)

    We are implementing 4Cite tracking on our website and need to collect ecommerce data on the INVC page. Most data is easily collected, but the SKU field needs to be comma delimited (without a comma after the last value).

    Example with one product purchased: sku1

    Example with two products purchased: sku1, sku2

    I had it setup like this <mvt:foreach iterator="item" array="order:items">'&mvt:item:code;',</mvt:foreach>, but that adds a comma at the end.

    What's the best way to repeat &mvt:item:code; without the comma at the end?

    Thanks,

    Jay
    VickeryHill.com
    www.vickeryhill.com

    #2
    Re: Comma Delimited SKU on INVC Page (4Cite)

    Don't add the comma by default but only when it is not the last item. You may need toolbelt or toolkit to achieve this.
    Andreas Toman
    PCINET, LLC

    Miva Merchant Design, Development, Integration & Support
    We built over 200 Miva Merchant stores!
    Miva shopping cart design & integration service and see our Portfolio!


    e-mail: [email protected]
    web: www.pcinet.com
    LinkedIn: Andreas Toman
    phone: (786) 250-2056 (Miami, FL)

    Comment


      #3
      Re: Comma Delimited SKU on INVC Page (4Cite)

      Try something like the following:
      Code:
      <mvt:if expr="pos1 EQ 1">&mvt:item:code;<mvt:else>,&mvt:item:code;</mvt:if>

      Comment


        #4
        Re: Comma Delimited SKU on INVC Page (4Cite)

        Perfect. Thanks Dan!

        Originally posted by Dan - Glendale Designs View Post
        Try something like the following:
        Code:
        <mvt:if expr="pos1 EQ 1">&mvt:item:code;<mvt:else>,&mvt:item:code;</mvt:if>
        VickeryHill.com
        www.vickeryhill.com

        Comment

        Working...
        X