<-
Apache > HTTP Server > Documentation > Version 2.2 > ¸ðµâ

Please note

This document refers to a legacy release (2.2) of Apache httpd. The active release (2.4) is documented here. If you have not already upgraded, please follow this link for more information.

You may follow this link to go to the current version of this document.

¾ÆÆÄÄ¡ ¸ðµâ mod_version

°¡´ÉÇÑ ¾ð¾î:  en  |  ja  |  ko 

ÀÌ ¹®¼­´Â ÃÖ½ÅÆÇ ¹ø¿ªÀÌ ¾Æ´Õ´Ï´Ù. ÃÖ±Ù¿¡ º¯°æµÈ ³»¿ëÀº ¿µ¾î ¹®¼­¸¦ Âü°íÇϼ¼¿ä.
¼³¸í:¹öÀüº° ¼³Á¤
»óÅÂ:Extension
¸ðµâ¸í:version_module
¼Ò½ºÆÄÀÏ:mod_version.c
Áö¿ø:¾ÆÆÄÄ¡ 2.1 ÀÌÈĺÎÅÍ

¿ä¾à

¿©·¯ ´Ù¸¥ À¥¼­¹ö ¹öÀü°ú ±¸¼ºÀ» ´Ù·ç¾î¾ß ÇÒ Å« ³×Æ®¿÷°ú Å×½ºÆ®¿ëÀ¸·Î »ç¿ëÇϱâÀ§ÇØ ÀÌ ¸ðµâÀ» ¸¸µé¾ú´Ù. ÀÌ ¸ðµâÀº ¼ýÀÚ ºñ±³³ª Á¤±ÔÇ¥Çö½ÄÀ» »ç¿ëÇÏ¿© ÀÚÀ¯·Î¿î ¹öÀü °Ë»ç°¡ °¡´ÉÇÑ <IfVersion>À» Á¦°øÇÑ´Ù.

¿¹Á¦

<IfVersion 2.1.0>
# ÇöÀç À¥¼­¹ö ¹öÀüÀº Á¤È®È÷ 2.1.0ÀÌ´Ù
</IfVersion>

<IfVersion >= 2.2>
# ÁøÂ¥ »õ·Î¿î ±â´ÉÀ» »ç¿ëÇÑ´Ù :-)
</IfVersion>

´Ù¸¥ »ç¿ë¹ýÀº ¾Æ·¡¸¦ Âü°íÇÑ´Ù.

Áö½Ã¾îµé

top

<IfVersion> Áö½Ã¾î

¼³¸í:¹öÀüº° ¼³Á¤À» ¹­´Â´Ù
¹®¹ý:<IfVersion [[!]operator] version> ... </IfVersion>
»ç¿ëÀå¼Ò:ÁÖ¼­¹ö¼³Á¤, °¡»óÈ£½ºÆ®, directory, .htaccess
Override ¿É¼Ç:All
»óÅÂ:Extension
¸ðµâ:mod_version

<IfVersion> ¼½¼ÇÀº À¥¼­¹ö ¹öÀüÀÌ ¿øÇÏ´Â Á¶°ÇÀ» ¸¸Á·ÇÒ¶§¸¸ ½ÇÇàÇÒ ¼³Á¤ Áö½Ã¾î¸¦ ¹­´Â´Ù. ÀϹÝÀûÀÎ (¼ýÀÚ) ºñ±³ÀÇ °æ¿ì version ¾Æ±Ô¸ÕÆ®´Â 2.1.0À̳ª 2.2¿Í °°ÀÌ major[.minor[.patch]] Çü½ÄÀÌ´Ù. minor¿Í patch´Â ¾ø¾îµµ µÈ´Ù. ÀÌµé ¼ýÀÚ°¡ ¾ø´Ù¸é 0À̶ó°í °¡Á¤ÇÑ´Ù. ´ÙÀ½°ú °°Àº ¼ýÀÚ operator°¡ °¡´ÉÇÏ´Ù.

operator¼³¸í
= ȤÀº == µ¿ÀÏÇÑ À¥¼­¹ö ¹öÀü
> º¸´Ù Å« À¥¼­¹ö ¹öÀü
>= Å©°Å³ª °°Àº À¥¼­¹ö ¹öÀü
< º¸´Ù ÀÛÀº À¥¼­¹ö ¹öÀü
<= À۰ųª °°Àº À¥¼­¹ö ¹öÀü

¿¹Á¦

<IfVersion >= 2.1>
# ¹öÀüÀÌ 2.1.0 º¸´Ù Å©°Å³ª °°À»¶§¸¸
# ½ÇÇàÇÑ´Ù.
</IfVersion>

¼ýÀÚ ºñ±³¿Ü¿¡µµ Á¤±ÔÇ¥Çö½ÄÀ» »ç¿ëÇÏ¿© À¥¼­¹ö ¹öÀüÀ» ÁöÁ¤ÇÒ ¼ö ÀÖ´Ù. ¿©±â¿¡´Â µÎ°¡Áö ¹æ¹ýÀÌ ÀÖ´Ù.

operator¼³¸í
= ȤÀº == versionÀº /regex/ Çü½ÄÀÌ´Ù
~ versionÀº regex Çü½ÄÀÌ´Ù

¿¹Á¦

<IfVersion = /^2.1.[01234]$/>
# ¿¹¸¦ µé¾î, ¿©±â¿¡ ¹ö±×°¡ Àִ ƯÁ¤ ¹öÀü¿¡ ´ëÇÑ ÇØ°áÃ¥ÀÌ ³ª¿Â´Ù </IfVersion>

¿¬»êÀÚ ¾Õ¿¡ ´À³¦Ç¥(!)¸¦ ¾²¸é Àǹ̸¦ ¹Ý´ë·Î Çؼ®ÇÑ´Ù.

<IfVersion !~ ^2.1.[01234]$>
# ÀÌ ¹öÀüÀÌ ¾Æ´Ï¸é
</IfVersion>

operator¸¦ »ý·«Çϸé =À̶ó°í »ý°¢ÇÑ´Ù.

°¡´ÉÇÑ ¾ð¾î:  en  |  ja  |  ko 

top

Comments

Notice:
This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Freenode, or sent to our mailing lists.