Forum Moderators: mack
<%
Dim sVar
sVar = "Widgets" ' or your field from a recordset
%>
<html>
<head>
<title>Great Page about <%=sVar%></title>
<meta name="description" content="<%=sVar%> Information, history, resources and more">
</head>
<body>
<h1>Information about <%=sVar%></h1>
<body>
loads of great content
</body>
</html>
mcavill's example is just inserting the text in variable sVar into the html page returned to browsers.
If you work out what content+html you want the asp to generate, then where the content is coming from, building it into the page using similar syntax to the example should be straightforward.
Assuming you have field names in your database called MetaDescrip and MetaKeywords, and each page has a unique ID, your sql will be something like:
SELECT MetaDescrip, MetaKeywords FROM <YourTable> WHERE ID=<YourPageID>
And then you can add them into your HTML page using code like this:
<meta name="description" content="<%=rs("MetaDescrip")%>">
<meta name="keywords" content="<%=rs("MetaKeywords")%>">
HTH