+-- i18n helper
+function Node._i18n(self, config, section, option, title, description)
+
+ -- i18n loaded?
+ if type(luci.i18n) == "table" then
+
+ local key = config:gsub("[^%w]+", "")
+
+ if section then key = key .. "_" .. section:lower():gsub("[^%w]+", "") end
+ if option then key = key .. "_" .. option:lower():gsub("[^%w]+", "") end
+
+ self.title = title or luci.i18n.translate( key, option or section or config )
+ self.description = description or luci.i18n.translate( key .. "_desc", "" )
+ end
+end
+