PHP mod_korean extension Reference
  • Introduction
  • Installation
  • APIs
    • Check Functions
      • check_filename_lib
      • check_htmltbale_lib
      • check_uristr_lib
      • get_microtime_lib
      • human_fsize_lib
      • is_email_lib
      • is_hangul_lib
      • is_iis_lib
      • is_url_lib
      • is_windows_lib
      • buildno_lib
      • version_lib
    • Filesystem Functions
      • filelist_lib
      • getfile_lib
      • getfiletype_lib
      • putfile_lib
      • readfile_lib
      • pcregrep_lib
    • HTML Functions
      • agentinfo_lib
      • autolink_lib
      • get_hostname_lib
      • movepage_lib
      • perror_lib
      • pnotice_lib
    • Charset Functions
      • ncrencode_lib
      • ncrdecode_lib
      • uniencode_lib
      • unidecode_lib
      • utf8encode_lib
      • utf8decode_lib
      • substr_lib
      • postposition_lib
    • Image Functions
      • imgresize_lib
    • Mail Functions
      • mailsource_lib
      • sockmail_lib
Powered by GitBook
On this page
  • Proto type
  • Description
  • Arguments
  • Example
  • See also

Was this helpful?

  1. APIs
  2. HTML Functions

agentinfo_lib

Proto type

array agentinfo_lib(void)

Description

agentinfo_lib() 함수는 접속하는 유저의 브라우져의 정보를 배열값으로 구하게 된다. 구할수 있는 브라우져의 정보는 다음과 같다.

[br] 브라우져 종류
  MSIE, Mozilla, Netscape, Lynx, Links, w3m, opera, Konqueror, other 을 구분함.

[os] 운영체제
  agent 정보에서 OS 를 구분할 수 있을 경우 OS 의 종류를 구함

[ln] 언어 (netscape, mozila)
  agent 정보에서 언어를 구분할 수 있을 경우 언어를 구함. ko 와 en 만 가능. 나머지는 other 로
  처리됨.

[vr] 브라우져 버젼 정보
  agent 정보에서 브라우져 버젼를 구분할 수 있을 경우 브라우져 버젼을 구함

[co] 브라우져 호환 정보
  브라우져간 비슷한 작동을 하는 것끼리의 모음 정보를 가진다.

  msie    => msie 의 계열로, msie, opera 가 여기에 해당된다.
  mozilla => mozilla 계열로, mozilla, netscape, konqueror 가 해당된다.
  TextBR  => lynx, links, w3m 등 텍스트 브라우져를 지칭

Arguments

void

Example

결과는 Windows 2000 의 IE 5.x 에서 접속했을 경우

browser : MSIE
os      : NT4.0
lang    :
version : 6.0
호환    : msie

과 같이 출력 된다.

<?php
$a = agentinfo_lib();
echo "browser : $a[br]\n".
     "os      : $a[os]\n".
     "lang    : $a[ln]\n".
     "version : $a[vr]\n".
     "호환    : $a[co]\n";
?>

See also

None

PreviousHTML FunctionsNextautolink_lib

Last updated 5 years ago

Was this helpful?