Is it possible to log and save ip addresses using HTML?

liunx

Guest
I wanted to know if it is possible to log and save IP addresses using HTML, I know it's possible using PHP and other stuff.<br />
<br />
But I was wondering if it was possible with HTML.<br />
<br />
If it is... can someone please guide me through...<br />
<br />
Tons of thanks in advance :) .<br />
<br />
Peace out.<!--content-->Guess not... you can only detect browser and platform and stuff, but no IP. You can do that using VBScript or something (I guess).<br />
<br />
JayDie<!--content-->Even what JayDie is mentioned cannot be done with HTML, Javascript yes, but not HTML<!--content-->Can you detect IP with JavaScript??? Don't think so... How then?<br />
<br />
I thought you can do it with VBScript (for example ASP, server side...)<br />
<br />
JayDie<!--content-->Server side is the easiest way, and then allowing it to write to the page, and then load. Netscape will allow Javascript to pull IP addresses, but this is not reliable. VBScript may have the power, but this is more of a language built of an application language, so its web features aren't too impressive, so I am not too sure about it. I will research the topic :)<!--content-->Well it is possible to get IPs using javascript... I saw and used a couple of javascripts like...<br />
<br />
<SCRIPT LANGUAGE="JavaScript"><br />
// Ip Tracking)<br />
<!-- Begin<br />
var ip = '<!--#echo var="REMOTE_ADDR"-->';<br />
// End --><br />
</script> <br />
<br />
That can be used to see the IP of the surfer... but is it possible to log that IP into a txt file or any other data file?... Are there scripts that can be used to do that?... PHP and ASP do allow it... but I'm trying to find a way with HTML, Javascript :confused: .<!--content-->that is netscape-compatible only, so in IE and Mozilla, this will cause an error :)<!--content-->actually, that is either an shtml or asp file. Javascript alone can't detect IP addresses<!--content-->http://www.javascriptkit.com/script/script2/displayip.shtml<!--content-->Originally posted by steelersfan88 <br />
<!-- m --><a class="postlink" href="http://www.javascriptkit.com/script/script2/displayip.shtml">http://www.javascriptkit.com/script/scr ... ayip.shtml</a><!-- m --> <br />
That's not plain JS...<!--content-->Paul, I did read that on the page, and it probably is not reliable for free servers anyway, but the fact that it uses Netscape only pretty much eliminates it from use, I think we can agree.<br />
<br />
And indeed, it is SHTML, I sent the link to confirm samij586's belief of asp or shtml file, not to say it was javascript, just in case of misinterpretation, wanted to make it clear :)<!--content-->Originally posted by steelersfan88 <br />
And indeed, it is SHTML, I sent the link to confirm samij586's belief of asp or shtml file, not to say it was javascript, just in case of misinterpretation, wanted to make it clear :) <br />
Ahh, pardon the confusion, I thought you were responding to: Javascript alone can't detect IP addresses of Sam's post. :D<!--content-->no, that's ok, i definately should have done more than give a link, i would edit it if we had not just made it clearer in these following posts<!--content-->quote:<br />
--------------------------------------------------------------------------------<br />
Originally posted by steelersfan88 <br />
<!-- m --><a class="postlink" href="http://www.javascriptkit.com/script...displayip.shtml">http://www.javascriptkit.com/script...displayip.shtml</a><!-- m --> <br />
--------------------------------------------------------------------------------<br />
<br />
Hey thanks for your replies :) ... but steelersfan88... that link that you posted, shows a wrong IP address... but this... <br />
<br />
<!-- m --><a class="postlink" href="http://simplythebest.net/scripts/javascript_118.html">http://simplythebest.net/scripts/javascript_118.html</a><!-- m --><br />
<br />
Shows my right IP address... I'm still confused, because you said that the script I posted earlier causes an error with IE and Mozilla... and only works with Netscape. But I use IE 6 <br />
:confused: . I've never used Netscape, I run windows XP.<br />
<br />
Well I really appreciate your replies. Thanks :) . Peace out bros... sorry for my lame questions, but I'm new to all this :D .<!--content-->Both sites give me the same ip address. Note that the one HTML file is not-standalone and can not alone detect your ip address, as Paul and i discussed earlier :)<!--content-->Oh ok... thanks for clearing that out... I am new to all this and got to learn a lot ;) ... but thanks for your replies all of you. Great site... keep up the good work :D .<!--content-->
 
Back
Top