skip to Main Content

I use Mal’s e-commerce for the shopping cart on my website. Typically I use <form> code for the "Add to Cart" button which allows a thumbnail image to be included on the shopping cart page. The https://www.example.com/thumbnail-image/... part of the "thumbnail.jpg" URL is parked on Mal’s website.

I need to instead use a hyperlink "Add to Cart" on one of my pages, but in doing so I’m not able to include the <input name="thumb"...> line of code. I’m not well-versed with coding so I might not be phrasing this question correctly (and hope I’m not being too confusing), but is there a way to add a thumbnail ("thumb") command to the line of hyperlink I’m wanting to use?

This is the code I usually use:

<form action="https://www.example.com/cf/add.cfm" method="post">
<input name="userid" type="hidden" value="00000000">
<input name="product" type="hidden" value="Acme Widget">
<input name="price" type="hidden" value="30.00">
<input name="thumb" value="thumbnail.jpg" type="hidden">
<input name="return" type="hidden" value="https://mywebsite.com/">
<input type="submit" value="Add to Cart">
</form>

This is the hyperlink code I would like to use and include a thumbnail (if possible):

<a href="https://www.example.com/cf/add.cfm?userid=00000000&return=https://www.example.com.com/&product=Acme+Widget&price=30.00">Add to Cart</a>

2

Answers


  1. Chosen as BEST ANSWER

    I was able to figure it out and it turned out being pretty simple. I just added &thumb=thumbnail.jpg at the end of the hyperlink and that did the trick.


  2. Try this code

    <a href="https://www.example.com/cf/add.cfm" onclick="this.href += '?userid=00000000&product=Acme%20Widget&price=30.00&thumb=thumbnail.jpg&return=www.example.com/'">
    

    Add to Cart

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search