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
company-project-repo: | |
- wordpressproject1 | |
- docker-compose.yml | |
- settings.php | |
- drupalproject1 | |
- docker-compose.yml | |
- sites | |
- multisite1/ | |
- settings.local.php | |
- multisite2/ |
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
company-project-repo: | |
- wordpressproject1 | |
- docker-compose.yml | |
- drupalproject1 | |
- docker-compose.yml | |
- drupalproject2 | |
- docker-compose.yml | |
- README.md |
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
company-project-repo: | |
- wordpressproject1 | |
- drupalproject1 | |
- drupalproject2 | |
- README.md |
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
/** | |
* Recursive isset for array or object properties. | |
*/ | |
function recursiveIsset($variable, $checkArray, $i = 0) { | |
$new_var = null; | |
if (is_array($variable) && array_key_exists($checkArray[$i], $variable)) { | |
$new_var = $variable[$checkArray[$i]]; | |
} else if (is_object($variable) && array_key_exists($checkArray[$i], $variable)) { | |
$new_var = $variable->$checkArray[$i]; |
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
jQuery("#edit-instance-widget-settings-available-countries").val(["BE", "MT", "BG"]); |
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 uli to en homepage | |
drush_uli() { | |
drush $1 uli | xargs -I % echo %?destination=/en | |
} | |
alias druli=drush_uli |
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
function custom_menu() { | |
$items = array(); | |
$items['ajax/custom_module/custom_action/%/%'] = array( | |
'title' => 'Title', | |
'delivery callback' => 'ajax_deliver', // important here! | |
'page callback' => 'custom_module__pagecallback', | |
'page arguments' => array(3,4), // index starts with zero | |
'type' => MENU_CALLBACK, |
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
/** | |
* Implements hook_menu(). | |
*/ | |
function HOOK_menu() { | |
$items['forum/topics/%taxonomy_term/%taxonomy_term'] = array( | |
'page callback' => '_HOOK_PAGE_CALLBACK_page', | |
'access arguments' => array('access content'), | |
); | |
// Generate your url where needed like so. |
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
/** | |
* Removes unused HOOK fields | |
*/ | |
function HOOK_update_7000() { | |
$fields_remove = array( | |
'FIELD_NAME', | |
); | |
foreach ($fields_remove as $field_name) { | |
field_delete_field($field_name); | |
} |
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
.bootstrapgrid { | |
text-align: center; | |
} | |
.bootstrapgrid:before { | |
content: ''; | |
display: inline-block; | |
height: 100%; | |
vertical-align: middle; | |
margin-right: -15px; /* Adjusts for spacing */ |
NewerOlder