How to add "itemscope itemtype="http://schema.org/Article" in drupal 7 -


this function_preprocess loaded css clases in block.tpl.php. how add same div other attributes itemscope itemtype="http://schema.org/periodical", itemprop="image", itemprop="description" , more... microdata elements

function floyd_preprocess_region(&$variables, $hook) {     if($variables['region'] == "top_c"){         $variables['classes_array'][] = 'uk-margin-top uk-margin-bottom uk- grid-width-small-1-1 uk-grid-width-medium-1-3 uk-grid-width-large-1-4'; } 

" **itemscope itemtype="http://schema.org/article"**>

instead of:

$variables['classes_array'][] = ... 

try:

$variables['title_attributes_array']['class'][] = ... 

and if it's block, think should try hook instead:

function floyd_preprocess_block(&$variables, $hook) {...} 

(block instead of region)


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -