git grep "\.t-" -- assets/src/stylesheets
git grep ".u-" -- assets/src/stylesheets
git grep "__" -- assets/src/stylesheets
| drush eval "var_dump(Drupal\Component\Utility\Crypt::randomBytesBase64(55))" |
| $query = new EntityFieldQuery(); | |
| $query->entityCondition('entity_type', 'node') | |
| ->entityCondition('bundle', 'industry_news_events') // type de contenu industry_news_events | |
| ->propertyCondition('status', NODE_PUBLISHED) // qui dois etre publiée | |
| ->fieldCondition('field_news_or_event', 'value', 'news', '=') // et on veux que les news | |
| ->propertyOrderBy('created', 'desc') // dans l'ordre des derniers création | |
| ->range(0,6); // et on veux les 6 derniers | |
| $result = $query->execute(); | |
| if($result['node']){ |
| //form | |
| $form['node'] = array( | |
| '#type' => 'textfield', | |
| '#title' => t('Tester'), | |
| '#autocomplete_path' => 'test/keyral/ajax', | |
| ); | |
| function lolilo_ajax($string = ''){ |
| namespace Drupal\matthew\Plugin\Block; | |
| use Drupal\Core\Block\BlockBase; | |
| use Drupal\Core\Url; | |
| /** | |
| * Provides a 'Next Previous' block. | |
| * | |
| * @Block( |
| namespace Drupal\my_ckeditor\Plugin\CKEditorPlugin; | |
| use Drupal\ckeditor\CKEditorPluginInterface; | |
| use Drupal\Component\Plugin\PluginBase; | |
| use Drupal\ckeditor\Annotation\CKEditorPlugin; | |
| use Drupal\Core\Annotation\Translation; | |
| use Drupal\editor\Entity\Editor; | |
| /** | |
| * Defines the "templates" plugin. |
| <?php | |
| class ElasticsearchIndex { | |
| public $_index; | |
| public $_type; | |
| public $_server; | |
| public $_protocol; | |
| function __construct($protocol, $server, $index, $type){ |
| ########################################################################## | |
| #### Script to setup Codio box for Drupal development | |
| ########################################################################## | |
| #### Instructions | |
| #### From the Codio Dashboard, create a new Empty template project. | |
| #### Open a Terminal window from the Tools->Terminal window | |
| #### Copy the contents of this file to a file called 'setup.sh' in the root of your machines file system | |
| try { | |
| } catch (Exception $e) { | |
| drupal_set_message(t('message %message', | |
| array('%message' => $e->getMessage())), 'error'); | |
| watchdog('lol', t('Add new items structure : @time sec, name : @name ', | |
| array('@time' => $time_execute, | |
| '@name' =>$item->structure)), array()); | |
| } |
| drupal_goto('<front>'); |