👍 🌟💩👍💃👯🙇😺👀🐰🐥💐🌸🌷🍁:squirrel:💝🎉💰🎸🎺🎷🎨🎩🍺🍹🍷🍣🍰🍪🚤🚀🏁🗿
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 | |
/** | |
* Fetches a field for an array of nids of a given type. | |
* | |
* Usage example: $nodes = mymodule_field_load_multiple('page', 'field_image', array(1, 2, 3)); | |
* | |
* @param string $content_type | |
* The node's content type machine name. | |
* @param string $field |
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
" Extra bundles. | |
Bundle 'joonty/vdebug.git' | |
" Editor overrides. | |
set shiftwidth=2 " Use indents of 4 spaces | |
set expandtab " Tabs are spaces, not tabs | |
set tabstop=2 " An indentation every four columns | |
set softtabstop=2 " Let backspace delete indent | |
" associate *.install and *.module files with with php filetype |
Drupal 7's default behavior is to redirect the user to the full display of a node after it has been saved.
If you want to stay in the edit form after saving, add this snippet to a custom module adjusting the module namespace in the two functions.
For Drupal 8 or 9, have a look at the comment below by @zanvidmar.
Patches are managed through the Drush patch command. Existing patches can be found at patches.make.
Apply patch URL to multifield module
$ cd docroot
$ drush pa multifield https://www.drupal.org/files/issues/multifield-features_integration-2102265-29.patch
Patch https://www.drupal.org/files/issues/multifield-features_integration-2102265-29.patch applied to [ok]
- Acudir a cualquier oficina de correos solicitando el impreso.
- Se reciben dos impresos y un sobre. Uno es para Correos y el otro es para el Censo Electoral. En el segundo podemos especificar a qué dirección queremos que se nos envíe la documentación para votar.
- La documentación llegará al domicilio no más tarde del 4 de mayo.
- El voto deberá enviarse no más tarde del 19 de mayo.
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
/** | |
* Skip third party resources from being requested. | |
* | |
* Usage: add this file to casper js at the --includes option. | |
* Edit the array of URLs to skip. | |
* You can find out which third party requests your pages are making | |
* by adding the option --log-level=debug to the casperjs command. | |
*/ | |
casper.on('resource.requested', function(requestData, request) { | |
// List of URLs to skip. Entering part of a hostname or path is OK. |
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
// CasperJS default settings. | |
$command_specific['casperjs'] = array( | |
'verbose' => TRUE, | |
'url' => 'http://local.mysite.com', | |
'test-root' => '../testing/tests', | |
'includes' => '../testing/users.js,../testing/common.js', | |
); |
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 drush_pm_compare($alias_a, $alias_b) { | |
$result_a = drush_invoke_process($alias_a, 'pm-list') | |
$result_b = drush_invoke_process($alias_b, 'pm-list') | |
// Compare both arrays and inform about differences | |
} |
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
SELECT TABLE_NAME, table_rows, data_length, index_length, round(((data_length + index_length) / 1024 / 1024),2) "Size in MB" | |
FROM information_schema.TABLES | |
WHERE table_schema = "mydatabase" ORDER BY round(((data_length + index_length) / 1024 / 1024),2) DESC | |
LIMIT 0,15; |