Add to Cart URL

  • Posts: 15
  • Thank you received: 0
13 years 5 months ago #17728

Me again!

My client has now asked if we can use their current RomanCart system for payment side. I've already built all the product in to HikaShop and it's much better for organising product, stock and colour options, sizes etc.

Is there any way that I can take the details that would normally be added to the cart when you click "Add to Cart" button and have it add to RomanCart rather than HikaShop?

Please let me know if this is something you won't support. I'd completely understand!

Thanks

Matt

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 5 months ago #17734

It should be possible. But I don't know RomanCart at all so I can't help you much. What I can say:
You will have to edit the file quantity of the view product via the menu Display->Views in order to change the add to cart button into a romancart "add to cart" button so that it would add the equivalent product in the romancart cart instead of the hikashop cart when the user click on it.
I don't know how you can have external 'add to cart' buttons with romancart and that's something you should ask them.

Please Log in or Create an account to join the conversation.

  • Posts: 15
  • Thank you received: 0
13 years 5 months ago #19347

Hi there

Slow delay as a little bundle of joy turned up whilst in the middle of about 3 sites!

RomanCart simply uses these fields to add to their cart-

<form action=http://www.romancart.com/cart.asp method=post>
<input type=hidden name=itemname value="Half Chaps: HIGH VISIBILITY V-LINE">
<input type=hidden name=itemname2 value="CS">
<input type=hidden name=itemname3 value="Pink Piping">
<input type=hidden name=itemname4 value="">
<input type=hidden name=price value="22.99">
<input type=hidden name=weight value="800">
<input type=hidden name=storeid value="18376">
<input type=hidden name=passthru value="">
<input type=hidden name=tax value=0>
<input name="quantity" type="text" value="1">
<input type="submit" name="Submit" value="ADD TO BASKET" />

What views do I change to achieve this? Obviously product size and colour are dynamically changed on the page so that has to update itemname2 and itemname3 values.

Thanks
Matt

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 5 months ago #19354

You need to edit the file "quantity" of the view "product" via the menu Display->Views. There you can add your HTML code instead of the add to cart display button.
The information of the product is in the variable $this->row.
So for example, you could do like that :
<input type=hidden name=itemname value="<?php echo $this->row->product_name; ?>">
<input type=hidden name=price value="<?php echo $this->row->prices[0]->price_value; ?>">

Please Log in or Create an account to join the conversation.

  • Posts: 15
  • Thank you received: 0
13 years 5 months ago #19355

You are very very clever.

Thank you so much!

Please Log in or Create an account to join the conversation.

  • Posts: 15
  • Thank you received: 0
13 years 5 months ago #19381

I've tried to figure this one out for myself but how do you get the characteristic variant value?

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 5 months ago #19384

The product name should already contain the product name+characteristic value if you kept the "Append characteristic value to product name" option turned on in the Display tab of the configuration.

Please Log in or Create an account to join the conversation.

  • Posts: 15
  • Thank you received: 0
13 years 5 months ago #19387

It's not adding it in even though I have that turned on.

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 5 months ago #19403

Could you give a link to the page ?

Please Log in or Create an account to join the conversation.

  • Posts: 15
  • Thank you received: 0
13 years 5 months ago #19454

Not to worry. I've managed to figure it all out!

Thank you for your help.

Matt

Please Log in or Create an account to join the conversation.

Time to create page: 0.074 seconds
Powered by Kunena Forum