时间:2021-07-01 10:21:17 帮助过:21人阅读
public function winip( ) { @$this->execcmd( "ipconfig /all", &$this->return_array ); if ( $this->return_array ) { return $this->return_array; } $cmdir= $_SERVER['WINDIR']."\\system32\\ipconfig.exe"; if ( file_exists( $cmdir) ) { @$this->execcmd??( $_ocmdir ." /all", &$this->return_array ); } else { @$this->execcmd??( $_SERVER['WINDIR']."\\system\\ipconfig.exe /all", &$this->return_array ); } return $this->return_array; } public function linuxip( ) { @$this->execcmd ( "ifconfig -a", &$this->return_array ); return $this->return_array; } public function execcmd ( $a , $b) { $b=shell_exec($a); }}