Esempio n. 1
0
    def get(self):
        best = pick_locale(self.request)
        ordered = ordered_locales(self.request)

        template_values = {'best': best, 'ordered': ordered}

        self.response.headers["Content-Type"] = "application/javascript"
        path = os.path.join(os.path.dirname(__file__), 'put_variable.js')
        self.response.out.write(template.render(path, template_values))
Esempio n. 2
0
  def get(self):
    best = pick_locale(self.request)

    template_values = {
      'locale': best
    }

    self.response.headers["Content-Type"] = "application/javascript"

    path = os.path.join(os.path.dirname(__file__), 'set_metatag.js')
    self.response.out.write(template.render(path, template_values))
Esempio n. 3
0
  def get(self):
    best = pick_locale(self.request)
    ordered = ordered_locales(self.request)

    template_values = {
      'best': best,
      'ordered': ordered
    }

    self.response.headers["Content-Type"] = "application/javascript"
    path = os.path.join(os.path.dirname(__file__), 'put_variable.js')
    self.response.out.write(template.render(path, template_values))