http://themeforward.com/demo2/2011/01/17/testing-comments/

URL file-access is disabled within the server - may be the error I am getting with Short Web addresses. I am no PHP coder, if you could publish the code I ought to be utilising I'd be thankful! How do you rewrite the road?

In functions:

//////////////////////////////////////// Custom templates: page templates
add_filter('single_template', create_function('$t', 'foreach( (array) get_the_category() as $cat ) { if ( file_exists(TEMPLATEPATH . "/single-{$cat->term_id}.php") ) return TEMPLATEPATH . "/single-{$cat->term_id}.php"; } return $t;' ));

The phone call:

<?php $turl = getTinyUrl(get_permalink($post->ID));
echo 'Short URL <a href="'.$turl.'">'.$turl.'</a>' ?>

If PHP has cURL enabled you can include this function:

function getTinyUrl2($url) {
  $ch = curl_init();

  curl_setopt($ch, CURLOPT_HEADER, 0);
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //Set curl to return the data instead of printing it to the browser.
  curl_setopt($ch, CURLOPT_URL, "http://tinyurl.com/api-create.php?url=".$url);

  $data = curl_exec($ch);
  curl_close($ch);

  return $data;
}

after which improve your code to make use of the brand new function:

$turl = getTinyUrl2(get_permalink($post->ID));
echo 'Tiny Url for this post: <a href="'.$turl.'">'.$turl.'</a>'

Hope that can help

Tinyurl.com doesn't get you file by php's file_get_contents function. Use curl rather to make use of tinyurl api.

<?php
   $url = "http://example.com";
   $ch = curl_init("http://tinyurl.com/api-create.php?url=".$url);
   curl_setopt($ch, CURLOPT_RETURNTRANSFERT, true);
   $tinyurl = curl_exec($ch);
   curl_close($ch);
?>