예제 #1
0
 def __before__(self):
      if 'lang' in session:
           set_lang(session['lang'])
      else:
           set_lang('fa')
           session['lang']='fa'
           session.save()
      
      h.setMenuItems(_('menus.dat'))
      self.menu_items = session[_('menus.dat')]
      h.setPageContents(_('pages.dat'))
예제 #2
0
 def __before__(self):        
     #if 'lang' in session:
         #set_lang(session['lang'])
     #else:
         #set_lang('fa')
         #session['lang']='fa'
         #session.save()
     set_lang(request.environ['app.lang'])
         
     h.setMenuItems(_('menus.dat'))
     h.setPageContents(_('pages.dat'))
     self.menu_items = session[_('menus.dat')]     
예제 #3
0
 def __before__(self):
     set_lang(request.environ["app.lang"])
     h.setPageContents(_("pages.dat"))
예제 #4
0
 def __before__(self):
     set_lang(request.environ['app.lang'])      
     h.setPageContents(_('pages.dat'))        
예제 #5
0
 def __before__(self):    
     set_lang(request.environ['app.lang'])   
     h.setMenuItems(_('menus.dat'))
     h.setPageContents(_('pages.dat'))
     self.menu_items = session[_('menus.dat')]