mirror of
https://github.com/billz/raspap-webgui.git
synced 2023-10-10 13:37:24 +02:00
Added get_public_ip()
This commit is contained in:
parent
225bff59b6
commit
84fcedc203
@ -778,3 +778,13 @@ class validation
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Resolves public IP address
|
||||||
|
*
|
||||||
|
* @return string $public_ip
|
||||||
|
*/
|
||||||
|
function get_public_ip()
|
||||||
|
{
|
||||||
|
exec('wget https://ipinfo.io/ip -qO -', $public_ip);
|
||||||
|
return $public_ip[0];
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user