I have a use case in which I wish to collect payments before users are allowed to fill a form; basically the form is an assessment form for which the provider (offering analysis) would like to charge money.
Currently I have the form setup using webforms, but I couldn't find a decent or well established way of collecting payment with webform submission. I already have Ubercart on the site so, if there is a Ubercart to webform bridge, I would definitely like to know about it as well (I couldn't find any). Lastly I am also open for any other approaches.

My use case is the following. Users pay for the assessment (service) using Paypal, and then they are given a link to submit a form; the submitted data need to go to the provider.
Do you have any ideas on how this could be implemented? I assume it should be a relatively common use case.


I believe you are looking for the "Ubercart event registration" technique and the Node Checkout module. Mainly because this technique is associated with "event ticketing" most people do not realize the general nature of what the Node Checkout module provides:

Node Checkout causes a "node creation form" to be presented to a user after adding an item to their cart. The idea being that someone is purchasing an event ticket, so they are presented with a form for capturing their name, address and other info so their identity can be verified at the event's ticket booth.

HOWEVER, this technique provides a few interesting things for developers:

1) these don't have to be event products, the "purchase" can be for anything

2) the information collected is entirely up to you, because you create a new content type for capturing this information, you can put text fields, checkboxes or whatever FAPI or CCK widgets you want on that form

3) due to the nature of how this technique works, you can trigger one or two "purchased item forms": the first one is automatically triggered by the Node Checkout module after the use clicks "add to cart", but part of this technique includes use of a Conditional Action to support identification of abandoned purchases where the "new purchase form" was filled out, but checkout never happened. You can use this Conditional Action moment to trigger a 2nd (or maybe in your case only) node form for collecting this information AFTER their purchase transaction completes.

I think if you only want a form to appear to the customer after the purchase transaction, you may not even need Node Checkout - you can do it all with a custom content type for your information collection, and use Conditional Actions to trigger the display of that form after purchase.

You'll have to do some mental translating to understand this technique, because the best tutorial explaining the technique is purely about event ticketing. But if you have a little imagination, you'll realize how generally useful asking the customers for information after a purchase can be.

Here's the best tutorial I've been able to find on this, step by step too:



Have you tried the Ubercart Webform Checkout Pane module?

You could define a simple product and use the webform as part of the checkout process.

Some more details about this module (from its project page):

This module allows you to define Webform nodes as checkout/order panes in Ubercart.

This is useful if you want to collect additional information during the checkout process. For example, you may want a quick survey or require additional fields that apply to the entire order.

Using the Webform module allows for many advantages: the forms/fields can easily be modified by an end-user; less development time is required to create database tables and code to store/retrieve the data; and the form will remember the user's previous answers.

Furthermore, this module now provides tokens for every field in each of your enabled webforms, making it easy for you to insert the submitted values into confirmation emails, invoices, etc.


If I understand you correctly you could use Ubercart Event Registration. It creates a product class that is also a webform content type. The user fills in the webform first and then is taken to their cart. There's a hidden component in the webform for the payment status that gets updated automatically when payment's received, so it would be easy to filter out those who hadn't paid.

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.