i am not concerned with validation right now. The script above doesnt work.
All i am trying to do is hyperlink a commenters name if they leave a web site URL when making a comment. If they dont leave a url i just want to dosplay the name with no hyperlink.
The reason i am doing this is that i noticed that if you hyperlink all names with the url, then if the filed was left blank then the the default url is the name of the post. i dont want that!!
so i tried this php code, but it is giving me strange results:-
$urlentered = comment_author_url();
echo '<span class="commentauthor"><a href="',comment_author_url(),'" target="_blank">', comment_author(), ' </a></span>';
echo '<span class="commentauthor">', comment_author(), ' </span>';
The strange result is that the url - when present- gets printed before the span tag.
I've been struggling with this for days now!!!