I'm including svg files in my site using file_get_contents(). Normally this works fine on http, but I setup this site to use https locally. When I do I get this error:
Warning: file_get_contents(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed on line 226
Warning: file_get_contents(): Failed to enable crypto on line 226
From what I can tell, it's because the cert is self signed. I found a local solution of disabling the SSL check on file get contents. I found something similar using cURL. However this seems to be a security hole. Is there a way to make this work without disabling SSL checks in file_get_contents or cURL?