View Full Version : HTTP://were.com

07-03-2002, 10:07 AM
I have made my websites .htaccsess file to display an error page when a file is not found. I now NEED to know the folowing:

??) How can i make javascript print the WHOLE location of the site (I.E. "http://my.com/badurl") and on the NEXT line, display the 'minimized' version (I.E. "my.com")

Thanks in advance for the help!!!

07-03-2002, 12:07 PM
document.write(window.location.href); // full url
document.write(window.location.hostname); // only the domain