Deleted articles cannot be recovered. Draft of this article would be also deleted. Are you sure you want to delete this article?
åæ¸ã PHP ã®å®è¡ç°å¢ãæ§ç¯ããå ´åãã°ã°ãã¨å¤§ä½ nginx 㨠PHP-FPM ãè¨å®ã PHP ã®å®è¡ç°å¢ãæ§ç¯ããè¨äºã沢山åºã¦ãã¾ããã¤ã³ãã©ã®ç¥èããªãé ãã³ããã§ã¨ãããã PHP ã®å®è¡ç°å¢ãæ§ç¯ã§ãããããã¨ããããåãããã©ããåãããªããã¨ããç¶æ ã§ããã ãPHP-FPM ã£ã¦ä½ï¼ã ãApache ã®å ´åã¤ã³ã¹ãã¼ã«ããã ã㧠PHP ã®å®è¡ç°å¢æ§ç¯ã§ããããï¼ã ãnginx 㨠PHP-FPM ã®éä¿¡ã¯ã©ããªã£ã¦ãã®ï¼ã ...etc èªåã¨åããããªæ¹ã ããããããããªãã®ã§ããã®é 調ã¹ã¦ã¾ã¨ãã¦ãããå 容ãä¸è¨ã«è¨ãã¾ãã ä»åæ§ç¯ãã¦ãã OS ã®ç°å¢ PHP-FPM ã£ã¦ä½ï¼ Answer PHP: FastCGI Process Manager (FPM) - Manual FPM ( FastCGI Process Manager ) 㯠PH
PHPã¯ãWebãµã¤ãæ§ç¯ã«ç¹åãã¦éçºãããããã°ã©ãã³ã°è¨èªã§ãã大ããªç¹å¾´ã®ã²ã¨ã¤ã¯ãHTMLã«ç´æ¥ããã°ã©ã ãåãè¾¼ããã¨ãã§ããã¨ããç¹ã§ããPHPãç¨ãããã¨ã§ãHTMLãåçã³ã³ãã³ãã¨ãã¦åºåã§ãã¾ããHTMLããã®ã¾ã¾ãã©ã¦ã¶ã«è¡¨ç¤ºãããã®ã«å¯¾ããPHPããã°ã©ã ã¯ãµã¼ãå´ã§å®è¡ãããçµæããã©ã¦ã¶ã«è¡¨ç¤ºããããããPHPã¹ã¯ãªããã¯ããµã¼ããµã¤ãã¹ã¯ãªãããã¨å¼ã°ãã¦ãã¾ãã
ã¨ã°ã¼ã¯ãã£ããµã㪠PHPMailerã«ãªã¢ã¼ãã¹ã¯ãªããå®è¡ã®èå¼±æ§CVE-2016-10033ãå ¬è¡¨ããããæ»æãæåããå ´åãã¦ã§ãã·ã§ã«ãè¨ç½®ãããã¦ã§ããµã¼ãã¼ãä¹ã£åãããçé常ã«å±éºã§ããããæ»ææåã«ã¯ä¸è¨ã®æ¡ä»¶ãå¿ è¦ã§ãããã¨ãããã£ã PHPMailer 5.2.17以åã使ã£ã¦ãã Senderããããã£ï¼ã¨ã³ããã¼ãFromï¼ãå¤é¨ããè¨å®ã§ãã ç¾å¨åºåã£ã¦ããPoCã¯MTAã¨ãã¦sendmailãæ³å®ãã¦ãããpostfixã使ã£ã¦ããç°å¢ã§ã¯åé¡ãªã 対ççã¨ãã¦å ¬éããã¦ãã PHPMailer 5.2.19ãä¸å®å ¨ã§ããã®ã§ãåé¿çã®å°å ¥ãæ¨å¥¨ããã ã¯ããã« 12æ24æ¥ã«PHPMalerã®èå¼±æ§CVE-2016-10033ãå ¬è¡¨ãããã¨ãã ã¯ãªã¹ãã¹ãã¬ã¼ã³ãã ã¨è©±é¡ã«ãªã£ã¦ãã¾ãã PHPããã®ã¡ã¼ã«éä¿¡ã«åºã使ããã¦ããã©ã¤ãã©ãªã®ãPHPMai
ã¾ãã©ãã»ã«ã¤ã¨ã§ã¨ã³ã¸ãã¢ãã£ã¦ãã @M_Ishikawa ãã¨ç³å·ã¨ç³ãã¾ãã好ããªè¨èã¯ã¡ãã大æç¥ã§ãã ãã®è¨äºã¯ ã»ã«ã¤ã¨ Advent Calendar 2015 8æ¥ç®ã®è¨äºã§ãã Advent Calendarã«åå ããã«ããã£ã¦ãã¿ãæãå½ãããªãã£ãã®ã§ãããæè¿ã¡ãã£ã¨å¤ãã£ãçµé¨ãããã®ãæãåºãã¾ããã ããã¨ããã®ãããã®åå¹´éã§ã Laravel Phalcon FuelPHP CakePHP Ethna ã¨æ²¢å±±ã®PHPãã¬ã¼ã ã¯ã¼ã¯ãåæ並è¡ãã¦éçºãã¦ããã®ã§ãã Ethnaé·ããã¨ãã£ã¦ãã®ã«ãã®çæéã§laravelã¨cakephpã¨falconã¨fuelphpã¨ä¸¦è¡ãã¦æ±ã£ã¦ã¦çµæ§æ··ä¹±ããã³ãã¬ã¼ãã¨ã³ã¸ã³ãsmarty, blade, twig, volt, mustacheã¨å ¨é¨ç°ãªãã®ãæ··ä¹±ãâ Masayuki Ishikawa (@M_
â ãã³ãã¬ã¼ãã®èªã¿è¾¼ã¿ã¨ãã£ã¬ã¯ããªã®ã»ããï¼PHPãã¡ã¤ã«ã«è¨è¿°ï¼ â» Smarty require_once('Smarty/Smarty.class.php'); $smarty = new Smarty(); $smarty->template_dir = './templates/'; $smarty->compile_dir = './templates_c/'; â» Twig require_once('Twig/Autoloader.php'); Twig_Autoloader::register(); $loader = new Twig_Loader_Filesystem("./templates/"); $twig = new Twig_Environment($loader, array( 'cache' => 'cache_twig', 'debug' =>
PHP: The Right Wayãèªãã§ããã®ã³ã³ã»ããã«å ±æããã®ã§ãä»åãComposerã¨Packagistã§ã©ã¤ãã©ãªãéçºããã¹ããå ¬éããæé ãã¾ã¨ãã¦ãããã¨æãã¾ãã Composerã£ã¦ Composerã¯ãPHPã®ã©ã¤ãã©ãªä¾å管çãã¼ã«ã§ããRubyã®Bundlerã®ããã«ä¾åããã©ã¤ãã©ãªãè¨å®ãã¡ã¤ã«ã«æ¸ãã¦ã³ãã³ããããã°ã©ã¤ãã©ãªã®ã¤ã³ã¹ãã¼ã«ã¨å©ç¨æºåãæ´ãã¾ãã ã¾ããComposerç¨ã®ãªãã¸ããªã ãã§ãªããPEARãGithubã®ãªãã¸ããªãComposerçµç±ã§åå¾ã§ããã®ã§ãã¨ã¦ã便å©ã§ãã åºæ¬çãªä½¿ãæ¹ ã¤ã³ã¹ãã¼ã« ããã¸ã§ã¯ãã®ã«ã¬ã³ããã£ã¬ã¯ããªã«composer.pharããã¦ã³ãã¼ããããããã ãã
MAMPã§HTMLãã¡ã¤ã«ãªã©ã§ãPHPãå®è¡ã§ããããã«è¨å®ããæ¹æ³ãã¡ã¢ãMAMPã®ãã¼ã¸ã§ã³ã¯2.1.1ã è¨å®æ¹æ³ /Applications/MAMP/conf/apache/ã«ããhttpd.confãããã¹ãã¨ãã£ã¿ãªã©ã§éãã¦ã135è¡ç®ãããã«ãã以ä¸ã®é¨åãä¿®æ£ããã AddType application/x-httpd-php .php .phtml ãã®é¨åã«PHPãå®è¡ãããããã¡ã¤ã«å½¢å¼ã®æ¡å¼µåã追å ããã AddType application/x-httpd-php .php .phtml .html ç·¨éããhttpd.confãä¿åãã¦MAMPãåèµ·åããã°ã追å ãããã¡ã¤ã«å½¢å¼ã§PHPãåãã¯ãã åèãµã¤ã web帳 | MAMPã®è¨å®æ¹æ³ MAMP: Mac, Apache, MySQL, PHP
.htmlæ¡å¼µåã®ãã¼ã¸ã«PHPãåãè¾¼ãã§ãã³ã³ãã³ãã®ä¸é¨ãåçã«ãããã¨ãã£ã¦ããã¾ãããï¼ ãããªæã以ä¸ã®ãããªã³ã¼ããã.htaccessãã¨ãããã¡ã¤ã«ãä½æãã¦ã¬ã³ã¿ã«ãµã¼ãã¼ã«ã¢ãããã¼ããããã°ã.htmlæ¡å¼µåã®ãã¼ã¸ããããããPHPã®åçãã¼ã¸ã§ãããã®ããã«åä½ããããã¨ãã§ããã¨è¨ããã¦ãã¾ãã AddType application/x-httpd-php .php .html ã§ãããããã¤ãã®ã¬ã³ã¿ã«ãµã¼ãã¼ã§ä¸è¨ã³ã¼ãã試ãã¦ã¿ãã¨ãããPHPããã¾ãåä½ããªãã±ã¼ã¹ãå¤ããã¬ã³ã¿ã«ãµã¼ãã¼ã®ä»æ§ãè¨å®å 容ã«ãã£ã¦ã.htaccessãã®è¨è¿°å 容ãå¤ããå¿ è¦ãããããã§ãã ããã§ã代表çãªã¬ã³ã¿ã«ãµã¼ãã¼ãä¾ã«ãã¬ã³ã¿ã«ãµã¼ãã¼å¥ã«ã¾ã¨ãã .htaccess ã®è¨è¿°æ¹æ³ããç´¹ä»ãããã¨æãã¾ãã ãç´¹ä»ããã¦ããã ãã¬ã³ã¿ã«ãµã¼ãã¼ãªã¹ãã¯ä»¥ä¸ã«ãª
$_SERVERå¤æ°ã«ã¤ã㦠PHPã§ã¯ããµã¼ãã«é¢ããç°å¢å¤æ°ã¯ $_SERVER ã°ãã¼ãã«å¤æ°(ã©ãããã§ãã¢ã¯ã»ã¹åºæ¥ãå¤æ°)ã«æ ¼ç´ããã¾ãã é常ã«ä¾¿å©ãªã®ã§ãããããã©ã®å¤æ°ãã©ãã ã£ãï¼ã¨å¿ãã¦ãã¾ãã®ã§ãåå¿é²å ¼ãã¦æ¸ãã¦ãããã¨ã«ãã¾ãã ä¾ã«ã¯ãå®éã«ã¢ã¯ã»ã¹ããã£ãæç¹ã®$_SERVERå¤æ°å¤ãæ²è¼ãã¦ãã¾ãã®ã§ããèªèº«ã®ã¢ã¯ã»ã¹æ å ±ãªã©ã確èªãããã¨ãã§ãã¾ãã
PHPã®==æ¼ç®åã¯è¤éãªæåããããã¨ãç¥ããã¦ãããã2012å¹´ã«ãªãªã¼ã¹ãããPHP 5.4.4ã§å¤æ´ããã==æ¼ç®åã®æåã«ã¤ãã¦ã®è©±ã話é¡ã«ãªã£ã¦ããã PHP 5.4.4ããåã¯ãã'9223372036854775807' == '79223372036854775808'ãã¨ããå¼ãtrueãè¿ãã¦ããã®ããPHP 5.4.4ã§ã¯ãããfalseãè¿ãããã«å¤æ´ããããã¨ãã話ãªã®ã ãï¼Bug #54547 wrong equality of string numbersï¼ããã®å¤æ´ã«ãããä»åº¦ã¯ã'9999999999999999999.0' == '9999999999999999999.1'ãã¨ããå¼ãtrueã«ãªã£ã¦ãã¾ããã¨ããå¥ã®åé¡ãçºçãã¦ãã¾ã£ã模æ§ã ãããªã£ã¦ãã¾ãåå ã«ã¤ãã¦ã¯å è¨äºã§èª¬æããã¦ããããPHPã«ããã¦ã==ãæ¼ç®åã¯æ°å¤æååå士ãæ¯
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ã©ã³ãã³ã°
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}