Got an aspx page with a button and an associated code in VB.net.
On my testing server the page works fine.
On the old hosters server the page worked fine too.
But now, at the new hoster it does not.
When I click on the submit button: nothing happens.
The only thing that works is form validation.
I pasted the code below.
It's a login page, but I added this in the code to be sure that the problem
is on this page:
response.write( "ok1")
So even this ok1 does not appear.
In fact, when I click on the button, the page is not posted.
Could it be a setting at the hosters server. The hoster says asp.net
scripting is active for the whole site.
PS: other aspx pages on the same website with buttons etc do work at that
hoster.
I really don't get it.
THX for help !
############### ######## CODE START ############### ########
<%@ Page Language="VB" ContentType="te xt/html" ResponseEncodin g="iso-8859-1"
%>
<%@ Register TagPrefix="MM" Namespace="Drea mweaverCtrls"
Assembly="Dream weaverCtrls,ver sion=1.0.0.0,pu blicKeyToken=83 6f606ede05d46a, c
ulture=neutral" %>
<MM:DataSet
id="dsusers"
runat="Server"
IsStoredProcedu re="false"
ConnectionStrin g='<%#
System.Configur ation.Configura tionSettings.Ap pSettings("MM_C ONNECTION_STRIN G
_connusers") %>'
DatabaseType='< %#
System.Configur ation.Configura tionSettings.Ap pSettings("MM_C ONNECTION_DATAB A
SETYPE_connuser s") %>'
CommandText='<% # "SELECT * FROM tbl_users WHERE user_name = ? AND
user_password = ?" %>'
Debug="true"
<Parameters>
<Parameter Name="@user_nam e" Value='<%# IIf((Request.Fo rm("user_name" )
<> Nothing), Request.Form("u ser_name"), "") %>' Type="WChar" />
<Parameter Name="@user_pas sword" Value='<%#
IIf((Request.Fo rm("user_passwo rd") <> Nothing),
Request.Form("u ser_password"), "") %>' Type="WChar" />
</Parameters></MM:DataSet>
<MM:PageBind runat="server" PostBackBind="t rue" />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>LOGIN</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="backoffic e.css" rel="stylesheet " type="text/css">
</head>
<body>
<p> </p>
<p> </p>
<form method="POST" enctype="applic ation/x-www-form-urlencoded" id="form1"
runat="server">
<table width="379" height="379" border="0" align="center"
background="ima ges/selfmanager.jpg " class="tblresul ts">
<tbody>
<tr>
<td height="190" valign="bottom" ><div align="center"> <strong>
</strong></div></td>
</tr>
<tr>
<td><div align="center" class="style1">
</div></td>
</tr>
<tr>
<td><div align="center"> </div></td>
</tr>
<tr>
<td bgcolor="#FFFFF F"><div align="center" class="style3"> <span
class="style1"> <span class="style2">
<asp:Label ID="txt_failed " runat="server" />
</span></span>Gebruikers naam:</div></td>
</tr>
<tr>
<td>
<div align="center">
<asp:TextBox id="user_name" runat="server"> </asp:TextBox>
<asp:RequiredFi eldValidator ID="RequiredFie ldValidator1"
EnableClientScr ipt="true" Display="Dynami c" ErrorMessage="V erplicht"
ControlToValida te="user_name" runat="server"> </asp:RequiredFie ldValidator>
</div></td>
</tr>
<tr>
<td bgcolor="#FFFFF F"><div align="center"
class="style3"> Wachtwoord:</div></td>
</tr>
<tr>
<td>
<div align="center">
<asp:TextBox ID="user_passwo rd" runat="server" TextMode="Passw ord"
/>
<asp:RequiredFi eldValidator ID="RequiredFie ldValidator2"
EnableClientScr ipt="true" Display="Dynami c" ErrorMessage="V erplicht"
ControlToValida te="user_passwo rd"
runat="server"> </asp:RequiredFie ldValidator>
</div></td>
</tr>
<tr>
<td><div align="center"> </div></td>
</tr>
<tr>
<td>
<div align="center">
<asp:Button ID="submit" OnClick="onlogi n" runat="server"
Text="LOG-IN"></asp:Button>
</div></td>
</tr>
<tr>
<td>
<div align="center">
<script runat="server">
sub onlogin (sender As Object, e As System.EventArg s)
response.write( "ok1")
if dsusers.recordc ount > 0 then
Formsauthentica tion.redirectfr omloginpage("ba ckoffice", true)
response.redire ct("/backoffice/accesslevel1/index.aspx")
else if ((request.form( "user_password" )))<> nothing OR
((request.form( "user_name" ))) <> nothing
txt_failed.text ="Login MISLUKT. Probeer opnieuw."
end if
end sub
</script>
</div></td>
</tr>
</tbody>
</table>
</form>
</body>
</html>
############### ######## CODE END ############### ########