<%
    my ($item,$prjid) = @_;
    my ($id,$url,$title,$target,%opts) = @$item;
    my $dest = $url ? $url : $id;

    my $tgtsfx = $opts{prepend_prjname_to_target} ? $prjid : '';
    $tgtsfx =~ s/[^a-zA-Z_0-9]/_/g;
%>
<a 
    href=<%$ $opts{jsopenopts} ? '#' : $dest %>
    <%$ $target && !$opts{jsopenopts} ? "target=$target$tgtsfx " : '' %> 
<% if ($opts{jsopenopts}) { 
    my $s = 'onclick="openwnd(' . "'$dest', " . ($target ? "'$target$tgtsfx'" : '') .
	",'$opts{jsopenopts}')" . ';"';
    print $s;
} %>

><%= $title %></a>
<% if ($opts{addnojslink}) { %>
    <noscript>
	<a href=$dest?nojs=1 >[no-scripts-version]</a>
    </noscript>
<% } %>
