Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Results 1 to 5 of 5

Thread: Show ISP?

  1. #1
    Join Date
    Mar 2007
    Posts
    184
    Tokens
    0

    Default Show ISP?

    How can you show the viewers ISP in php?

    Thanks.
    Edited by Catzsy Forum Super Moderator: Your signature has been removed because
    It is against the rules to insult/bully other members by targetting them with personal remarks about them in your signature.

  2. #2
    Join Date
    Jun 2008
    Location
    Scotland
    Posts
    24
    Tokens
    0

    Default

    Do you mean something like this? Or do you mean like actually show the name e.g: Virgin Media ?

    <?php

    $ip = $_SERVER['REMOTE_ADDR'];
    $isp = @getHostByAddr( $ip );

    print $isp

    ?>

    ?

    I will try again to post, everytime I try a message comes up for like 1 second then disappears.. :S.

    Do you want something like this or, the actual ISP's name like Virgin Media?

    PHP Code:
    <?php

    $ip 
    $_SERVER['REMOTE_ADDR'];
    $isp = @getHostByAddr$ip );

      print 
    $isp
      
    ?>
    That prints out some address that has the ISP in it..?

    I think I can post now lol.

    Anyway is it like this you want? Or the actual ISP name?

    PHP Code:
    <?php

    $ip 
    $_SERVER['REMOTE_ADDR'];
    $isp = @getHostByAddr$ip );

      print 
    $isp
      
    ?>
    This is about the 5th time I've tried to post this :\ keep getting a error message about a MOD needs to approve it.

    Edited By DaveTaylor// (Forum Moderator) Posts approved and merged.
    Last edited by DaveTaylor; 03-07-2008 at 03:44 PM.

  3. #3
    Join Date
    Apr 2005
    Posts
    4,614
    Tokens
    90

    Latest Awards:

    Default

    PHP Code:
    <?php
    $ip 
    "" $_SERVER['REMOTE_ADDR'] . "";
    $isptc gethostbyaddr($_SERVER['REMOTE_ADDR']);
    $ispoh preg_split("/./"$isptc);
    $xy count($ispoh);
    $x $xy 1;
    $y $xy 2;
    $i $xy 3;
    $ispp "" $ispoh[$i] . ".";
    $isp "" $ispoh[$y] . "." $ispoh[$x] . "";
    echo
    "<b>ip: $ip</b><br>";
    echo
    "<b>isp: $ispp$isp</b>";
    ?>
    try that

  4. #4
    Join Date
    Aug 2005
    Location
    Tunbridge Wells, Kent
    Posts
    5,063
    Tokens
    1,624

    Latest Awards:

    Default

    Quote Originally Posted by Robbie! View Post
    PHP Code:
    <?php
    $ip 
    "" $_SERVER['REMOTE_ADDR'] . "";
    $isptc gethostbyaddr($_SERVER['REMOTE_ADDR']);
    $ispoh preg_split("/./"$isptc);
    $xy count($ispoh);
    $x $xy 1;
    $y $xy 2;
    $i $xy 3;
    $ispp "" $ispoh[$i] . ".";
    $isp "" $ispoh[$y] . "." $ispoh[$x] . "";
    echo
    "<b>ip: $ip</b><br>";
    echo
    "<b>isp: $ispp$isp</b>";
    ?>
    try that
    Your one just posts this:

    ip: XX.XX.XX.XX
    isp: ..

    ISP just has .. in it because my ISP Host name is Bethere.co.uk
    Never argue with an idiot, he'll drag you down to his level, and beat you with experience.

    Quote Originally Posted by Recursion
    *oh trust me
    *I would NEVER go ATi
    And 15 mins later...
    Sapphire ATI Radeon HD 5850 1024MB GDDR5 PCI-Express Graphics Card £195.73 1 £195.73
    *ordered.

  5. #5
    Join Date
    Dec 2007
    Posts
    1,683
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Flisker View Post
    Your one just posts this:

    ip: XX.XX.XX.XX
    isp: ..

    ISP just has .. in it because my ISP Host name is Bethere.co.uk
    Be There FTW, well o2.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •