Get country code

Aquí podrás hablar de cualquier tema que no tenga un sección específica.
Hello to all

How can I get the country like the following code?

Código: Seleccionar todo

function GetPublicIP(webip)
local webip = webip or 'http://my.ipaddress.is/';
local ret;
local ip;
local pip = "";

ret =HTTP.Submit(webip,{},SUBMITWEB_GET, 20, 80, nil, nil);
        if ret ~= "" then
                ip=ret:match("%d+%.%d+%.%d+%.%d+");
                if ip ~= nil and ret ~= ip then
                         pip = ip;
                end
        else
                pip = "";
        end
return pip;
end
on show

Código: Seleccionar todo

local ip=GetPublicIP(webip);

Input.SetText("Input1", ip);
Please help, my work is tied to this code



something like that?



MEGA.NZ
HIDE: ON
Hidebb Message Hidden Description



Gracias
Thank you, but I don't have the source and it didn't show Afghanistan, but it showed the IP correctly

ایپی رو درست نمایش داد ولی کشور نمایش نمیده چطوری محافظت کردی از فایل میشه به من هم یاد بدی هم وطن ؟
gracias
MORTEZA420 escribió:
12 Jun 2020 09:42
Thank you, but I don't have the source and it didn't show Afghanistan, but it showed the IP correctly



Imagen


well
csv file update June 10, 2020


MEGA.NZ
HIDE: ON
Hidebb Message Hidden Description



testa colega
usamakey escribió:
12 Jun 2020 14:59
MORTEZA420 escribió:
12 Jun 2020 09:42
Thank you, but I don't have the source and it didn't show Afghanistan, but it showed the IP correctly



Imagen


well
csv file update June 10, 2020


MEGA.NZ
HIDE: ON
Hidebb Message Hidden Description




I need a source You have protected the file What should I do?
project file
will be canceled tomorrow at 18.00


MEGA.NZ
HIDE: ON
Hidebb Message Hidden Description
usamakey escribió:
13 Jun 2020 17:53
project file
will be canceled tomorrow at 18.00


MEGA.NZ
HIDE: ON
Hidebb Message Hidden Description
Wow, the card is very good thanks
Thank you