| | |
title tag
Please support our ColdFusion advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Thread Solved |
Here's one way:
Get your db information before you output the <head> tag on your page.
Inside the <title> tag, output the info from your query. For example:
Obviously, replace the query with your own, but you get the general idea?
Let me know if you need more help.
Get your db information before you output the <head> tag on your page.
Inside the <title> tag, output the info from your query. For example:
ColdFusion Syntax (Toggle Plain Text)
<cfquery datasource="dsn" name="pageData"> SELECT * FROM pageContent WHERE pageID = #pageID# </cfquery> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title><cfoutput>#pageData.Title#</cfoutput></title> </head>
Obviously, replace the query with your own, but you get the general idea?
Let me know if you need more help.
![]() |
Similar Threads
- Need to read "Title tag" and "original date" of pictures (Visual Basic 4 / 5 / 6)
- What is the most important tag for SEO? (Search Engine Optimization)
- Meta Tag Considerations (Search Engine Optimization)
Other Threads in the ColdFusion Forum
- Previous Thread: Get values
- Next Thread: Insert query.
| Thread Tools | Search this Thread |





