Links namespace as constants

Developer
Dec 8, 2012 at 1:46 AM

Sometimes I have to use items from links namespace inside attributes.  Or I need to use Controller.Name inside an attribute or other place where a constant is required.

Wonder about the possibility of generating constants for all the links (in addition to, instead of, or not at all depending on setting.xml).

Would end up with

Links.Content_Images_SomeFolder_SomeGraphic_gif

and so on....thoughts?

Coordinator
Dec 8, 2012 at 5:31 AM

Note that for the controller name, you can already do this using NameConst (see this bug).

For the links, the tricky part is that with const we lose the ability to run logic to generate the strings, and it relies on that heavily (a lot of it from your past contributions I think :) ).