473,545 Members | 2,413 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

IP Address

I'm new to this group on here, but I wanted to know if anyone knows how to
display an IP address using javascript. Thanks in advance.

Randy
Jul 23 '05 #1
4 2093
MRBEATZ wrote:
I'm new to this group on here, but I wanted to know if anyone knows how to
display an IP address using javascript. Thanks in advance.


No. JS has no way of determining the IP Address so it has no way to
display it, on its own.
--
Randy
comp.lang.javas cript FAQ - http://jibbering.com/faq & newsgroup weekly
Jul 23 '05 #2
On Sat, 05 Mar 2005 22:33:27 -0500 Randy Webb wrote:
MRBEATZ wrote:
I'm new to this group on here, but I wanted to know if anyone knows how
to display an IP address using javascript. Thanks in advance.


No. JS has no way of determining the IP Address so it has no way to
display it, on its own.


http://javascript.internet.com/user-...p-address.html

Actually, it sneaks in a simple line of php coding to do it.
I have seen some total javascripts do the trick.
Question is will they actually detect the true IP of the visitor's machine
or not?
To better trap the IP would be best done server side with php.

Jul 23 '05 #3
Richard wrote:
On Sat, 05 Mar 2005 22:33:27 -0500 Randy Webb wrote:

MRBEATZ wrote:

I'm new to this group on here, but I wanted to know if anyone knows how
to display an IP address using javascript. Thanks in advance.
No. JS has no way of determining the IP Address so it has no way to
display it, on its own.

http://javascript.internet.com/user-...p-address.html


That site does not use JS to get the IP Address, only to display it. It
relies on server side scripting to attempt to get the IP Address. Before
attempting to correct me in the future, try actually reading (and
understanding) what I said. You do know though that they have a *reason*
for calling you RtS?
Actually, it sneaks in a simple line of php coding to do it.
Actually, its not PHP, but it is a server side scripting language.
PHP code does not start:
<!--#echo var="REMOTE_ADD R"-->

PHP tags either start with <? or <?PHP
I have seen some total javascripts do the trick.
No you haven't. But you are welcome to *attempt* to prove me wrong.
Question is will they actually detect the true IP of the visitor's machine
or not?
Doesn't matter since IP addresses are as worthless as the hairs on a
chicken's ass.
To better trap the IP would be best done server side with php.


And if a user does not have PHP available? Hmmmm

--
Randy
comp.lang.javas cript FAQ - http://jibbering.com/faq & newsgroup weekly
Jul 23 '05 #4
MRBEATZ wrote on 06 mrt 2005 in comp.lang.javas cript:
I'm new to this group on here, but I wanted to know if anyone knows
how to display an IP address using javascript. Thanks in advance.


document.write( "123.456.1. 1");

Is it about displaying "an" IP or
about determining what your own IP is?

The server often sees another IP adres [router, proxi],
than your browser uses.

Serverside asp example using clientside javascript to display:

document.write( "<%=request.ser vervariables("r emote_addr")%>" );

With pure clientside javascript it is impossible, I believe.

--
Evertjan.
The Netherlands.
(Replace all crosses with dots in my emailaddress)

Jul 23 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

21
15665
by: Alexander N. Spitzer | last post by:
If I have a machine with 3 virtual IP addresses (192.168.1.), how can I start 3 instances of the same RMI application (each started with different properties/configs), each listening on the port 1234, but each instance binds to a different ip address. that is to say: instance #1 binds to 192.168.1.5/port 1234 instance #2 binds to...
8
4580
by: YAN | last post by:
Hi, I want to get the mac address from a machine, which i have the IP address of that machine, how can i do that? I know how to get the mac address of the local machine from the following code: Dim mc As System.Management.ManagementClass Dim mo As System.Management.ManagementObject mc = New...
7
21276
by: Privacy Advocate | last post by:
//crossposted to: comp.lang.javascript, alt.comp.lang.javascript in an effort to get factual answers from JavaScript experts// Simply put; Is it possible to obtain the real (actual) IP address of someone (client) that visits a web site through an anonymous proxy if this person ONLY has JavaScript enabled in their browser? This is NOT a...
33
3124
by: baumann.Pan | last post by:
hi all, i want to get the address of buf, which defined as char buf = "abcde"; so can call strsep(address of buf, pointer to token);
4
6277
by: andreas.w.h.k. :-\) | last post by:
How do I change the address location in the wsdl <wsdl:port name="SearchSoap12" binding="tns:SearchSoap12"> <soap12:address location="http://searchservices/engine/search.asmx" /> </wsdl:port> Anderas
1
2923
by: Phoenix_ver10 | last post by:
I have a mailing list with multiple names going to the same addresses. I need one address with all the names for that address on it. I checked out the example on microsoft's site, but A: It doesn't work (error that there is an extra parenthise (sp?) ) and B: Will only let in two names for each record. If there are three, the middle on is...
1
2349
by: Jamie J. Begin | last post by:
I'm very new to the world of Python and am trying to wrap my head around it's OOP model. Much of my OOP experience comes from VB.Net, which is very different. Let's say I wanted to create an object that simply outputted something like this: Developer Detroit Michigan
6
7016
by: Nicolas Noakes | last post by:
Hello, I would like to convert to following process to code. Any advice is welcome. I have a hardware device which requires the this procedure to set it's IP address. First create an static ARP entry for the device's MAC address and the desired IP address. Then telnet to this IP address on TCP port 1. This will set the device to...
36
3362
by: Julienne Walker | last post by:
Ignoring implementation details and strictly following the C99 standard in terms of semantics, is there anything fundamentally flawed with describing the use of a (non-inline) function as an address? I keep feeling like I'm missing something obvious. -Jul To keep things in context, this is in reference to describing functions to a...
1
3113
by: saravanatmm | last post by:
I need javascript code for validate the email address. Email address field cannot allowed the capital letters, special characters except '@' symbol. But can allowed the small letters, numeric numbers. Now i use this script for validate the email address. But it allows the cpital letters otherwise its working correctly. SCRIPT FUNCTION ...
0
7487
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7420
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7680
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7446
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7778
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
4966
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3476
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3459
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1033
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.