Web Analytics Made Easy -
StatCounter Prpopulate a form on someone elses website - CodingForum

Announcement

Collapse
No announcement yet.

Prpopulate a form on someone elses website

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Prpopulate a form on someone elses website

    Hello

    I am trying to pre populate someone elses form with our specific discount code using a link from our website to their form.

    I have tried the following with no luck

    Code:
    baseURL?referal_code=MYCODE
    baseURL&referal_code=MYCODE
    The form im trying to add the code into is
    Code:
    <form action="/welcome?destination=welcome" method="post" id="mco-frontpage-frontpage-reference-code-form" accept-charset="UTF-8" _lpchecked="1"><div><div class="form-item form-type-textfield form-item-referal-code">
      <label for="edit-referal-code">Reference code <span class="form-required" title="This field is required.">*</span></label>
     <input type="text" id="edit-referal-code" name="referal_code" value="" size="15" maxlength="128" class="form-text required">
    </div>
    <input type="submit" id="edit-submit--2" name="op" value="Submit" class="form-submit"><a href="/user/password">Reset Password</a><input type="hidden" name="form_build_id" value="form-ARwA9jfIR9JkdeUJFItz6uRLo729bTs04MqWFE42YZY">
    <input type="hidden" name="form_id" value="mco_frontpage_frontpage_reference_code_form">
    </div></form>
    Can anybody tell me what i am doing wrong

    Thanks in advance

  • #2
    If your trying to do this for everyone that fills in this form you might be surprised to find that it can not be done. If you want to do it when you fill out the form why not just make your own form on your site and place what you want where you want it?
    Code:
    <form action="/welcome?destination=welcome" method="post" id="mco-frontpage-frontpage-reference-code-form" accept-charset="UTF-8" _lpchecked="1">
    	<div class="form-item form-type-textfield form-item-referal-code">
    	<label for="edit-referal-code">Reference code <span class="form-required" title="This field is required.">*</span></label>
    	<input type="text" id="edit-referal-code" name="referal_code" value="[COLOR="#FF0000"]ANY THING YOU WANT HERE[/COLOR]" size="15" maxlength="128" class="form-text required">
    	</div>
    	<input type="submit" id="edit-submit--2" name="op" value="Submit" class="form-submit">
    	<a href="/user/password">Reset Password</a>
    	<input type="hidden" name="form_build_id" value="form-ARwA9jfIR9JkdeUJFItz6uRLo729bTs04MqWFE42YZY">
    	<input type="hidden" name="form_id" value=[COLOR="#FF0000"]"I THINK THIS IS WHERE YOU WANT YOUR CODE[/COLOR]">
    </form>
    Evolution - The non-random survival of random variants.
    Physics is actually atoms trying to understand themselves.

    Comment

    Working...
    X