This file contains hidden or 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 | |
/** | |
* @file | |
* Default simple view template to display a list of rows. | |
* | |
* @ingroup views_templates | |
*/ | |
?> | |
<?php if (!empty($title)): ?> |
This file contains hidden or 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 | |
// Varnish | |
$conf['cache_backends'][] = 'sites/all/modules/contrib/varnish/varnish.cache.inc'; | |
$conf['cache_class_cache_page'] = 'VarnishCache'; | |
// Drupal 7 does not cache pages when we invoke hooks during bootstrap. This needs | |
// to be disabled. | |
$conf['page_cache_invoke_hooks'] = FALSE; | |
$conf['reverse_proxy'] = TRUE; |
This file contains hidden or 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 | |
// Define module download destination. | |
$site_path = drush_site_path(); | |
$site_path_parts = explode('/', $site_path); | |
$clean_site_path_parts = array_slice($site_path_parts, -2, 2); | |
$clean_site_path = implode('/', $clean_site_path_parts); | |
if (!empty($clean_site_path)) { | |
$command_specific['dl']['destination'] = $clean_site_path . '/modules/contrib'; | |
} |
This file contains hidden or 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
.embedded-video .player { | |
position: relative; | |
padding-bottom: 56.25%; | |
height: 0; | |
overflow: hidden; | |
max-width: 100%; | |
} | |
.embedded-video .player iframe, | |
.embedded-video .player object, |
This file contains hidden or 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 | |
function _load_header_image($variables) { | |
if ($node = $variables['node']) { | |
// Load main_image | |
$file = $node->field_main_image->entity; | |
if ($file) { | |
$variables = array( | |
'responsive_image_style_id' => 'header_image', | |
'uri' => $file->getFileUri(), |
This file contains hidden or 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
#!/bin/bash | |
drush sql-dump --gzip --result-file=backup-xxxx.sql.gz --structure-tables-list=cache,cache_*,cache_filter,cache_form,cache_menu,cache_page,history,sessions,watchdog |
This file contains hidden or 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
#!/bin/bash | |
## Aegir has major problems while migrating sites, when the new platform doesn't have the vendor libraries available. | |
## Here is a workaround for solving that problem. | |
## Copy the working site into the new platform. | |
## That needs to be done, to let composer_manager know about all the site package requirements | |
cp -r /var/aegir/platforms/old_platform/sites/site.name.org /var/aegir/platforms/new_platform/sites/site.name.org.migration | |
cd /var/aegir/platforms/new_platform | |
## Initialize composer_manager if not already done |
This file contains hidden or 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
diff --git a/includes/commerce_product.inline_entity_form.inc b/includes/commerce_product.inline_entity_form.inc | |
index 5dcb6f2..62da0b6 100644 | |
--- a/includes/commerce_product.inline_entity_form.inc | |
+++ b/includes/commerce_product.inline_entity_form.inc | |
@@ -160,7 +160,7 @@ class CommerceProductInlineEntityFormController extends EntityInlineEntityFormCo | |
); | |
$entity_form['product_details'] = array( | |
'#type' => 'fieldset', | |
- '#title' => t('Details'), | |
+ '#title' => $this->getSetting('multi_edit') ? $product->title . ' (' . $product->sku . ')' : t('Details'), |
This file contains hidden or 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
drush @live.example.org sql-dump --gzip|zcat|drush sql-cli |
This file contains hidden or 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
/** | |
* Grunt file for Drupal theming, including clever drush cache clearing. | |
* | |
* Usage in docker4drupal environment: `grunt --docker` | |
* It ensures, that drush is executed from the php container. | |
*/ | |
module.exports = function (grunt) { | |
var drush_path = 'drush'; |