Easiest way is to use the Replace function built in to CF. http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=functions_m-r_32.html
<http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=functions_m-r_32.html>If you have multiple instances of the replacement value be sure to specify the "All" scope. You may also want to look at the ReplaceNoCase function. Brian Cain On Fri, Apr 1, 2011 at 10:22 AM, Scott Williams <myscottwilli...@yahoo.com>wrote: > > Hi all -- > > I have a script that draws some text from a database, and I would like to > embed > a person's name within the text. > > For example, the database field contains this text: > > Hi #name#. How's it going? > > I would like the #name# to be replaced with a previously defined variable > "name." > > Can ColdFusion do this? If so, how? > > Scott > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:343464 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm