Manish Basdeo
Manish Basdeo

Reputation: 6269

How do i overwrite the default drupal6 block template?

I want to customize the default block of drupal 6 such that i have my own template for different blocks ..How can I achieve that ?

Upvotes: 0

Views: 718

Answers (2)

keyur.patel
keyur.patel

Reputation: 36

Steps to customize block.tpl.php

  1. Copy block.tpl.php file from your current enabled theme.
  2. Paste it.
  3. Name it like : block-{machine readable name of your block(or block-id)}.tpl.php Note: "Do not use Curly brackets {}. It just for separation"
  4. go to admin part of your site and flush all cache.
  5. That's it. go to the place where you decide to display block and made changes in your customize block-{your block name}.tpl.php file.

Upvotes: 1

Aneesh
Aneesh

Reputation: 158

1) goto the theme folder 2) copy the content of block.tpl.php to a new file block-div-id.tpl.php, where block-div-id is the div id of the block which you want to customize. 3) Now this template will be used to render that block.

Upvotes: 1

Related Questions