WackoWiki: Action: GetIP

https://wackowiki.org/doc     Version: 11 (11/11/2026 19:52)

Action: GetIP

Current version:
Credits:
{{getip}}

/action/getip.php
PHP
<?php
    // determine IP
    $tpl->ip = $ip = $this->get_user_ip();

    // resolve IP and determine host
    $tpl->host = gethostbyaddr($ip);


/action/template/getip.tpl
HTML
[ === main === ]

[ ' ip ' ]<br>
[ ' host ' ]<br>