asp.net - Submit form that posts to another site -


i have online banking login i'm trying take old client site , put on new site. if copy form , paste new site, reloads page when submitted. i've tried change asp.net form using appropriate , other applicable tags same result.

if take form , put in simple index.html file, submits , takes me correct external site.

i unable set id & values asp.net form , may 1 of issues.

any appreciated.

here html form version works in .html page needs work in .aspx page:

<form action="some external site" method="post" autocomplete="off" target="_top">      <input type="hidden" name="sssid" value="my value">     <input type="hidden" name="iid" value="another value">      <div class="field-container">        <label for="aid" id="aid-label">access id</label>        <input name="aid" id="aid" type="text" size="8" onfocus="toggle_label(this, 'focus');" onblur="toggle_label(this,'blur');" />     </div>      <div class="field-container">         <label for="passcode" id="passcode-label">passcode</label>         <input name="passcode" id="passcode" type="password" size="8" onfocus="toggle_label(this, 'focus');" onblur="toggle_label(this,'blur');"/>     </div>      <div class="form-row">         <input type="submit" name="submit" value="go" class="button">     </div> </form>  

here asp.net form version tried:

<form action="some external site" method="post" autocomplete="off" target="_top">     <input type="hidden" name="sssid" value="some value">     <input type="hidden" name="iid" value="another value">     <asp:textbox runat="server" id="sssid" cssclass="form-control" type="hidden" clientidmode="static"></asp:textbox>     <asp:textbox runat="server" id="iid" cssclass="form-control"      type="hidden" clientidmode="static"></asp:textbox>     <div class="form-group">        <asp:label runat="server" id="lblaccessid"></asp:label>        <asp:textbox runat="server" id="txtaccessid" cssclass="form-control">    </asp:textbox>     </div>     <div class="form-group">         <asp:label runat="server" id="lblpasscode"></asp:label>         <asp:textbox runat="server" id="txtpasscode" cssclass="form-control" textmode="password"></asp:textbox>                                                 </div>     <button type="submit" class="btn btn-blue">go        <img src="/content/img/icon-sm-arrow.png" alt="" />     </button> </form> 

my asp.net form code behind:

protected void page_load(object sender, eventargs e)     {         txtaccessid.attributes.add("placeholder", "access id");         txtpasscode.attributes.add("placeholder", "passcode");              } 

i had use following post correctly:

<asp:linkbutton runat="server" id="btnsubmit" cssclass="btn btn-blue" postbackurl="urlhere" text='go <img src="/content/img/icon-sm-arrow.png" alt="" />' /> 

Comments

Popular posts from this blog

python - TypeError: start must be a integer -

c# - DevExpress RepositoryItemComboBox BackColor property ignored -

django - Creating multiple model instances in DRF3 -