Jump to:

23550 Posts in 19336 Topics by 2890 members

General Questions

SilverStripe Forums » General Questions » provideI18nEntities() hardly(!) working in 3.0?

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Page: 1
Go to End
Author Topic: 400 Views
  • martimiz
    Forum Moderator
    1091 Posts

    provideI18nEntities() hardly(!) working in 3.0? Link to this post

    Normally I'd use the provideI18nEntities::provideI18nEntities() method to offer translations to the TextCollector that cannot otherwise be picked up from a _t() function in a class. But it looks like in 3.0 the TextCollector almost never gets there:

    in i18nTextCollector line 399: class_exists($class, false) seems to almost(!) always return false on my module classes. (only a SiteConfig decorator returns true). It states:

    // Not all classes can be instanciated without mandatory arguments,
    // so entity collection doesn't work for all SilverStripe classes currently
    // Requires PHP 5.1+

    But shouldn't class_exists(...) return true on existing classes anyway? Can anyone reproduce this?

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.