Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CF returning extra HTML

Status
Not open for further replies.

ded

Programmer
Nov 3, 2000
41
0
0
GB
Anyone any ideas how to solve this one.

If I write the following CF page

Code:
<CFOUTPUT>#now()#</CFOUTPUT>

then when I access it through the server I get

Code:
<!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0 Transitional//EN&quot;>

<html>
<head>
	<title>Untitled</title>
</head>

<body>



</body>
</html>
{ts '2002-05-20 14:26:36'}

when all I want is

Code:
{ts '2002-05-20 14:26:36'}

Any ideas? I am using CF 4.0

Cheers,
Duncan
 
Hey Duncan,

My guess is that you have an application.cfm somewhere that's inserting the unwanted code or either your webserver is somehow configured to add it. I would put an application.cfm file in the same directory as your script with just a single line

<cfset x=0>

If this solves the problem, you just need to look up the directory tree until you find the application.cfm that's causing the problem. If that doesn't fix it, I would ask what webserver you're using as that's the only other thing I could see that would add the unwatned html.

Hope this helps,
GJ
 
Thanks GJ,

It was a rogue Application.cfm, I don't think my brain was with me yesterday.

Cheers,
Duncan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top