@@ -233,6 +233,8 @@ msgid ""
233233"Back or Cancel button) the :attr:`~FieldStorage.done` attribute of the "
234234"object for the field will be set to the value -1."
235235msgstr ""
236+ "如果在获取上传文件的内容时遇到错误(例如,当用户点击回退或取消按钮中断表单提交时)该字段中对象的 :attr:`~FieldStorage.done` "
237+ "属性值将被设为 -1。"
236238
237239#: ../../library/cgi.rst:167
238240msgid ""
@@ -245,6 +247,10 @@ msgid ""
245247"case, it can be iterated over recursively just like the top-level form "
246248"object."
247249msgstr ""
250+ "文件上传标准草案考虑到了从一个字段上传多个文件的可能性(使用递归的 :mimetype:`multipart/\\ *` 编码格式)。 "
251+ "当这种情况发生时,该条目将是一个类似字典的 :class:`FieldStorage` 条目。 这可以通过检测它的 :attr:`!type` "
252+ "属性来确定,该属性应当是 :mimetype:`multipart/form-data` (或者可能是匹配 "
253+ ":mimetype:`multipart/\\ *` 的其他 MIME 类型)。 在这种情况下,它可以像最高层级的表单对象一样被递归地迭代处理。"
248254
249255#: ../../library/cgi.rst:175
250256msgid ""
@@ -254,28 +260,34 @@ msgid ""
254260"In this case, the :attr:`!list`, :attr:`!file`, and :attr:`filename` "
255261"attributes are always ``None``."
256262msgstr ""
263+ "当一个表单按“旧”格式提交时(即以查询字符串或是单个 :mimetype:`application/x-www-form-urlencoded` "
264+ "类型的数据部分的形式),这些条目实际上将是 :class:`MiniFieldStorage` 类的实例。 在这种情况下,:attr:`!list`, "
265+ ":attr:`!file` 和 :attr:`filename` 属性将总是为 ``None``。"
257266
258267#: ../../library/cgi.rst:180
259268msgid ""
260269"A form submitted via POST that also has a query string will contain both "
261270":class:`FieldStorage` and :class:`MiniFieldStorage` items."
262271msgstr ""
272+ "通过 POST 方式提交并且也带有查询字符串的表单将同时包含 :class:`FieldStorage` 和 "
273+ ":class:`MiniFieldStorage` 条目。"
263274
264275#: ../../library/cgi.rst:183
265276msgid ""
266277"The :attr:`~FieldStorage.file` attribute is automatically closed upon the "
267278"garbage collection of the creating :class:`FieldStorage` instance."
268279msgstr ""
280+ ":attr:`~FieldStorage.file` 属性会在创建 :class:`FieldStorage` 实例的垃圾回收操作中被自动关闭。"
269281
270282#: ../../library/cgi.rst:187
271283msgid ""
272284"Added support for the context management protocol to the "
273285":class:`FieldStorage` class."
274- msgstr ""
286+ msgstr "为 :class:`FieldStorage` 类增加了上下文管理协议支持。 "
275287
276288#: ../../library/cgi.rst:193
277289msgid "Higher Level Interface"
278- msgstr ""
290+ msgstr "更高层级的接口 "
279291
280292#: ../../library/cgi.rst:195
281293msgid ""
0 commit comments