close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Add to cart button on detail page falsely shows record deleted

Thread began 8/16/2016 8:17 am by tmcbinc99963 | Last modified 8/18/2016 11:16 am by Ray Borduin | 2337 views | 7 replies |

tmcbinc99963

Add to cart button on detail page falsely shows record deleted

The current product results page uses the WA magnifying glass as a link to the detail page. There are also other areas of the site where you can link to the detail page without going through search/results. All seem to work fine.

I've added an Add to Cart button to the detail page so users can add the product to the cart without searching, which used to work as well.

When the Add to Cart button is clicked now, the page shows 'record has been deleted' and the product detail information is gone (only the cart buttons are there). Also, when I return to the cart, the products are still there and nothing has been deleted.

I've adjusted the layout recently and may have moved some things around vital to the eCart.

Sign in to reply to this post

Ray BorduinWebAssist

Remove the action attribute from the add to cart form on the details page and that should resolve this issue.

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

tmcbinc99963

The detail page Add to Cart doesn't update the cart on either of two scenario's:

This attempts to add items to the cart from the Prod_detail page before products are added to the cart via the Prod_results.php page.
Search for product
Select product detail
Add quantity and size; click Add to Cart
Click view quote
Results: The cart is empty

This attempts to update size and quantity from the Prod_detail page for an item that is already in the cart via the Prod_results.php page.
Search for product
Add quantity and size; click Get Quote
Click Select More Products
Click detail icon
Add quantity and size; click Add to Cart
Click view quote
Result: cart doesn’t update quantity or size

Sign in to reply to this post

Ray BorduinWebAssist

Your add to cart button was renamed.

The add to cart server behavior is triggered based on a button named "eCart1_1_ATC" but you have renamed your button to: "WebCartATC"

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

tmcbinc99963

Now I get the error per the attached screen shot. Was getting this error before, that's why I changed the name of the form. The error went away, but obviously that was the wrong fix.

Sign in to reply to this post

Ray BorduinWebAssist

The first error is because you have deleted the hidden form element named "eCart1_1_ID_Add" from the page. That should be added back to the form and given a value bound to the product ID column in the database.

The second error is because you have renamed your quantity field. It is looking for a field named "ATC_itemQuantity" but your quantity field is actually named "eCart1_1_Quantity_Add". You just have to get those two values in sync by replacing one or the other.

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

tmcbinc99963

The hidden field was there, it just wasn't inside the form with the other eCart form elements (best guess). That error went away, but still receiving the 'ATC_itemQuantity' error.

I changed the name of the quantity field, but the error remained. Noticed line 144 was still named "eCart1_1_Quantity_Add" so I changed it to "ATC_itemQuantity_Add" and also to "ATC_itemQuantity" but still received the same Undefined Index error.

Also noticed the quantity field is now named "ATC_itemQuantity" and the Add to Cart button is named "eCart1_1_Quantity"; don't know if this is a problem.

.

Sign in to reply to this post

Ray BorduinWebAssist

The form button was named: ATC_itemQuantity

but the binding was set to a form value for: ATC_itemQuantity_Add

so they were still out of sync. I've updated it and it appears to work now. I also added the redirect to the cart display and fixed the size select list.

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

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