/[LeafOK_CVS]/fenglin/lib/client_addr.inc.php
ViewVC logotype

Diff of /fenglin/lib/client_addr.inc.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.12 by sysadm, Wed Apr 23 05:13:57 2025 UTC Revision 1.13 by sysadm, Tue Apr 29 11:55:32 2025 UTC
# Line 1  Line 1 
1  <?php  <?php
2          require_once "../lib/ip_mask.inc.php";          require_once "../lib/ip_mask.inc.php";
 ?>  
 <?php  
 function client_addr(int $mask_level = 0) : string  
 {  
         $ip = (isset($_SERVER["REMOTE_ADDR"]) ? $_SERVER["REMOTE_ADDR"] : "");  
3    
4          return ip_mask($ip, $mask_level, "%");          function client_addr(int $mask_level = 0) : string
5  }          {
6  ?>                  $ip = (isset($_SERVER["REMOTE_ADDR"]) ? $_SERVER["REMOTE_ADDR"] : "");
7    
8                    return ip_mask($ip, $mask_level, "%");
9            }


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1