Forums

This topic is locked

Unread records ??

Posted 25 Jul 2004 00:10:05
1
has voted
25 Jul 2004 00:10:05 Al Patel posted:
I am trying to create some email functionality on my website, and I would like to bold or have some unique formatting to records that the user hasn't read yet. How can I do this? I have created a read_yet field in my SQL Server Database that I can use to flag whether an email has been read or not. But how can I format the record based on this when it is returned with other records that have/have not been read?

Thank you, Al

Replies

Replied 29 Jul 2004 00:26:38
29 Jul 2004 00:26:38 Simon Martin replied:
Wrap your messages up in a conditional that tests for the state of your read_yet field. So something a bit like this:
<% if rsEmail("read_yet" = "N" then %>
<b><%= rsEmail("message" %><b />
<% else %>
<%= rsEmail("message" %>
<% end if %>

or whatever formatting you want to apply to your message - Personally I would apply CSS formatting to the unread emails.

You <i>could </i> response.write your 2 outputs rather than breaking up the code as I have done...?

Sharing knowledge saves valuable time!

Simon

[DWMX 2004]|[SQL]|[ASP/VBScript]|[XP-Pro]
Replied 29 Jul 2004 12:57:33
29 Jul 2004 12:57:33 Dave Thomas replied:
plz post your message in only one forum.

ive deleted your post in the Ultradev section.

Regards,
Dave

[DWMX 2004]|[FlashMX 2004 Pro]|[SQL]|[Access2000]|[ASP/VBScript]|[XP-Pro]

Reply to this topic