1

Firstly I am new to Drupal commerce and start learning it on the job as required. So if you see my question as basic functionality in Drupal commerce, please pardon me.

Question: I have a simple commerce site and it look like as follows: Product view -- Shopping cart -- checkout

After checkout, I am adding a new custom module(creating an account for the user and few other things). I need to get the attributes of the product from the shopping cart module. How can I retrieve that information from the shopping cart module to the new custom module that I am building.

Thanks in advance.

  • You might also want to consider storing non-sensitive variables such as product nodes in a SESSION variable and that way you can access them across page loads. – AlxVallejo Jun 21 '14 at 14:25
0

We already have a rule shipped with the drupal commerce core, which creates the user account on checkout process. It might be a good starting point for you in both ways how it is looping through order information to use in your custom module or you can modify the rule as per your requirement.

Rule is "Create a new account for anonymous user."

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.