Friday, June 29, 2007

Define a new block in drupal

open          "site_base"/ template/"template_name"/template.php
function themeName_regions()
{
return array(
"left"=>t("left sidebar"),
"right"=>t("right sidebar"),
"newRegion"=>t("human readable name for the region");
)

}

you must edit theme file(Especially page.tpl.php) for outputing  "newRegion"

1 comment:

  1. thanks much this worked great!

    there is a parse error in the array (it's ended ; one level too high

    :)

    ReplyDelete