Add to Cart Javascript?

General ShopSite user discussion

Add to Cart Javascript?

Postby bucolic » Sun Jul 26, 2009 8:16 am

We have an option in our size selection box in our store that is "Unavailable". Couple lines below of the selections:


<option value="24314">44 - <span class="oldprice"></span>&nbsp;<span class="onsale">Sale: ($30.99)</span> - In Stock: 49 </option>


<option value="24315">46 - <span class="oldprice"></span>&nbsp;<span class="onsale">Sale: ($30.99)</span> - Unavailable </option>

Is there a script that will pop up a message if they try to add an item marked Unavailable to the cart and stop them to go back and make another selection?

We don't want to remove these and sometimes they do become available again.

Thanks for any help.
************************
Using Shopsite 12:Pro
Hosted By Lexiconn
************************
bucolic
 
Posts: 20
Joined: Sat Jun 23, 2007 12:09 pm

Postby Jim » Mon Jul 27, 2009 7:58 am

Have your tried putting ";n" at the end of the option? That indicates that the option is not a valid selection and will display a message when they try to checkout of the cart saying they need to make a valid selection.

See the help at http://shopsite.com/help/10.0/en-US/sc/ ... tions.html
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Postby bucolic » Mon Jul 27, 2009 8:49 am

Darn! Didn't work. I think it's the process we use. We grab manufactures inventory and run a script in excel to populate Extra Field 2 with those values. We then upload the date using the Sku as the unique identifier and Overwrite product field 2 with the data such as "In Stock: 50+" or "Unavailable". That would have been a breeze if it worked as I could have just changed the script to put "Unavailable;n". Am I missing something or did I do something wrong? Be great if that solution would work.

Thanks so much for the help.
************************
Using Shopsite 12:Pro
Hosted By Lexiconn
************************
bucolic
 
Posts: 20
Joined: Sat Jun 23, 2007 12:09 pm

Postby Jim » Mon Jul 27, 2009 9:32 am

If you are using the extra product fields that would not have worked. Also that information is not passed to the shopping cart so there is no way to have it checked in the cart. Sorry, I don't have any other suggestions.
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah


Return to User Forum

Who is online

Users browsing this forum: No registered users and 135 guests