I have this code in default.aspx
PHP Code:
<asp:Label id="ids" runat="server" CssClass="aspnetmaker" Visible="FALSE"></asp:Label>
<asp:Label id="DIV1" runat="server" Visible="True"></asp:Label>
I cannot display the second asp:Label( id="DIV1").
And also, the asp:Label(id="ids") is not "Hi".
The code behind is default.aspx.vb(below)
Whats the problem?
PHP Code:
Imports System
Imports System.Web
Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.HtmlControls
Imports System.Web.UI.WebControls
Imports System.Data
Imports System.Data.SqlClient
Imports Microsoft.VisualBasic
Namespace mygdi
Public Class ewdefault
Inherits System.Web.UI.Page
Protected WithEvents ids As Label
Protected WithEvents DIV1 As Label
Dim fname
'*********************
' Page Load Handler
'*********************
Private Sub Page_Load(ByVal s As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim test
Dim useridStr As String
Response.Cookies.Remove("hi")
If Not fname = Request.Cookies("hi").Value Is Nothing Then
Dim aCookie As HttpCookie = Request.Cookies("hi")
ids.Text = Server.HtmlEncode(aCookie.Value)
useridStr = ids.Text
ids.Text = "NIL"
End If
Dim oewdb As ewdb = New ewdb
Dim sTmp As String
Dim sSelect As String
Dim sConnStr As String = oewdb.ewConnStr ' Get Connection String
sSelect = "SELECT * FROM [Users] WHERE [UserName] = useridStr"
'" & sTmp & "'"
Dim objDataReader As SqlDataReader
Dim oConn As New SqlConnection(sConnStr)
oConn.Open() ' Open the Connection to the Database
Dim objCommand As New SqlCommand(sSelect, oConn)
objDataReader = objCommand.ExecuteReader()
Dim useridDB, passwordDB As String
useridDB = objDataReader("Us")
ids.Text = "NIL"
DIV1.Text = "hello"
End Sub
Private Sub InitializeComponent()
End Sub
End Class
End Namespace
__________________
$id ="waxxer";
$id = str_replace('x', 'l', $id);
echo $id;
echo " and Marj";
|