|
1 | | -# SOME DESCRIPTIVE TITLE. |
2 | | -# Copyright (C) 2001 Python Software Foundation |
3 | | -# This file is distributed under the same license as the Python package. |
4 | | -# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. |
5 | | -# |
6 | | -# Translators: |
7 | | -# python-doc bot, 2025 |
8 | | -# |
9 | | -#, fuzzy |
| 1 | +# |
10 | 2 | msgid "" |
11 | 3 | msgstr "" |
12 | | -"Project-Id-Version: Python 3.15\n" |
13 | | -"Report-Msgid-Bugs-To: \n" |
14 | | -"POT-Creation-Date: 2026-09-11 17:24+0000\n" |
15 | | -"PO-Revision-Date: 2025-09-16 00:01+0000\n" |
16 | | -"Last-Translator: python-doc bot, 2025\n" |
17 | | -"Language-Team: Indonesian (https://app.transifex.com/python-doc/teams/5390/" |
18 | | -"id/)\n" |
19 | | -"MIME-Version: 1.0\n" |
20 | | -"Content-Type: text/plain; charset=UTF-8\n" |
21 | | -"Content-Transfer-Encoding: 8bit\n" |
| 4 | +"Language-Team: Indonesian (https://app.transifex.com/python-doc/teams/5390/id/)\n" |
22 | 5 | "Language: id\n" |
23 | 6 | "Plural-Forms: nplurals=1; plural=0;\n" |
24 | | - |
25 | | -msgid ":mod:`!http.cookies` --- HTTP state management" |
26 | | -msgstr "" |
27 | | - |
28 | | -msgid "**Source code:** :source:`Lib/http/cookies.py`" |
29 | | -msgstr "" |
30 | | - |
31 | | -msgid "" |
32 | | -"The :mod:`!http.cookies` module defines classes for abstracting the concept " |
33 | | -"of cookies, an HTTP state management mechanism. It supports both simple " |
34 | | -"string-only cookies, and provides an abstraction for having any serializable " |
35 | | -"data-type as cookie value." |
36 | | -msgstr "" |
37 | | - |
38 | | -msgid "" |
39 | | -"The module formerly strictly applied the parsing rules described in the :rfc:" |
40 | | -"`2109` and :rfc:`2068` specifications. It has since been discovered that " |
41 | | -"MSIE 3.0x didn't follow the character rules outlined in those specs; many " |
42 | | -"current-day browsers and servers have also relaxed parsing rules when it " |
43 | | -"comes to cookie handling. As a result, this module now uses parsing rules " |
44 | | -"that are a bit less strict than they once were." |
45 | | -msgstr "" |
46 | | - |
47 | | -msgid "" |
48 | | -"The character set, :data:`string.ascii_letters`, :data:`string.digits` and " |
49 | | -"``!#$%&'*+-.^_`|~:`` denote the set of valid characters allowed by this " |
50 | | -"module in a cookie name (as :attr:`~Morsel.key`)." |
51 | | -msgstr "" |
52 | | - |
53 | | -msgid "Allowed ':' as a valid cookie name character." |
54 | | -msgstr "" |
55 | | - |
56 | | -msgid "" |
57 | | -"On encountering an invalid cookie, :exc:`CookieError` is raised, so if your " |
58 | | -"cookie data comes from a browser you should always prepare for invalid data " |
59 | | -"and catch :exc:`CookieError` on parsing." |
60 | | -msgstr "" |
61 | | - |
62 | | -msgid "" |
63 | | -"Exception failing because of :rfc:`2109` invalidity: incorrect attributes, " |
64 | | -"incorrect :mailheader:`Set-Cookie` header, etc." |
65 | | -msgstr "" |
66 | | - |
67 | | -msgid "" |
68 | | -"This class is a dictionary-like object whose keys are strings and whose " |
69 | | -"values are :class:`Morsel` instances. Note that upon setting a key to a " |
70 | | -"value, the value is first converted to a :class:`Morsel` containing the key " |
71 | | -"and the value." |
72 | | -msgstr "" |
73 | | - |
74 | | -msgid "If *input* is given, it is passed to the :meth:`load` method." |
75 | | -msgstr "" |
76 | | - |
77 | | -msgid "" |
78 | | -"This class derives from :class:`BaseCookie` and overrides :meth:`~BaseCookie." |
79 | | -"value_decode` and :meth:`~BaseCookie.value_encode`. :class:`!SimpleCookie` " |
80 | | -"supports strings as cookie values. When setting the value, :class:`!" |
81 | | -"SimpleCookie` calls the builtin :func:`str` to convert the value to a " |
82 | | -"string. Values received from HTTP are kept as strings." |
83 | | -msgstr "" |
84 | | - |
85 | | -msgid "Module :mod:`http.cookiejar`" |
86 | | -msgstr "" |
87 | | - |
88 | | -msgid "" |
89 | | -"HTTP cookie handling for web *clients*. The :mod:`http.cookiejar` and :mod:" |
90 | | -"`!http.cookies` modules do not depend on each other." |
91 | | -msgstr "" |
92 | | - |
93 | | -msgid ":rfc:`2109` - HTTP State Management Mechanism" |
94 | | -msgstr "" |
95 | | - |
96 | | -msgid "This is the state management specification implemented by this module." |
97 | | -msgstr "" |
98 | | - |
99 | | -msgid "Cookie Objects" |
100 | | -msgstr "Objek *Cookie*" |
101 | | - |
102 | | -msgid "" |
103 | | -"Return a tuple ``(real_value, coded_value)`` from a string representation. " |
104 | | -"``real_value`` can be any type. This method does no decoding in :class:" |
105 | | -"`BaseCookie` --- it exists so it can be overridden." |
106 | | -msgstr "" |
107 | | - |
108 | | -msgid "" |
109 | | -"Return a tuple ``(real_value, coded_value)``. *val* can be any type, but " |
110 | | -"``coded_value`` will always be converted to a string. This method does no " |
111 | | -"encoding in :class:`BaseCookie` --- it exists so it can be overridden." |
112 | | -msgstr "" |
113 | | - |
114 | | -msgid "" |
115 | | -"In general, it should be the case that :meth:`value_encode` and :meth:" |
116 | | -"`value_decode` are inverses on the range of *value_decode*." |
117 | | -msgstr "" |
118 | | - |
119 | | -msgid "" |
120 | | -"Return a string representation suitable to be sent as HTTP headers. *attrs* " |
121 | | -"and *header* are sent to each :class:`Morsel`'s :meth:`~Morsel.output` " |
122 | | -"method. *sep* is used to join the headers together, and is by default the " |
123 | | -"combination ``'\\r\\n'`` (CRLF)." |
124 | | -msgstr "" |
125 | | - |
126 | | -msgid "" |
127 | | -"Return an embeddable JavaScript snippet, which, if run on a browser which " |
128 | | -"supports JavaScript, will act the same as if the HTTP headers was sent." |
129 | | -msgstr "" |
130 | | - |
131 | | -msgid "The meaning for *attrs* is the same as in :meth:`output`." |
132 | | -msgstr "" |
133 | | - |
134 | | -msgid "" |
135 | | -"This method generates a JavaScript snippet to set cookies in the browser, " |
136 | | -"which is no longer considered a standard or recommended approach. Use :meth:" |
137 | | -"`~http.cookies.BaseCookie.output` instead to generate HTTP headers." |
138 | | -msgstr "" |
139 | | - |
140 | | -msgid "" |
141 | | -"If *rawdata* is a string, parse it as an ``HTTP_COOKIE`` and add the values " |
142 | | -"found there as :class:`Morsel`\\ s. If it is a dictionary, it is equivalent " |
143 | | -"to::" |
144 | | -msgstr "" |
145 | | - |
146 | | -msgid "" |
147 | | -"for k, v in rawdata.items():\n" |
148 | | -" cookie[k] = v" |
149 | | -msgstr "" |
150 | | - |
151 | | -msgid "Morsel Objects" |
152 | | -msgstr "Object *Morsel*" |
153 | | - |
154 | | -msgid "Abstract a key/value pair, which has some :rfc:`2109` attributes." |
155 | | -msgstr "" |
156 | | - |
157 | | -msgid "" |
158 | | -"Morsels are dictionary-like objects, whose set of keys is constant --- the " |
159 | | -"valid :rfc:`2109` attributes, which are:" |
160 | | -msgstr "" |
161 | | - |
162 | | -msgid "" |
163 | | -"The attribute :attr:`httponly` specifies that the cookie is only transferred " |
164 | | -"in HTTP requests, and is not accessible through JavaScript. This is intended " |
165 | | -"to mitigate some forms of cross-site scripting." |
166 | | -msgstr "" |
167 | | - |
168 | | -msgid "" |
169 | | -"The attribute :attr:`samesite` controls when the browser sends the cookie " |
170 | | -"with cross-site requests. This helps to mitigate CSRF attacks. Valid values " |
171 | | -"are \"Strict\" (only sent with same-site requests), \"Lax\" (sent with same-" |
172 | | -"site requests and top-level navigations), and \"None\" (sent with same-site " |
173 | | -"and cross-site requests). When using \"None\", the \"secure\" attribute must " |
174 | | -"also be set, as required by modern browsers." |
175 | | -msgstr "" |
176 | | - |
177 | | -msgid "" |
178 | | -"The attribute :attr:`partitioned` indicates to user agents that these cross-" |
179 | | -"site cookies *should* only be available in the same top-level context that " |
180 | | -"the cookie was first set in. For this to be accepted by the user agent, you " |
181 | | -"**must** also set ``Secure``." |
182 | | -msgstr "" |
183 | | - |
184 | | -msgid "" |
185 | | -"In addition, it is recommended to use the ``__Host`` prefix when setting " |
186 | | -"partitioned cookies to make them bound to the hostname and not the " |
187 | | -"registrable domain. Read `CHIPS (Cookies Having Independent Partitioned " |
188 | | -"State)`_ for full details and examples." |
189 | | -msgstr "" |
190 | | - |
191 | | -msgid "The keys are case-insensitive and their default value is ``''``." |
192 | | -msgstr "" |
193 | | - |
194 | | -msgid "" |
195 | | -":meth:`!__eq__` now takes :attr:`~Morsel.key` and :attr:`~Morsel.value` into " |
196 | | -"account." |
197 | | -msgstr "" |
198 | | - |
199 | | -msgid "" |
200 | | -"Attributes :attr:`~Morsel.key`, :attr:`~Morsel.value` and :attr:`~Morsel." |
201 | | -"coded_value` are read-only. Use :meth:`~Morsel.set` for setting them." |
202 | | -msgstr "" |
203 | | - |
204 | | -msgid "Added support for the :attr:`samesite` attribute." |
205 | | -msgstr "" |
206 | | - |
207 | | -msgid "Added support for the :attr:`partitioned` attribute." |
208 | | -msgstr "" |
209 | | - |
210 | | -msgid "The value of the cookie." |
211 | | -msgstr "Nilai dari *cookie*" |
212 | | - |
213 | | -msgid "The encoded value of the cookie --- this is what should be sent." |
214 | | -msgstr "" |
215 | | - |
216 | | -msgid "The name of the cookie." |
217 | | -msgstr "Nama dari *cookie*" |
218 | | - |
219 | | -msgid "Set the *key*, *value* and *coded_value* attributes." |
220 | | -msgstr "" |
221 | | - |
222 | | -msgid "Whether *K* is a member of the set of keys of a :class:`Morsel`." |
223 | | -msgstr "" |
224 | | - |
225 | | -msgid "" |
226 | | -"Return a string representation of the Morsel, suitable to be sent as an HTTP " |
227 | | -"header. By default, all the attributes are included, unless *attrs* is " |
228 | | -"given, in which case it should be a list of attributes to use. *header* is " |
229 | | -"by default ``\"Set-Cookie:\"``." |
230 | | -msgstr "" |
231 | | - |
232 | | -msgid "" |
233 | | -"Return an embeddable JavaScript snippet, which, if run on a browser which " |
234 | | -"supports JavaScript, will act the same as if the HTTP header was sent." |
235 | | -msgstr "" |
236 | | - |
237 | | -msgid "" |
238 | | -"This method generates a JavaScript snippet to set cookies in the browser, " |
239 | | -"which is no longer considered a standard or recommended approach. Use :meth:" |
240 | | -"`~http.cookies.Morsel.output` instead to generate HTTP headers." |
241 | | -msgstr "" |
242 | | - |
243 | | -msgid "" |
244 | | -"Return a string representing the Morsel, without any surrounding HTTP or " |
245 | | -"JavaScript." |
246 | | -msgstr "" |
247 | | - |
248 | | -msgid "" |
249 | | -"Update the values in the Morsel dictionary with the values in the dictionary " |
250 | | -"*values*. Raise an error if any of the keys in the *values* dict is not a " |
251 | | -"valid :rfc:`2109` attribute." |
252 | | -msgstr "" |
253 | | - |
254 | | -msgid "an error is raised for invalid keys." |
255 | | -msgstr "" |
256 | | - |
257 | | -msgid "Return a shallow copy of the Morsel object." |
258 | | -msgstr "" |
259 | | - |
260 | | -msgid "return a Morsel object instead of a dict." |
261 | | -msgstr "" |
262 | | - |
263 | | -msgid "" |
264 | | -"Raise an error if key is not a valid :rfc:`2109` attribute, otherwise behave " |
265 | | -"the same as :meth:`dict.setdefault`." |
266 | | -msgstr "" |
267 | | - |
268 | | -msgid "Example" |
269 | | -msgstr "Contoh" |
270 | | - |
271 | | -msgid "" |
272 | | -"The following example demonstrates how to use the :mod:`!http.cookies` " |
273 | | -"module." |
274 | | -msgstr "" |
275 | | - |
276 | | -msgid "" |
277 | | -">>> from http import cookies\n" |
278 | | -">>> C = cookies.SimpleCookie()\n" |
279 | | -">>> C[\"fig\"] = \"newton\"\n" |
280 | | -">>> C[\"sugar\"] = \"wafer\"\n" |
281 | | -">>> print(C) # generate HTTP headers\n" |
282 | | -"Set-Cookie: fig=newton\n" |
283 | | -"Set-Cookie: sugar=wafer\n" |
284 | | -">>> print(C.output()) # same thing\n" |
285 | | -"Set-Cookie: fig=newton\n" |
286 | | -"Set-Cookie: sugar=wafer\n" |
287 | | -">>> C = cookies.SimpleCookie()\n" |
288 | | -">>> C[\"rocky\"] = \"road\"\n" |
289 | | -">>> C[\"rocky\"][\"path\"] = \"/cookie\"\n" |
290 | | -">>> print(C.output(header=\"Cookie:\"))\n" |
291 | | -"Cookie: rocky=road; Path=/cookie\n" |
292 | | -">>> print(C.output(attrs=[], header=\"Cookie:\"))\n" |
293 | | -"Cookie: rocky=road\n" |
294 | | -">>> C = cookies.SimpleCookie()\n" |
295 | | -">>> C.load(\"chips=ahoy; vienna=finger\") # load from a string (HTTP " |
296 | | -"header)\n" |
297 | | -">>> print(C)\n" |
298 | | -"Set-Cookie: chips=ahoy\n" |
299 | | -"Set-Cookie: vienna=finger\n" |
300 | | -">>> C = cookies.SimpleCookie()\n" |
301 | | -">>> C.load('keebler=\"E=everybody; L=\\\\\"Loves\\\\\"; fudge=;\";')\n" |
302 | | -">>> print(C)\n" |
303 | | -"Set-Cookie: keebler=\"E=everybody; L=\\\"Loves\\\"; fudge=;\"\n" |
304 | | -">>> C = cookies.SimpleCookie()\n" |
305 | | -">>> C[\"oreo\"] = \"doublestuff\"\n" |
306 | | -">>> C[\"oreo\"][\"path\"] = \"/\"\n" |
307 | | -">>> print(C)\n" |
308 | | -"Set-Cookie: oreo=doublestuff; Path=/\n" |
309 | | -">>> C = cookies.SimpleCookie()\n" |
310 | | -">>> C[\"twix\"] = \"none for you\"\n" |
311 | | -">>> C[\"twix\"].value\n" |
312 | | -"'none for you'\n" |
313 | | -">>> C = cookies.SimpleCookie()\n" |
314 | | -">>> C[\"number\"] = 7 # equivalent to C[\"number\"] = str(7)\n" |
315 | | -">>> C[\"string\"] = \"seven\"\n" |
316 | | -">>> C[\"number\"].value\n" |
317 | | -"'7'\n" |
318 | | -">>> C[\"string\"].value\n" |
319 | | -"'seven'\n" |
320 | | -">>> print(C)\n" |
321 | | -"Set-Cookie: number=7\n" |
322 | | -"Set-Cookie: string=seven" |
323 | | -msgstr "" |
0 commit comments