recentpopularlog in

therobyouknow : time   132

« earlier  
8 - How can we get Block Bundle Type for block in code? - Drupal Answers
use \Drupal\block_content\BlockContentInterface;


/**
* Implements HOOK_preprocess_block().
*
* @param $variables
*/
function mymodule_preprocess_block(&$variables) {
$content = $variables['elements']['content'];
if (isset($content['#block_content']) && $content['#block_content'] instanceof BlockContentInterface) {

if ($content['#block_content']->bundle() == 'xxx') {
// ...
}

}
}
8  drupal8  drupal  web  dev  cms  computing  module  theme  block  update  refresh  force  cache  disable  twig  specific  howto  question  answer  problem  solution  time  computed  generated  calculated 
4 weeks ago by therobyouknow
PHP: DateTime::createFromFormat - Manual
including how to ignore characters, e.g. \0 and ignore remainder of string using + (plus)
php  guide  datetime  reference  date  time  example  timezone  ignore  computing  dev  web 
november 2016 by therobyouknow
Storing Milliseconds in MySQL
milliseconds in its own table, seems a little complex to me
php  time  mysql  timestamp  millisecond  numeric  int  field  computing  database  table 
september 2011 by therobyouknow
« earlier      
per page:    204080120160

Copy this bookmark:





to read