Here's what I have so far.
In the head:
Code:
<%
Dim rsArticles
Dim rsArticles_cmd
Dim rsArticles_numRows
Set rsArticles_cmd = Server.CreateObject ("ADODB.Command")
rsArticles_cmd.ActiveConnection = MM_Classifieds_STRING
rsArticles_cmd.CommandText = "SELECT * FROM AD WHERE CLASS_NUMBER = '99' ORDER BY START_DATE ASC"
rsArticles_cmd.Prepared = true
Set rsArticles = rsArticles_cmd.Execute
rsArticles_numRows = 0
%>
<%
Dim Repeat1__numRows
Dim Repeat1__index
Repeat1__numRows = -1
Repeat1__index = 0
rsArticles_numRows = rsArticles_numRows + Repeat1__numRows
%>
This is where the ads will display in the body:
Code:
<img src="<%=(rsArticles.Fields.Item("IMAGE1").Value)%>" width="32" height="32" /> <%=(rsArticles.Fields.Item("AD_TEXT").Value)%>
I have an image pulling from the database but when there isn't one I need it to be nothing. And of course displaying the image in a certain place depending on the type in the image1Typ field.
Bookmarks