Skip to content

Instantly share code, notes, and snippets.

View MahmoudSayed96's full-sized avatar
🏠
Working from home

Mahmoud Sayed Hassan MahmoudSayed96

🏠
Working from home
View GitHub Profile
@raphaellarrinaga
raphaellarrinaga / drupal_8_php_cheat.md
Last active September 4, 2022 21:49
[Drupal 8 php/config cheatsheet] #tags: drupal8, php, config, cheatsheet

Drupal 8 PHP cheatsheet

Get current node id

$node = \Drupal::routeMatch()->getParameter('node');
if ($node instanceof \Drupal\node\NodeInterface) {
  $nid = $node->id();
}
@nhatnx
nhatnx / curl-error-60-ssl-certificate-unable-to-get-local-issuer-certificate.md
Last active July 20, 2024 15:49
[WAMP] cURL error 60: SSL certificate: unable to get local issuer certificate

Need to do this in both php.ini files !!!

Attention Wamp/Wordpress/windows users. I had this issue for hours and not even the correct answer was doing it for me, because I was editing the wrong php.ini file because the question was answered to XAMPP and not for WAMP users, even though the question was for WAMP.

here's what I did

Download the certificate bundle.

Put it inside of C:\wamp64\bin\php\your php version\extras\ssl

<?php
namespace App\Console\Commands;
use Illuminate\Support\Composer;
use Illuminate\Filesystem\Filesystem;
use Illuminate\Console\GeneratorCommand;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\InputArgument;