Can I add my own custom HTML form to a page?
You can add a custom HTML form you've created that posts to another web site e.g.for submitting donations to Worldpay. To add your form's HTML code to an article use the Source button in the document editor and then paste your HTML/Javascript code in the required place. There are, however, modifications you'll need to make to your code.
Every article in Insight already contains <form> html tags. This will cause an issue when you try to add you own custom form HTML to the article's source. To resolve the problem you need to remove the <form> tags in the article source and customise the submit button code so it submits the form directly to the external URL the form is being submitted to.
The button code would therefore look something like this:
<input class="sitebutton" id="ArticleSubmitButton" style="WIDTH: 90px" onclick="this.form.action='https://select.worldpay.com/wcc/purchase';" type="submit" name="Send" value="Send" />
You could add any additional parameters you need to pass as hidden fields like so:
<input type="hidden" name="instId" value="67878" /> <input type="hidden" name="accId1" value="675675676" /> <input type="hidden" name="accId2" value="7688989" /> <input type="hidden" name="cartId" value="cartname" /> |