Download & Extend

Translation of block subject missing

Project:CCK Blocks
Version:6.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Earl Grey
Status:closed (fixed)

Issue Summary

When using the i18ncontent module (part of i18n module), it is possible to translate the labels of fields of content types. These translations are not shown in the CCK Blocks, because the t() function is not used to display the block subject.

This minor change solves it:

<?php
 
/* original line 54, does not use t() on content label for block subject
  block['subject'] = $fields[$delta]['widget']['label'] ? $fields[$delta]['widget']['label'] : $delta;
  */

  // replace with this, using t():
 
$block['subject'] = t($fields[$delta]['widget']['label'] ? $fields[$delta]['widget']['label'] : $delta);
?>

Comments

#1

THANKS

#2

Version:6.x-1.1» 6.x-1.x-dev
Assigned to:Anonymous» Earl Grey
Status:active» needs review

Please test the attached patch. It will get into the -dev version, if it works.

AttachmentSize
cck-blocks-translatesubject-DEV-316166-3.patch 792 bytes

#3

To make testing easier, this patch is contained in tomorrows -dev release.

#4

Status:needs review» fixed

seems to be fixed, as there are no further comments.

#5

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.