asp.net - My pay pal button will not link to pay pal. It only refreshes page, why? -
i have following code in registration page go paypal button. when click on button refreshes page.
is missing? should able include paypal button on aspx page right?
<asp:content id="content1" contentplaceholderid="head" runat="server"> </asp:content> <asp:content id="content2" contentplaceholderid="contentplaceholder1" runat="server"> <asp:panel runat="server" id="pnlregisterpage" cssclass="registerpage"> <table> <tr> <td><p>plain text</p></td> <td> <form action="https://www.paypal.com/cgi-bin/webscr" method="post"> <input type="hidden" name="cmd" value="_s-xclick"> <input type="hidden" name="hosted_button_id" value="z8tackrhqr722"> <table> <tr><td><input type="hidden" name="on0" value="registration type">registration type</td></tr><tr><td><select name="os0"> <option value="team">team $80.00</option> <option value="individual">individual $40.00</option> </select> </td></tr> </table> <input type="hidden" name="currency_code" value="usd"> <input type="image" src="https://www.paypal.com/en_us/i/btn/btn_buynowcc_lg.gif" border="0" name="submit" alt="paypal - safer, easier way pay online!"> <img alt="" border="0" src="https://www.paypal.com/en_us/i/scr/pixel.gif" width="1" height="1"> </form> </td> </tr> </table> </asp:panel> </asp:content>
master page
<body> <form id="form1" runat="server"> <asp:toolkitscriptmanager id="toolkitscriptmanager1" runat="server"> </asp:toolkitscriptmanager> <div class="masterbody"> <center> <asp:image runat="server" id="imglogo" imageurl="" /></center> <div class="menubar"> <div class="loginview"> <asp:loginview id="menubar" runat="server"> <anonymoustemplate> </anonymoustemplate> <loggedintemplate> </loggedintemplate> </asp:loginview> </div> </div> <div> <asp:contentplaceholder id="contentplaceholder1" runat="server"> </asp:contentplaceholder> </div> </div> <div class="footer"></div> </form> </body>
the master page shows contentplaceholder1 inside asp.net runat="server" form won't able place paypal form inside region. you'll need arange paypal form not inside other form.
a possible solution found here: http://www.codersbarn.com/post/solution-to-aspnet-form---paypal-problem.aspx don't think you'll able have postback events on page form rendering disabled.
Comments
Post a Comment