# IP address

**URL:** <https://forum.kirupa.com/t/ip-address/14519>\
**Category:** random\
**Created:** [February 27, 2003, 7:04am UTC](https://forum.kirupa.com/t/ip-address/14519 "2003-02-27T07:04:07Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![lava](https://avatars.discourse-cdn.com/v4/letter/l/a4c791/32.png) [@lava](https://forum.kirupa.com/u/lava)\
**Post date:** [February 27, 2003, 7:04am UTC](https://forum.kirupa.com/t/ip-address/14519/1 "2003-02-27T07:04:07Z")

</div>

I just added an option to send a text message to my cellphone on my site… I wanted to know if there’s a way to get a users IP address using ActionScript, so that I can get it in case someone decides to stalk me…  
Raf

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 27, 2003, 7:42am UTC](https://forum.kirupa.com/t/ip-address/14519/2 "2003-02-27T07:42:16Z")

</div>

Not in AS, but through PHP you can. How to go about that with your form I have no clue.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 27, 2003, 7:42am UTC](https://forum.kirupa.com/t/ip-address/14519/3 "2003-02-27T07:42:48Z")

</div>

i don’t think that is possible with **as** …

but you can use php [size=1]assuming that your server supports php :P[/size]

a quick example would be something like …

```php

<?
echo "&ip=$REMOTE_ADDR&";
?>

```

then place a dynamic text field on the stage with the variable **“ip”** [no quotes] [size=1]variable … not instance name[/size]  
and add this script to the timeline

```auto

this.loadVariables("file.php");

```

=)

[size=1]**[edit]**  
hmm … lost beat me :-[/size]

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 27, 2003, 11:40am UTC](https://forum.kirupa.com/t/ip-address/14519/4 "2003-02-27T11:40:00Z")

</div>

this has been brought up before. Kax nailed the php example mentioned in that previous thread (here):  
[http://www.kirupaforum.com/showthread.php?s=&threadid=11773&highlight=ip](http://www.kirupaforum.com/showthread.php?s=&threadid=11773&highlight=ip)  
though there is also an asp version mentioned there as well

## search

IP  
address  
ipaddress  
php  
asp

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 27, 2003, 11:45am UTC](https://forum.kirupa.com/t/ip-address/14519/5 "2003-02-27T11:45:48Z")

</div>

there it was 😛

i ran a search and couldn’t find that thread :-\

it’s easier just posting the link than having to explain it here 😏

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 27, 2003, 12:09pm UTC](https://forum.kirupa.com/t/ip-address/14519/6 "2003-02-27T12:09:08Z")

</div>

or in cgi :

```php
$ip=$ENV{'REMOTE_ADDR'};

```
