Announcement

Collapse
No announcement yet.

View-Cart Page Variable

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

  • View-Cart Page Variable

    According to the documentation the variable [ITEM_ID] on the view cart page should return the SKU?
    https://www.3dcart.com/guide/templat...html#variables

    I'm not getting the sku with this variable, and it's not the catalog Id either. What number is this? If it's not the SKU, can we get a variable on this page that does represent the sku? Or is there any way of getting the skus for the items in a customers cart?

    Thanks,
    Matt

  • #2
    From testing it seems that [ITEM_ID] is 3D Carts Internal ID associated with the SKU information. My guess anyways, since one of my cart items showed 10688 instead of the ID/SKU on the product information page.

    My Thoughts:
    - The Cart is viewed by the Customer only. Does the customer actually need to see the SKU? In my opinion, the SKU is internal data that the customer doesn't need to see.
    - Customers that have a cart, but have not checked out is stored as an Order with an Order_Status of 7 - Not Completed. IF you are using the API to get cart information, then you need to grab the order, iterate through its orderitems, and for each orderitem, you need to query the product to retrieve the SKU information. If this is the case and you are using the API, message me lets talk. or email me at b.rich86@outlook.com

    Comment


    • #3
      Thanks, Brian.

      Our wholesale users use SKUs a lot of the time when they are ordering, so it is necessary information for them. However, I'm trying to send facebook pixel events about items that customers have purchased, which requires the SKU number to be sent (to match with the sku in our product catalog).

      I may have to run through the completed orders on my server and send the pixel events that way... Was just trying to get it all done client side.

      Matt

      Comment


      • #4
        Matt,

        I do not work with web stuff very much (I program for my company), and this is the first time ever hearing about Facebook Pixel.
        However, seeing as the requirements for Pixel include access to change the code to your website, maybe there is a solution available. I am not too sure, but is it possible to massage the input to the pixel event before executing it? Take for instance, if one piece of information is the SKU, take the item name, run it through the 3D Cart Product API on your webserver, and it returns the SKU that you desire?

        Brian.

        Comment


        • #5
          ozzyonfire use [itemid] on the view cart to show sku.

          Hope this helps
          TheCartDesigner.com

          Follow Us on Twitter
          **TIP THE "HELP" JAR**

          Comment


          • #6
            Can confirm for thecartdesigner. Can also confirm that [itemid] is not on the template documentation for view_cart.html

            Comment


            • #7
              Thanks, Brian. That's not a bad idea actually. Just send an AJAX request to my server to do a lookup on the item before the pixel fires. Not ideal, but definitely something I can work with.

              Cart Designer, thanks! [itemid] gave me the intended SKU value, even though it doesn't show up anywhere in the documentation... Is this a global variable that is accessible from any page on 3D Cart?

              Thanks,
              Matt



              Comment

              Working...
              X