close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Not Wanting Zero Balance Invoice to go through payment processor (Paypal)

Thread began 12/17/2009 8:31 am by Rich Petersen | Last modified 12/18/2009 3:59 pm by Jason Byrnes | 2094 views | 5 replies |

Rich Petersen

Not Wanting Zero Balance Invoice to go through payment processor (Paypal)

Hello!!

I have a question...

I have implemented a coupon system, and sometimes, this will result in a $0.00 balance due invoice.

When they submit, I do not want this going to paypal, instead, just a page that says "thank you for your order"

Where would I modify the behavior?

Thanks in advance!

Rich

Sign in to reply to this post

Jason ByrnesWebAssist

What payment gateway are you using?

the steps for doing this will be different depending on whether you are using Local or re mote Checkout.

Sign in to reply to this post

Rich Petersen

Thanks Jason,

Currently, paypal express.........

Sign in to reply to this post

Jason ByrnesWebAssist

On the confirm page, open the Server behaviors panel, Window -> Server behaviors.


in the list of server behaviors, locate the Local Checkout (Paypal Direct Payments) server behavior, and select it. Switch Dreamweaver to Code view. The code for the local checkout will be highlighted. You need to add an if statement around the opening and closing PHP tags of the highlighted code:

php:
<?php if($<cartName>->GrandTotal() > 0) { ?>
<?php
...highlighted code...
?>
<?php 

else if ((
$_SERVER["REQUEST_METHOD"] == "POST") && (isset($_SERVER["HTTP_REFERER"]) && strpos(urldecode($_SERVER["HTTP_REFERER"]), urldecode($_SERVER["SERVER_NAME"].$_SERVER["PHP_SELF"])) > 0) && isset($_POST))  {
  $<
cartName>->redirStr "checkout_success.php";
?>



Where <cartName> is the name of your eCart object.

Sign in to reply to this post

Rich Petersen

Works like a champ, thanks Jason....

Sign in to reply to this post

Jason ByrnesWebAssist

Great, glad to hear its working.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...