how to output something like <this is my word=“word” value=“#abcg#”> using cfoutput coldfusion
-
21-12-2019 - |
Question
how to output something like using cfoutput tag.
<cfoutput>
<this is my word="word" value="#abcg#">
</cfoutput>
this will gives me nothing when i use single-quote it will print it with single-quote like
<cfoutput>
<'this is my word="word" value="#abcg#"'>
</cfoutput>
result is:
<'this is my word="word" value="#abcg#"'>
how can i get just
<this is my word="word" value="#abcg#">
thanks for the help
Solution
You can use the following to escape the browser trying to render it as an HTML tag
<cfoutput>
<this is my word="word" value="#abcg#">
</cfoutput>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow