sed -i '' 's/utf8mb4_0900_ai_ci/utf8mb4_unicode_ci/g' db.sql
sudo files_chown /mnt/files/public/
sudo files_chmod /mnt/files/public/
drush pm-uninstall `drush pm-list --pipe --no-core --status=disabled`
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
{# Rendering node links field #} | |
{{ content.links }} | |
{# Rendering comments #} | |
{{ content.comment }} | |
{# Rendering any field <FIELDNAME> #} | |
{{ content.field_FIELDNAME }} | |
{# Rendering node title #} |
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
function THEMENAME_form_alter(&$form, &$form_state, $form_id) { | |
// Fix order total translation | |
if (isset($form['cart_contents'])){ | |
$form['cart_contents']['cart_contents_view']['#markup'] = str_replace('Order total', t('Order total'), $form['cart_contents']['cart_contents_view']['#markup']); | |
} | |
// Fix translation on checkout form | |
if ($form['#id'] == 'commerce-checkout-form-checkout'){ | |
if(isset($form['customer_profile_billing'])){ | |
$form['customer_profile_billing']['#title'] = t('Billing information'); | |
} |
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
<?php | |
/** | |
* Implements hook_preprocess_HOOK() for HTML document templates. | |
*/ | |
function THEMENAME_preprocess_html(&$variables) { | |
foreach ($variables['page']['#attached']['html_head'] as $key => $value) { | |
if ($value[1] === 'viewport') { | |
$value[0]['#attributes']['content'] = 'width=device-width,minimum-scale=1,initial-scale=1'; | |
$variables['page']['#attached']['html_head'][$key] = $value; |
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
{% if node.field_hero_image.entity %} | |
<img src="{{ file_url(node.field_hero_image.entity.uri.value) }}" | |
alt="{{ node.field_hero_image.alt }}" | |
{% if node.field_hero_image.title %} | |
title="{{ node.field_hero_image.title }}" | |
{% endif %} | |
/> | |
{% endif %} |
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
/** | |
* Implements hook_form_alter(); | |
*/ | |
function YOURTHEME_form_alter(&$form, &$form_state, $form_id) { | |
// Fix order total translation | |
if (isset($form['cart_contents'])){ | |
$form['cart_contents']['cart_contents_view']['#markup'] = str_replace('Order total', t('Order total'), $form['cart_contents']['cart_contents_view']['#markup']); | |
} | |
// Fix translation on checkout form | |
if ($form['#id'] == 'commerce-checkout-form-checkout'){ |
NewerOlder