View Single Post
Old 11-10-2012, 10:07 PM   PM User | #5
anarchoi
New Coder

 
Join Date: May 2007
Posts: 56
Thanks: 4
Thanked 0 Times in 0 Posts
anarchoi is an unknown quantity at this point
I have tried following this tutorial:
http://www.simonerodriguez.com/ajax-...ubmit-example/

But it's not working I don't understand what i'm doing wrong

Code:
<html>
<head>
  <script src="http://code.jquery.com/jquery-latest.js"></script>
  <script src="scripts/ajaxsbmt.js" type="text/javascript"></script>
</head>
<body>

<form name="MyForm" action="https://nidieunimaitre.spreadshirt.com/shop/basket/addtobasket" method="post"
onsubmit="xmlhttpPost('https://nidieunimaitre.spreadshirt.com/shop/basket/addtobasket, 'MyForm', 'MyResult', '<img src=\'pleasewait.gif\'>'); return false;">
    <input type="hidden" name="product" id="productId" value="101894422"/>
    <input type="hidden" name="article" id="articleId" value="10568008"/>
    <input type="hidden" name="view" id="currentView10568008" value="351"/>
    <input type="hidden" name="color" id="productColor10568008" value="2"/>

Size
<select class="b-core-ui-select__select" id="size" name="size"><option value="2" >S</option><option selected value="3" >M</option><option value="4" >L</option><option value="5" >XL</option><option value="6" >XXL</option></select>
<br>

Quantity
<select class="b-core-ui-select__select" id="quantity" name="quantity">
<option selected value="1" >1</option>
<option value="2" >2</option>
</select>

<br>

<input name="send_button" type="submit" value="Send" />
</form>


<div id="MyResult"></div>

</body>
</html>
anarchoi is offline   Reply With Quote