close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Add to Cart Server Behavior Not Working

Thread began 7/20/2017 9:11 am by cal114936 | Last modified 7/21/2017 10:06 am by Ray Borduin | 2392 views | 8 replies |

cal114936Beta Tester

Add to Cart Server Behavior Not Working

I am trying to bind a Taxable column in the eCart to a Taxable database column through the Add to Cart Behavior, but I am not able to choose the recordset. I assume this may be because of the recent CC updates. Is there a way to fix this? Or a step by step instruction of how can I do this by hand?

Sign in to reply to this post

Ray BorduinWebAssist

Yes, this is the bug in the latest version of CC. You can downgrade to a previous version using the Adobe Creative Cloud so that it will work natively, or you can go to your page and add the bindings you want to use to the page itself and copy/paste them into a .txt document and then copy and paste them into the server behavior where you want to use them.

Sign in to reply to this post
Did this help? Tips are appreciated...

cal114936Beta Tester

Version 2017.0.1 is ok?

Sign in to reply to this post

Ray BorduinWebAssist

yes that version should work.

That is usually an error with your site settings. Maybe you have a https redirect but your Site URL is set with http://, or a www. redirect but you aren't using www. in your Site URL.

I couldn't be sure without reproducing your site definition. If you want to export it and send it as a private attachment, I could import it and reproduce the problem and debug the cause.

Sign in to reply to this post
Did this help? Tips are appreciated...

cal114936Beta Tester

Okay, testing server is working and I have bound the tax column in the add to cart server behavior.

I have added a calculation in the cart object: CATaxAmount =([Price]*[Quantity])*[CATaxable]

Now resulting in...

Parse error: syntax error, unexpected '=' in /home/hotvws/public_html/WA_eCart/eCart1_PHP.php on line 11

edited the line to

$itmObj->CATaxableTotal=$itmObj->Price * $itmObj->Quantity * $itmObj->CATaxable;//c

And now no error.

But after binding the taxable column to the add the cart button, there is no sales tax being added for any products whether 1 or 0 in the database column.

Sign in to reply to this post

Ray BorduinWebAssist

The entered calculation should just be:

([Price]*[Quantity])*[CATaxable]

Sign in to reply to this post
Did this help? Tips are appreciated...

cal114936Beta Tester

Yes I got that.

But after binding the taxable column to the add the cart button, there is no sales tax being added for any products whether 1 or 0 in the database column.

Sign in to reply to this post

Ray BorduinWebAssist

You would still have to add a tax rule to charge the total of the CATaxableTotal column. Did you do that? You can display the CATaxableTotal in your cart and verify it has the correct amount.

Sign in to reply to this post
Did this help? Tips are appreciated...

cal114936Beta Tester

Yes, it has the correct CATaxableTotal.

I found the answer in another post of yours Ray....


On the confirm_cart.php page you will need to save the session variable... So add code like this:

<?php
if (isset($_POST['State_2'])) {
$_SESSION['ShipState'] = $_POST['State_2'];
}
?>

Then use the session variable ShipState in your rule.

The session variable you are using now is from the persistent form and is actually an array of all of the session values, so you can't use it to refer to a specific field like you are attempting.

Thanks

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...