How about an "Agree to Terms" interstitial page before actually charging the card or sending the user to PayPal? My vision is a simple scrolling div containing refund terms and any other legal mumbo jumbo with an "I agree" checkbox and a submit button. This is one of those cover-one's-backside functions that is necessary for vendors who might be involved in credit card disputes. And for that matter it's important to let users know that once they download the file, they're not going to be able to receive a refund.

Keep up the good work!

Jeff

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jjeff’s picture

solipsist’s picture

I agree, also with PayPal's very liberal policies regarding refunds this would serve as some sort of legally binding document for the seller to refer to in case a customer decides to dispute a transaction.

Jeff Veit’s picture

This node contains a patch for a terms and conditions link. It's not an interstitial page and it's not 'Tick the box to indicate your agreement'. I tend to think that the more barriers you put in the way of customers, the fewer follow through with a sale. But you could extend it to be a tickbox.

Jeff

solipsist’s picture

Ioffer file downloads so I am modifying the file module to show a license agreement on the file list page informing the user that downloading the file means the purchase is final and no refunds can be made. However AFAIK the file module keeps no log of user downloads, it would be nice to have some sort of evidence in case the customer tries to get a refund and claims non-delivery.

neclimdul’s picture

The file problem is actually something my group is going to have to deal with. As of know we are relying on apache logs. This becomes less than ideal pretty quick but you know how deadlines work. However, all that's kinda off topic.

Being as I like to think of the E-Commerce module as being flexible I'd say it'd be nice to offer this in 2 ways.
1) the admin can setup a textarea to show up on the page that the user agrees to
2) the admin sets up a second page and that link is shown to the user
In either case the admin can require have a checkbox that the user must select agreeing to the terms. These wouldn't be mutually exclusive so they could both be used to get the desired effect. Of course, they also wouldn't be required so if they aren't needed by the site, they aren't shown.

Final note, is this really a 4.5 issue? Can we make this a CVS feature request and back port it as needed? I wasn't even aware that 4.5 was actively maintained.

sime’s picture

Version: 4.5.x-1.x-dev » master
Component: cart.module » cart

decent idea. tagging cvs

gordon’s picture

Component: cart » -- other --

This can be done as a contrib module without any problems.

Just us use the checkoutapi() and add it to the review page.

sime’s picture

Component: -- other -- » new module

clarify component

Christoph C. Cemper’s picture

cool - need this too +1

blakehall’s picture

Here's a simple module I've been using for 4.7.

I don't know enough right now about the filter system to process the various filters on a site, so this one just takes regular old HTML.

before the terms are rendered for the users the text is passed through filter_xss(), but if your site admin is trying to attack your site you have larger problems than that.

TODO's (as I see them) would be:

  • enable the multiple filters
  • port to 5.X
blakehall’s picture

Status: Active » Needs review
FileSize
3.63 KB

Attached is a version for 5.

Here's the terms.info (so I don't have attach another file)

; $Id:$
name = Terms
description = Optionally require a terms and conditions screen during checkout.
package = "E-Commerce Uncategorized"
dependencies = store
version = 3-dev
blakehall’s picture

FileSize
3.57 KB

And another for 4.7

sime’s picture

Hi blakehall, I've try and review this as soon as I get the chance.

gordon’s picture

Version: master » 5.x-4.x-dev
Status: Needs review » Needs work

Thanks for this and I have had a quick look. I have a number of problems with this. See below.

- Use 2 spaces instead of tabs.
- Don't add another page to the checkout, Add it too the review form.
- change the name to something like ec_terms. terms is just a bit too generic
- Remove the 4.7 stuff from the help.

We are only accepting new modules for 5.x-4-dev so please make sure it works with this version.

All in all it is pretty good.

blakehall’s picture

Status: Needs work » Needs review
FileSize
4.73 KB

Thanks for the feedback Gordon.

  • Tabs have been converted to 2 spaces (after I found the right Textmate setting ;)
  • 4.7 help stuff is gone
  • Module name now == ec_terms

But the last suggestion I feel fairly strongly about. For some E-Commerce sites agreeing to terms needs to be a more active process than some text display on the checkout review screen. So I've added another configuration option. You can now choose if you'd like the terms displayed as a separate screen during checkout, or displayed in their own box on the checkout review form. (I thought that was an easy compromise, since I couldn't figure out how to make some type of acknowledgment on the review screen seem natural or useable).

This version should work with 5.x-4.x-dev. As always more suggestions are welcome.

blakehall’s picture

FileSize
4.73 KB

Thanks for the feedback Gordon.

  • Tabs have been converted to 2 spaces (after I found the right Textmate setting ;)
  • 4.7 help stuff is gone
  • Module name now == ec_terms

But the last suggestion I feel fairly strongly about. For some E-Commerce sites agreeing to terms needs to be a more active process than some text display on the checkout review screen. So I've added another configuration option. You can now choose if you'd like the terms displayed as a separate screen during checkout, or displayed in their own box on the checkout review form. (I thought that was an easy compromise, since I couldn't figure out how to make some type of acknowledgment on the review screen seem natural or useable).

This version should work with 5.x-4.x-dev. As always more suggestions are welcome.

sime’s picture

You can now choose if you'd like the terms displayed as a separate screen during checkout, or displayed in their own box on the checkout review form.

Sounds very good.

sime’s picture

I like, the code is clean.

What I would really like is the ability to change the heading Terms and Conditions.

The other thing is a shortfall that could be a windfall (you know one of those things were I suggest a feature and hope you agree). Often, terms and conditions require a checkbox. Do you think you could yank out the coupon code that inserts a textbox and add that to you module.

The windfall? This would be one step towards adding other fields like Phone Number. Ie. the little fields that we don't have covered in the address.module (especially if address.module is not enabled ;-) ).

What thinketh you?

Styles’s picture

This is interesting, how complicated would it be to do this as a cck widget?
so we could also add "Agree to Terms" to cck forms?

blakehall’s picture

Status: Needs review » Needs work

@sime: (thanks for the review)

The module actually does require a checkbox if you make the terms present as a seperate page during the checkout process (rather than on the review screen). I tried messing around with form api, and the checkoutapi to achieve the same effect on the review screen but wasn't successful (but I'll give it another try after looking at coupon).

Allowing configuration of the title should be a relatively trivial fix. I'll post some more code after looking at coupon.

blakehall’s picture

Status: Needs work » Needs review
FileSize
6 KB

Okay...

  • I've added to the settings form an option to rename the title (from the default of Terms & Conditions).
  • I've added a checkbox (with the text 'I Agree to the $name_from_above'), which is required in order to checkout

In principle this technique could be used to inject just about any form element into the checkout process. Off the top of my head I can't imagine how a CCK widget could be used (since I'm not too familiar with CCK)...

Jeff Veit’s picture

FileSize
6.31 KB

Here's an updated version.

I've:
- Fixed a spelling error
- Removed the page title because it ended up being used on the review page
- Changed the meaning of required: previously it seemed to have the same effect as turning the module off. Now it indicates whether the user is required to agree with the terms and conditions by ticking the checkbox. If the user is not required to, then there's no checkbox.

Tested both with separate page and on review page, with and without checkbox, on Drupal 5.1 under PHP 5.

Jeff

gordon’s picture

I have been thinking about this a bit more, and I was wondering if instead of creating a new module, would it be better to add this to the legal module, which may be a more logical spot for it.

gordon’s picture

I know that people have put a lot of work into this, but I am just running this idea up the flag pole to see what people think.

And I think an enhancement like this would get a lot more love in the legal module than in the ecommerce module. And I would suspect that people who need this feature will have the legal module installed anyway.

blakehall’s picture

That makes sense to me. I guess the ultimate question is whether or not other modules are interested in plugging into ecommerce...

Obviously that means re-factoring code. On the sites I've been using this module I'm not using legal, so that'll take a while to get familiar.

It certainly wouldn't hurt to link folks here if they need simple terms during checkout though.

Robert Castelo’s picture

Hi, I'm the author of the Legal module, and I'd be very interested in integration with E-Commerce.

Just wondering what would be required....

Display T&C and accept checkbox on specific page or configurable to include anywhere in checkout process?

Would we need separate T&Cs for e-commerce than registration? (which is main use of Legal T&Cs now)

What are the other requirements?

Jeff Veit’s picture

I've got no problem with the idea. I'm not using the legal module at the moment - I've just got a node for legal stuff.

I don't want to force people agree to T&C before registration though. We use anonymous purchasing, without forcing an account as a requirement, and we don't don't force people to agree to T&Cs because we are just trying to draw attention to them: we are trying for the lightest, easiest sales process possible because every time we put barriers in place we lose sales.

Jeff

brmassa’s picture

Status: Needs review » Active

Robert,

like Jeff said, its going to be useful to make two kinds of Legal notes: registration and checkout (maybe making it generic and using some kind of hook). The reason is:

* eC allows anonymous purchasing: so users might never create an account and might never access the legal note
* eC might be enabled in a running site, so only new users will have to agree the terms

regards,

massa

kingandy’s picture

I guess the Legal integration stalled, since this issue's now over a year stale?

Well - I'm coming to do something similar to this on one of our sites, so I'm planning to use the ec_terms.module_2.txt file as my starting point (it seems to work more or less how I had pictured it). I may update this thread with some updates and refinements if I remember...

kingandy’s picture

FileSize
6.79 KB

OK, well, here's what I changed.

The Settings page went from a special callback function to a direct drupal_get_form call (with 'ec_terms_details' as the callback arguments) and the manually-added 'Save' button was switched out for a system_settings_form() push. I also streamlined some of the logic (some if() statements were validated twice, and other true/false variables were being fetched and then compared to 'true') and stripped out a bunch of occasions where things were assigned to variables for a single use (and vice-versa, declared variables when data was being fetched multiple times). Some of the validation is now handled directly by Forms API and all of the system messages are now run through the t() function.

I think that was about it ... pretty much no change to actual functionality, just some tidying up and translation. Oh ... the one thing I did add was a new variable ec_terms_fail, to allow admins to set their own failure message. I thought about putting the three switch-compulsory variables (text, name and fail) into their own fieldset but ultimately couldn't be bothered.

Schwalbe’s picture

Thanks to kingandy!

This is what we have been looking for but it seems, this module has never made it into the module download section.
Is this a workable module and how do I install it? Detailed instructions would be appreciated.

Thanks,

Klaus

kingandy’s picture

Status: Active » Needs review

I've set this issue to "Patch (code needs review)" though technically it's not a patch to anything and it's working pretty well on our production server. One of these days I'll apply for CVS access or work out how to get modules submitted...

Until that day, the module on this thread is pretty much ready to go. You can install it yourself as follows:
1) Create a folder 'ec_terms' in your sites/all/modules folder.
2) Create a file 'ec_terms.info' in this folder with content as defined on comment #11 above
3) Download the ec_terms.module_3.txt file from #30 and save it in your ec_terms folder as ec_terms.module
4) Go to your website's Site Building area and enable the module as normal.

Once you've done that, you should configure the module at admin/ecsettings/ec_terms - here you can make the checkbox mandatory or optional, have it as a separate screen or only on the review page, and customise most of the text used by the module.

Schwalbe’s picture

Works like a charm!

Thanks again,

Klaus

mybinaryromance’s picture

wow! this REALLY fills a gap - and makes ecommerce module 'legal' in countries with pretty restrictive (which in fact means 'customer protecting') laws around online sales!

one more little question: is there a possibility of having the checkbox displayed as last item of the cart review page? i mean just before the 'submit order' button? this is where users would expect it.

thanks a lot everyone!

mybinaryromance’s picture

to change the order of the review screen's form items to be more user friendly you can add something like

/**
* sorting function for uksort().
*/
function ec_terms_last($a, $b) {
	if ($a == 'ec_terms') return 1; else return 0;
}
/**
* Implementation of hook_form_alter().
*/
function ec_terms_form_alter($form_id, &$form) {
  
  switch ($form_id) {
    // This is our form ID.
    case 'checkout_review_form':
      uksort($form['screens'], 'ec_terms_last'); 
      break;
  }
}

to the module contributed here (#30). this is based on a form building tutorial at http://www.lullabot.com/articles/modifying-forms-drupal-5-and-6

i tried to change the form items' weights too, but wasn't successfull, so i stayed with good ol' uksort(). maybe there's a more drupal way of doing it, but i don't really know how

gordon’s picture

Status: Needs review » Closed (won't fix)

I do like the idea, but needs to be created as an external module in a new project.