Outputting dynamic php content from a drupal 7 module -


i've written module in drupal 7 output overview page project management application. im not sure how reference php variables in block out put. block content displayed through main content area.

i thought might able (i.e. fullpath represent path image change dynamically based on returned db query).

$block['content'] = ("<div><p>overview stuff <?php echo $fullpath?></p></div>"); 

however php element doesn't come through , don't think that's proper way anyway. i've not yet had experience .tpl.php files might way go. i've checked on google solution , going through docs not found yet.

can give me idea of how should go this?

many thanks

peter

i like

 $block['content'] = array(      '#markup' => t('overview stuff') . ' ' . $fullpath,      '#prefix' => '<div><p>',      '#suffix' => '</p></div>',  ); 

Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c# - Copy ObservableCollection to another ObservableCollection -

All overlapping substrings matching a java regex -