I am trying to customize a module(quicktabs) for my need. In the hook_block_view, the block['content'] contains an associative array of the contents. Is there an existing drupal call that renders the associative array in block['content']?


Yes: drupal_render()

Renders HTML given a structured array tree.

Recursively iterates over each of the array elements, generating HTML code.

There's much more explanation, and examples, on the docs page.

I'd advise also reading through Render Arrays in Drupal 7 to get a better idea of what that array represents.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.