We are over thinking this. If you want to limit this to Jot comments we can somply use a PHX custom modifier and apply it to the comments field. I took the code above and placed it in a phx modifier (a snippet with phx: name prefix):
<?php
/*
* parse links
*/
$t = $output;
// match protocol://address/path/
$t = ereg_replace("[a-zA-Z]+://([.]?[a-zA-Z0-9_/-])*", "<a href=\"\\0\">\\0</a>", $t);
// match www.something
$t = ereg_replace("(^| |\n)(www([.]?[a-zA-Z0-9_/-])*)", "\\1<a href=\"http://\\2\">\\2</a>", $t);
return $t;
?> Then in the Jot comment tpl I added the modifier to the chunk.comment.inc.html file at around line 38
<div class="jot-message">[+comment.content:wordwrap:esc:nl2br:parseLinks+]</div>
THis worked for parsing any http:// items, the www items are not working. My guess is that there is something wrong with the regex.
Anyway, this is a start.
Edit: this code has been fixed as described bellow.