Bagisto Forum

    Bagisto

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups

    how to get guest user id before register

    Bug Report
    3
    19
    769
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      mindwebtree last edited by mindwebtree

      how to posible guest user placed your order without register and what is flow this functionality >

      how to get guest user id before register

      1 Reply Last reply Reply Quote 0
      • A
        Amitk-Webkul last edited by

        Hi there,

        we are not storing guest user ID if you want to verify or get the data.

        you can get/verify on the basis of email ID.

        M 1 Reply Last reply Reply Quote 0
        • M
          mindwebtree @Amitk-Webkul last edited by mindwebtree

          @Amitk-Webkul
          so how to possible add to cart item for guest user ?

          1 Reply Last reply Reply Quote 0
          • A
            Amitk-Webkul last edited by

            Hi @mindwebtree,

            We are saving cart items on the basis of Email ID.

            M 1 Reply Last reply Reply Quote 0
            • M
              mindwebtree @Amitk-Webkul last edited by mindwebtree

              @Amitk-Webkul
              when first time guest user add to cart item so which email using without order placed

              may i know ?

              1 Reply Last reply Reply Quote 0
              • A
                Amitk-Webkul last edited by

                HI @mindwebtree,

                we are managing the Email ID while the order is placed.

                For the first-time guest user, you can get the Cart ID on the basis of the session (session()->get('cart')->id).

                From the Cart ID, you can get the cart item ID.

                M 2 Replies Last reply Reply Quote 0
                • M
                  mindwebtree @Amitk-Webkul last edited by mindwebtree

                  @Amitk-Webkul
                  if i want to add my custom functionality for guest user before add to cart and order place so which column basis possible

                  what is role of token that token insert cart item table

                  1 Reply Last reply Reply Quote 0
                  • M
                    mindwebtree @Amitk-Webkul last edited by

                    @Amitk-Webkul
                    please give me any response

                    1 Reply Last reply Reply Quote 0
                    • A
                      Amitk-Webkul last edited by

                      Hi @mindwebtree,

                      You can add custom functionality based on session.

                      Here token is a CSRF token to protect the website.

                      M 2 Replies Last reply Reply Quote 0
                      • M
                        mindwebtree @Amitk-Webkul last edited by mindwebtree

                        @Amitk-Webkul
                        how to work add to cart for guest user because that time not any specific value like email id , id etc.

                        1 Reply Last reply Reply Quote 0
                        • M
                          mindwebtree @Amitk-Webkul last edited by

                          @Amitk-Webkul
                          please sir let me know

                          1 Reply Last reply Reply Quote 0
                          • A
                            Amitk-Webkul last edited by Amitk-Webkul

                            Hi @mindwebtree,

                            before clicking on the final order place button, the complete data is saved, when the one-page checkout form has to be filled.

                            and then you will get the Email, id, etc data.

                            M 1 Reply Last reply Reply Quote 0
                            • M
                              mindwebtree @Amitk-Webkul last edited by mindwebtree

                              @Amitk-Webkulba.png

                              when click add to cart then item add in cart it how to possible before place order

                              1 Reply Last reply Reply Quote 0
                              • devansh-webkul
                                devansh-webkul last edited by

                                Hi there,

                                Before proceeding with checkout, entry will be done in the cart. And I am not getting what you are trying to say. Can you please explain.

                                M 1 Reply Last reply Reply Quote 0
                                • M
                                  mindwebtree @devansh-webkul last edited by

                                  @devansh-webkul
                                  Is add to cart functionality working according to session if yes so how please tell me

                                  1 Reply Last reply Reply Quote 0
                                  • devansh-webkul
                                    devansh-webkul last edited by

                                    Yes, guest functionality works according to the session and for customers, it is saved in the database.

                                    For more info you can check this method here,
                                    https://github.com/bagisto/bagisto/blob/0914f371f9f414697b1e4a57c22a2b271a9ec431/packages/Webkul/Checkout/src/Cart.php#L77

                                    M 1 Reply Last reply Reply Quote 0
                                    • M
                                      mindwebtree @devansh-webkul last edited by

                                      @devansh-webkul
                                      hello are you there ?

                                      M 1 Reply Last reply Reply Quote 0
                                      • M
                                        mindwebtree @mindwebtree last edited by

                                        @mindwebtree
                                        what is different between customer and guest user ?
                                        please describe me

                                        1 Reply Last reply Reply Quote 0
                                        • A
                                          Amitk-Webkul last edited by

                                          Hi @mindwebtree,

                                          The guest user allows a customer to purchase without logging into or creating a store account.

                                          Customers are those that have an account on your store that they can log in to.

                                          1 Reply Last reply Reply Quote 0
                                          • First post
                                            Last post