close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Redirect on Add to Cart not redirecting

Thread began 7/26/2010 10:15 am by Gareth.TannattNash253613 | Last modified 7/27/2010 11:39 am by Jason Byrnes | 754 views | 7 replies |

Gareth.TannattNash253613

Redirect on Add to Cart not redirecting

Hello,

Help I'm experiencing some fun in that the redirect on add to cart buton pressed is not redirecting, it merely refreshes the page?

my test & development design site can be seen here - flower.asp?id=1&Roses+S-delivered-in-Bortsmouth-by-Bortsmouths-premier-florist-Design+Florist+Site

(Please ignore the design as it is in development) and should once add to cart is pressed (on either product) should redirect to here -

cartso.asp?Bortsmouth=Florist

but it fails?

my code looks like this (part of)-

<%
' WA eCart AddToCart
if (cStr(Request.Form("FloristWebCart_3_ATC")) <> "" OR cStr(Request.Form("FloristWebCart_3_ATC.x")) <> "") then
ATC_itemID = cStr(Request.Form("FloristWebCart_3_ID_Add"))
ATC_AddIfIn = 0
ATC_RedirectAfter = "cart/cartso.asp"
ATC_RedirectIfIn = ""
ATC_RSPos = ProductPrice3.AbsolutePosition
ProductPrice3.MoveFirst()
DO while (NOT ProductPrice3.EOF)
if (cStr(ProductPrice3.Fields("ID").value) = cStr(ATC_itemID)) then
ATC_itemName = "" & cStr((ProductPrice3.Fields.Item("Name").Value)) & ""' column binding
ATC_itemDescription = "" & cStr((ProductPrice3.Fields.Item("ProductDescription").Value)) & ""' column binding
ATC_itemWeight = cDbl("0")' column binding
ATC_itemQuantity = "" & cStr(Request.Form("FloristWebCart_3_Quantity_Add")) & ""' column binding
ATC_itemPrice = cDbl("" & cStr((ProductPrice3.Fields.Item("Price").Value)) & "")' column binding
Exit DO
end if
ProductPrice3.MoveNext()
Loop
ProductPrice3.AbsolutePosition = ATC_RSPos
if (IsNumeric(ATC_itemQuantity) AND ATC_itemQuantity <> 0) then
set FloristWebCart = FloristWebCart_AddToCart(ATC_AddIfIn, ATC_RedirectIfIn, ATC_itemID, ATC_itemName, ATC_itemDescription, ATC_itemWeight, ATC_itemQuantity, ATC_itemPrice)
if (ATC_RedirectAfter <> "" AND FloristWebCart_redirStr = "") then
FloristWebCart_redirStr = ATC_RedirectAfter
end if
Session("WAEC_ContinueRedirect") = cStr(Request.ServerVariables("Script_Name")) & "?" & cStr(Request.QueryString())
end if
end if
%>

What have I missed?

Thanks in advance

Sign in to reply to this post

Jason ByrnesWebAssist

please compress a copy of your page into a zip archive and attach that to your reply so I can see the entire page code in context.

Sign in to reply to this post

Gareth.TannattNash253613

Sure thing Page attached

Hi thanks for the response.

I've attached the page, I can attache the site if needbe?

Its an ASP VBScript page, I know that you guys only support PHP now, but when I bought Ecart ASP was supported too!!

It's not your standard page in that I'm using a lot of stored procedures, and whilst it is only displaying the one product, there are different size options (on a showif) so effectively different products and different recordsets to choose from.

Hope this is of use - and you can help -
Many thanks :-)

Attached Files
Flower.zip
Sign in to reply to this post

Jason ByrnesWebAssist

Your page is missing the following code blank that should be just before the doctype tag:

<%
' WA eCart Redirect
if (FloristWebCart_redirStr <> "") then
Response.Redirect(FloristWebCart_redirStr)
end if
%>
Sign in to reply to this post

Gareth.TannattNash253613

Great thank you.

any idea why it didn't get added automatically?

Cheers :-)

Sign in to reply to this post

Jason ByrnesWebAssist

you're welcome.

I cant reproduce an instance where that code doesn't get inserted, so cannot guess why it wasn't in your case.

Sign in to reply to this post

Gareth.TannattNash253613

no problem - thank you anyway - very fast

Sign in to reply to this post

Jason ByrnesWebAssist

you're welcome.

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