Skip to content

Instantly share code, notes, and snippets.

@dawidnawrot
Created August 10, 2018 12:23
Show Gist options
  • Save dawidnawrot/1b6d0d6b9c77035429c0ce874a0f2e7f to your computer and use it in GitHub Desktop.
Save dawidnawrot/1b6d0d6b9c77035429c0ce874a0f2e7f to your computer and use it in GitHub Desktop.
<?php
function template_preprocess_page(&$variables) {
$google_simple_api_access_key = variable_get('google_simple_api_access_key');
drupal_add_js(array(
'google_simple_api_access' => array(
'key' => $google_simple_api_access_key,
),
),
'setting'
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment