Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, biapar, Willr, Ingo, swaiba

Customising Labels - ImageGallery: SOLVED


Go to End
Reply


2 Posts   733 Views

Avatar
pinkp

Community Member, 176 Posts

13 April 2010 at 2:13am

Edited: 13/04/2010 8:41am

What is the best way to change the labels of the ImageGallery. I need to customise it like so:

ImageGalleryAlbum.php

public function getCMSFields_forPopup()
	{
		return new FieldSet(
			new TextField('AlbumName', _t('ImageGalleryAlbum.ALBUMTITLE','Artist Name')),
			new TextareaField('Description', _t('ImageGalleryAlbum.DESCRIPTION','Artist Statement')),
			new ImageField('CoverImage',_t('ImageGalleryAlbum.COVERIMAGE','Artist Main Image'))
		);
	}

And also change all "album' references to "artist" the above does not seem to have any effect?

Thanks

---------------
EDIT

public function getCMSFields_forPopup()
	{
		return new FieldSet(
			new TextField('AlbumName', _t('ImageGalleryAlbum.ARTISTNAME','Artist Name')),
			new TextareaField('Description', _t('ImageGalleryAlbum.ARTISTSTATEMENT','Artist Statement')),
			new ImageField('CoverImage',_t('ImageGalleryAlbum.ARTISTMAINIMAGE','Artist Main Image'))
		);
	}

Avatar
UncleCheese

Forum Moderator, 4096 Posts

15 April 2010 at 1:46am

I'm pretty sure the cleanest way to do this would have been to override the lang file.

$lang[your_Locale]['ImageGalleryAlbum']['ALBUMTITLE'] = "My Label";