<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Snippets on Fairy Select</title><link>https://portfolio.fairy-select.com/posts/snippets/</link><description>Recent content in Snippets on Fairy Select</description><generator>Hugo -- gohugo.io</generator><language>en-US</language><lastBuildDate>Thu, 03 Dec 2020 12:57:47 +0900</lastBuildDate><atom:link href="https://portfolio.fairy-select.com/posts/snippets/index.xml" rel="self" type="application/rss+xml"/><item><title>ローカル環境の時だけ自己署名証明書のサイトへの file_get_contents を通す</title><link>https://portfolio.fairy-select.com/posts/snippets/file-get-contents-local-certificate/</link><pubDate>Thu, 03 Dec 2020 12:57:47 +0900</pubDate><guid>https://portfolio.fairy-select.com/posts/snippets/file-get-contents-local-certificate/</guid><description>&lt;p&gt;環境を指定する変数 &lt;code&gt;$environment&lt;/code&gt; を用意し、その値に応じて &lt;code&gt;file_get_contents&lt;/code&gt; に渡す引数を変えるような関数を作成しました。&lt;/p&gt;
&lt;p&gt;これにより、ローカル環境 &lt;code&gt;$environment = 'local'&lt;/code&gt; のときに証明書の検証を無視するような設定ができるかと思います。&lt;/p&gt;</description></item></channel></rss>