FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour www.fivetechsoft.com/getip.php
Posts: 1467
Joined: Mon Oct 10, 2005 11:26 AM
www.fivetechsoft.com/getip.php
Posted: Sat Sep 20, 2025 08:44 AM

Hello,

This link used to return the IP4-adres of my internetconnection.

Now, it returns nothing anymore.

What's wrong,

Thanks.

Regards,

Michel D.
Genk (Belgium)


_____________________________________________________________________________________________

I use : FiveWin for (x)Harbour v. 25.12 - Harbour 3.2.0 (May 2025) - xHarbour Builder (January 2020) - Bcc773

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: www.fivetechsoft.com/getip.php
Posted: Sat Sep 20, 2025 10:17 AM
Dear Michel,

I am afraid it is no longer available as we had to implement cloudflare to avoid attacks

I am sorry :cry:
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1467
Joined: Mon Oct 10, 2005 11:26 AM
Re: www.fivetechsoft.com/getip.php
Posted: Sat Sep 20, 2025 11:35 AM

Hello Antonio,

I understand.No problem.

Regards,

Michel D.
Genk (Belgium)


_____________________________________________________________________________________________

I use : FiveWin for (x)Harbour v. 25.12 - Harbour 3.2.0 (May 2025) - xHarbour Builder (January 2020) - Bcc773

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: www.fivetechsoft.com/getip.php
Posted: Mon Sep 22, 2025 07:19 PM
Dear Michel,

Using GitHub Spark I have built this app :)
https://ip-address-viewer--fivetechsoft.github.app/

You may do:
MsgInfo( WebPageContents( "https://ip-address-viewer--fivetechsoft.github.app/api/ip" ) )
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1467
Joined: Mon Oct 10, 2005 11:26 AM
Re: www.fivetechsoft.com/getip.php
Posted: Mon Sep 22, 2025 07:24 PM

Thank you very much, Antonio.

You are the best.

Regards,

Michel D.
Genk (Belgium)


_____________________________________________________________________________________________

I use : FiveWin for (x)Harbour v. 25.12 - Harbour 3.2.0 (May 2025) - xHarbour Builder (January 2020) - Bcc773

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: www.fivetechsoft.com/getip.php
Posted: Fri Oct 31, 2025 02:40 PM
FUNCTION IpPublico()

 LOCAL cIpPublico := 'NIL'
 LOCAL oIp

 cIpPublico := "..."

 #ifndef __PLATFORM__LINUX
    TRY
       oIp := WIN_OLECREATEOBJECT("MSXML2.XMLHTTP")

       IF HB_ISOBJECT(oIp)
          oIp:OPEN("GET","https://api.ipify.org/",.F.)
          oIp:SEND()
          cIpPublico := LEFT(ALLTRIM(oIp:responseText),16)
       ENDIF
    CATCH
    END
 #endif
RETURN (cIpPublico)
regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion