Ask a Question related to ASP Components, Design and Development.
-
mallyonline #1
Response.Write "<b>You are not logged on............
I last posted to this group about 6 months ago and was very pleased by the
excellent response I got and the great help offered to me. I am back this
time with another request for your expert help on a bit of ASP code I use on
my windows server 2003 with IIS6 machine.
I would like the code below to display in different colours depending on the
status of the page. I am looking to make the not logged in code appear red
and the logged in code green.
The code:
<%
If Len(Session("UID")) = 0 Then
Response.Write "<b>You are not logged on. If You don't have a username
or password you can register for one by clicking > </b>"
Else
Response.Write "<b>You are logged on as " & Session("UID") & "</b>"
End If
%>
If anyone can help this would be great.
Thank you
malcolm
mallyonline Guest
-
response.write URL
I have a page which lists conferences and events which the company for which I coded the site attends or hosts themselves. They want to be able to... -
If response.write help
Hi, I am trying to code my asp page so that if you are on page Y, the link to page Y in the nav, is in the over state to help users identify where... -
Response.Write and Response.Redirect
On my Page_Load event, i need to do some validation and then either let them proceed, or display a error message and boot them back to the previous... -
Response.write tables
There are no "table commands". If you're going to be doing any ASP at all, the first thing you should do is find out about HTML. <table> <% do... -
asp response.write doesn't display
Maybe you could start with a more barebones file, especially one without an unclosed LINK tag: -
McKirahan #2
Re: Response.Write "<b>You are not logged on............
"mallyonline" <malcolmkwhyte@btinternet.com> wrote in message
news:di6jor$3ba$1@nwrdmz01.dmz.ncs.ea.ibs-infra.bt.com...on> I last posted to this group about 6 months ago and was very pleased by the
> excellent response I got and the great help offered to me. I am back this
> time with another request for your expert help on a bit of ASP code I usethe> my windows server 2003 with IIS6 machine.
>
> I would like the code below to display in different colours depending onred> status of the page. I am looking to make the not logged in code appear> and the logged in code green.
>
> The code:
> <%
> If Len(Session("UID")) = 0 Then
> Response.Write "<b>You are not logged on. If You don't have a username
> or password you can register for one by clicking > </b>"
> Else
> Response.Write "<b>You are logged on as " & Session("UID") & "</b>"
> End If
> %>
>
> If anyone can help this would be great.
>
> Thank you
>
> malcolm
This changes the background color:
<%
If Len(Session("UID")) = 0 Then
Response.Write "<b style="background-color:lightgreen">You are not
logged on. If You don't have a username or password you can register
for one by clicking.</b>"
Else
Response.Write "<b style="background-color:red">You are logged on as " &
Session("UID") & "</b>"
End If
%>
This changes the font color:
<%
If Len(Session("UID")) = 0 Then
Response.Write "<b style="color:green">You are not logged on. If
You don't have a username or password you can register for one by
clicking.</b>"
Else
Response.Write "<b style="color:red">You are logged on as " &
Session("UID") & "</b>"
End If
%>
McKirahan Guest
-
arunkumar_m2001@yahoo.com #3
Re: Response.Write "<b>You are not logged on............
Hi Malcolm,
If you want the text to display in the desired color try this
<%
If Len(Session("UID")) = 0 Then
Response.Write "<b>" & "<font color = red>" & "You are not logged
on. If You don't have a username or password you can register for one
by clicking" & "</font>" & "</b>"
Else
Response.Write "<b>" & "<font color = green>" & "You are logged on
as " & "</font>" & "</b>"
End If
%>
Arun
arunkumar_m2001@yahoo.com Guest



Reply With Quote

