Pete Freitag Pete Freitag

Trackbacks with ColdFusion

Updated on September 18, 2023
By Pete Freitag

It's pretty simple to implement trackback pings with CFML, since trackbacks are simply just a HTTP form post to a specific url. The result is an XML file.

So do post a trackback to another blog, simply use CFHTTP:

<cfhttp url="http://the.trackback.url/" 
	<cfhttpparam name="url" value="" type="formfield">
	<cfhttpparam name="title" value="This is the title of your entry" type="formfield">
	<cfhttpparam name="blog_name" value="Your Blog Name" type="formfield">	
	<cfhttpparam name="excerpt" value="An excerpt of your entry" type="formfield">	


The only required parameter is the url of your blog entry, all others are optional.

The resulting XML will look like the following if there are no errors:

<?xml version="1.0" encoding="utf-8"?>

If there is an error, then the result will be something like this:

<?xml version="1.0" encoding="utf-8"?>
 <message>The error message</message>

To receive a trackback ping, it's also pretty simple, because you just handle the form variables, and output the resulting XML.

You can find all this info in the trackback spec (link no longer works:

trackbacks cfml

Trackbacks with ColdFusion was first published on March 29, 2005.

If you like reading about trackbacks, or cfml then you might also like:


The Fixinator Code Security Scanner for ColdFusion & CFML is an easy to use security tool that every CF developer can use. It can also easily integrate into CI for automatic scanning on every commit.

Try Fixinator

The weekly newsletter for the CFML Community