Aus irgendeinem Grund bekomme ich seltsame Eingabe für kyrillische Symbole in GAE.Eingabe von Formular, GAE, falsch
In der lokalen Umgebung funktioniert alles gut, ich bekomme, was im Eingabefeld war, mit self.request.get('')
. Aber auf Appspot, bekomme ich zum Beispiel "1mxt1czq0snfzq ==" oder "0ylqtdgb0yi =" anstelle von russischen Wörtern.
in Py
!/usr/bin/env python
-*- coding: utf-8 -*-
title = self.request.get('title')
in .html
meta charset="utf-8"
input type="text" name="title" id="title"
Ich bin stecken.
EDIT: Ja, es ist Base64, Sie haben Recht. Aber warum benutzt GAE es? Und wo, um es zu ändern? Warum das unterschiedliche Verhalten im lokalen und im Appspot?
In gleicher Form Ich versuche, um die Datei zu BlobHandler
<form class="form-horizontal" action="{{ upload_url }}" method="POST" enctype="multipart/form-data">
<div class="control-group">
<label class="control-label" for="title">Title</label>
<div class="controls">
<input type="text" name="title" id="title">
</div>
</div>
<div class="control-group">
<label class="control-label" for="file">Load image</label>
<div class="controls">
<input type="file" name="file" id="file" accept='image/*' required="required">
</div>
</div>
EDIT2 zu erhalten: Ja. https://code.google.com/p/googleappengine/issues/detail?id=2749
Scheint wie ein Fehler in GAE mit BlobHandler.
Lösung: accept-charset = "utf-8" in Form, das später versuchen.
, die wie 'base64' codierten Daten sehen ... – aviraldg