Here is my code:
<%
Sub showKeywords(connobj)
Dim strHTML
Dim rs
Set rs = Server.CreateObject ("ADODB.Recordset"
sql = "Select keywords FROM products;"
rs.Open sql, connobj, adOpenForwardOnly,adLockReadOnly,adCmdText
If not rs.EOF then
strHTML = "<META NAME=" & "keywords content="
While Not rs.EOF
strHTML = strHTML & rs("keywords"
rs.MoveNext
Wend
strHTML = strHTML & ">"
Else
strHTML = "No keywords found."
End if
rs.Close
Set rs = Nothing
Response.Write strHTML
End Sub
%>
All i am trying to do is take the keywords from my database and ad them to a meta tag. My database has 8 products and it takes the keywords from all eight products instid of the one displayed on the page? How do i make it only use keywords for certain products? Example: If you click on "Car" I want it to get the keywords from the record "Car", field "keywords" and insert them in the meta tag for that page?
This one has me !!
Thanks,
AirSki
<%
Sub showKeywords(connobj)
Dim strHTML
Dim rs
Set rs = Server.CreateObject ("ADODB.Recordset"
sql = "Select keywords FROM products;"
rs.Open sql, connobj, adOpenForwardOnly,adLockReadOnly,adCmdText
If not rs.EOF then
strHTML = "<META NAME=" & "keywords content="
While Not rs.EOF
strHTML = strHTML & rs("keywords"
rs.MoveNext
Wend
strHTML = strHTML & ">"
Else
strHTML = "No keywords found."
End if
rs.Close
Set rs = Nothing
Response.Write strHTML
End Sub
%>
All i am trying to do is take the keywords from my database and ad them to a meta tag. My database has 8 products and it takes the keywords from all eight products instid of the one displayed on the page? How do i make it only use keywords for certain products? Example: If you click on "Car" I want it to get the keywords from the record "Car", field "keywords" and insert them in the meta tag for that page?
This one has me !!
Thanks,
AirSki