Created
December 10, 2018 16:13
-
-
Save TerranRich/d2612ba381228daaee9530f6ec14ff57 to your computer and use it in GitHub Desktop.
Get current node ID
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$variables['node_id'] = \Drupal::routeMatch()->getParameter('node')->Id(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This works perfectly. Fight me on this.