Although it does not indicate receiving parameters this function allows some chars as parameters, they are the options a; m; n; r; s; v.



I don't know exactly what each one does, but below is a code example and its output on PHP 5.5 running on RedHat 4.4



<?php

echo '<pre>' ;

echo '(void): ' . php_uname (). "

" ; echo 'a: ' . php_uname ( 'a' ). "

" ; echo 'm: ' . php_uname ( 'm' ). "

" ; echo 'n: ' . php_uname ( 'n' ). "

" ; echo 'r: ' . php_uname ( 'r' ). "

" ; echo 's: ' . php_uname ( 's' ). "

" ; echo 'v: ' . php_uname ( 'v' ). "

" ; echo '</pre>' ;

phpinfo ();

?>



Note that I used file_get_contentes with a file, that file is present in most linux boxies and varies on content, but most of times it indicates kernel version, linux version, distribution and so on. In my case my user didn't have access to the file, so to identify that it was a red hat I paid attention to php_info outputs, there in the middle was the postgress driver description, p. eg indicating the distribution.



I guess there is no easy way to find out the server version programmatically a 100% of times, but by and large you can get around by yourself.