Skip to content

BankID and CURL ERROR 77 or CURL ERROR 60

I’ve spent a few hours trying to get cURL (in PHP) to work with the Swedish BankID service, and running into the following two certificate errors: The code I’m using to initialize cURL is the following: I’ve tried various variations of the CURLOPT_CAINFO and CURLOPT_CAPATH options, but I sti…

Trouble with || operator

I have a page (titled PPC) and a custom post type (titled Presentations) that I don’t want certain elements to appear on. I thought this code would work : Using each conditional by itself, without the ||, works fine. But when I combine them both and use the logical operator, nothing works. I’ve al…

run php file with script tag

Is there any way to insert php code through <script>? Like `<script src=”example.php”>. I know that script is only for JS but I want PHP to generate JS that I can insert with script tag. Here I found a possible sollution: Generate JavaScript file with PHP when requested in HTML. PHP fi…