Y
Y
YourQuestion2015-05-09 07:57:13
PHP
YourQuestion, 2015-05-09 07:57:13

PHP how to check port(except $_SERVER['SERVER_PORT'])?

Good afternoon.
The server sends a request to ip 5.82.222.16:2054
Is it possible to check the port?
those.

<?php 
if(запрос пришел на ip 5.82.222.16 по порту 2054) ){
  echo 'hello';
}

?>
so far we only know about $_SERVER['SERVER_PORT'], but the manual considers this method of checking unsafe, if there are other methods ?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question