close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Adding More Columns in eCart Object?

Thread began 4/08/2009 1:36 pm by Art | Last modified 7/16/2010 10:42 am by Ray Borduin | 3492 views | 16 replies |

Art

Adding More Columns in eCart Object?

My site has many pages and I am faced with the fact that I need to add a few more columns to the eCart Object. I'm building a coupon discount that is based on the category of the item but I don't currently have that built in. The problem, of course, if I do this and upload it, none of my pages will work and I'll have a mess on my hands. Consequently, what I need to do, before uploading the cart definitions, is go into each page and fire up the eEcart behavior in each page.

********************************************
NOTICE: I wish this part (above) could be built into an include so by updating one you update all...
********************************************

1. Is there an easier way of doing this without having to go into each page and fire up the eCart behavior?
2. Can I just add a couple more generic columns that aren't linked to anything so I don't have to do this all over when the case arises?

Sign in to reply to this post

Ray BorduinWebAssist

You only have to update the add to cart buttons to add content to those columns. I don't see how having placeholders would help... if you add a column you will need to update the add to cart server behavior to specify the contents.

Sign in to reply to this post

Art

I don't think I understand

Originally Said By: Ray Borduin
  You only have to update the add to cart buttons to add content to those columns. I don't see how having placeholders would help... if you add a column you will need to update the add to cart server behavior to specify the contents.  



I don't think I understand your response.

Perhaps restating will confirm my intention...or not...

In order to do the discount on category, I need to store the category id somewhere/product. I could do a plain old session variable but it wouldn't be tied to each row product added.

So, when I open the ecart window, I see the "General, Columns, Calculations, Discounts, Charges, Taxes" tabs. When I go to "Columns" I see a list of items like "Price, Name, Id, weight..." that are added/line when a product is added. I need to add one more "Column" here called "Category" that will record the category of each product and only those products will get a discount of 25%.

My past experience tells me that if you change the Columns by adding one more, and if you post the "WA_eCart_Definition_VB.asp" and "name_eCart_VB.asp" that get updated when you change anything in the ecart, the site dies and you get a major error.

The only way I know to do this is to go into each page and update the (as you said) the add to cart page and I'm wondering if this is the only way. I have a lot of pages and I want to avoid this.

Is this clear?
----------------
By the way, what would the rule look like?
I know it would be something like the following but what would it look like if I ONLY want it to apply to items that are in that category and not in others?
25% off if category is (categoryID)

Sign in to reply to this post

Ray BorduinWebAssist

If you don't have an active session the only thing that needs to be updated is the add to cart buttons. Since you are adding a column you would want to update those anyway to insert the correct category ID... maybe we keep going over eachother's head but it seems this would be necessary even if no errors occured without it.

Sign in to reply to this post

Art

You're right, I would have to update each "Add To Cart" item on the site.

Any ideas on what the "expression " would look like for this? I don't think the regular options offer what I need for this.

Sign in to reply to this post

Art

Or, do you think this would fit into the normal scope of WebAssist's tools.

Sign in to reply to this post

Ray BorduinWebAssist

I'm afraid I don't understand the question.

Sign in to reply to this post

Art

Sorry, let me try again.

Let's say I have 3 categories of products

01, 02, and 03

I want to have a coupon apply a discount on products in group 03 at checkout time.

What would be the best way to do this in WA?

Sign in to reply to this post

Ray BorduinWebAssist

1) What Server language? (I'll answer in php)

Most likely you would add a column to your cart for the category.

Then you would add a calculation like:

TotalDiscount = (([category] == '03')?([TotalPrice] * 0.25):0)

Then add a discount that is equal to the total of the TotalDiscount column in the discount tab.

Sign in to reply to this post

Art

ASP vbscript

how different would the calculation be?

Sign in to reply to this post
loading

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