added evalURL()-function

This commit is contained in:
Robert Gaggl 2001-10-02 10:55:33 +00:00
parent 0a11c9c515
commit cd7adeca02

View file

@ -132,3 +132,13 @@ function activateLinks (str) {
return (str); return (str);
} }
/**
* function checks if url is correct
* if not it assumes that http is the protocol
*/
function evalURL(url) {
if (url.indexOf("://") < 0)
return ("http://" + url);
return (url);
}