Jump to:

17452 Posts in 4473 Topics by 1971 members


SilverStripe Forums » Archive » has_one and ImageField for multilang website

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Page: 1
Go to End
Author Topic: 872 Views
    Community Member
    3 Posts

    has_one and ImageField for multilang website Link to this post

    how can i add different image for different languages?


    class Page extends SiteTree
       static $has_one = array(
          'MenuImg' => 'Image'




    $fields->addFieldToTab("Root.Content.Images", new ImageField('MenuImg','Menu image'));


    but when i change image for one language version it's changed for another.

    i try:

       static $extensions = array(

    but it doesn't help, and what is more using $extensions and Translatable it seems to me that other fields from Page became one language field.

    can someone explain how i can meke it works?

Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.