IP grabber for IE


  1. hanzy

This archived discussion is "read only".
For the corresponding "live" discussions, post in the active topic forum here.



Top 1.   Jan 2, 2003 8:31 AM

» hanzy - IP grabber

I've been asked to setup an IP grabber at work, just to make the user's life a little easier..

I've found some code and can't get it to work...
I know where the problem is but haven't a clue how to fix it..

I am a complete beginner so any help would be very much appreciated.

The code is as follows

//IP address display: By http://www.Hostroute.com
//Script featured on Website Abstraction (http://wsabstract.com)

var ip = ''

function ipval() {
document.myform.ipaddr.value=ip;
}
window.onload=ipval



I know the problem relates to the line

var ip = ''

As when run the users IP address isn't found it just prints ''

Any help, I'd be very grateful

Hannah

-- posted by hanzy



Please follow the guidelines set forth in the Suite101 Posting Etiquette when adding to the discussion.