1
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
4
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
6
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
7
<link rel="home" href="index.html" title="libsoup Reference Manual">
8
<link rel="up" href="ch02.html" title="Core API">
9
<link rel="prev" href="libsoup-2.4-soup-status.html" title="soup-status">
10
<link rel="next" href="libsoup-2.4-Soup-Miscellaneous-Utilities.html" title="Soup Miscellaneous Utilities">
11
<meta name="generator" content="GTK-Doc V1.14 (XML mode)">
12
<link rel="stylesheet" href="style.css" type="text/css">
14
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
15
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
17
<td><a accesskey="p" href="libsoup-2.4-soup-status.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
18
<td><a accesskey="u" href="ch02.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
19
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
20
<th width="100%" align="center">libsoup Reference Manual</th>
21
<td><a accesskey="n" href="libsoup-2.4-Soup-Miscellaneous-Utilities.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
23
<tr><td colspan="5" class="shortcuts">
24
<a href="#libsoup-2.4-SoupURI.synopsis" class="shortcut">Top</a>
26
<a href="#libsoup-2.4-SoupURI.description" class="shortcut">Description</a>
29
<div class="refentry" title="SoupURI">
30
<a name="libsoup-2.4-SoupURI"></a><div class="titlepage"></div>
31
<div class="refnamediv"><table width="100%"><tr>
33
<h2><span class="refentrytitle"><a name="libsoup-2.4-SoupURI.top_of_page"></a>SoupURI</span></h2>
36
<td valign="top" align="right"></td>
38
<div class="refsynopsisdiv" title="Synopsis">
39
<a name="libsoup-2.4-SoupURI.synopsis"></a><h2>Synopsis</h2>
40
<pre class="synopsis">
41
#include <libsoup/soup.h>
43
<a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI">SoupURI</a>;
44
<a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="returnvalue">SoupURI</span></a> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-new-with-base" title="soup_uri_new_with_base ()">soup_uri_new_with_base</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *base</code></em>,
45
<em class="parameter"><code>const <span class="type">char</span> *uri_string</code></em>);
46
<a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="returnvalue">SoupURI</span></a> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-new" title="soup_uri_new ()">soup_uri_new</a> (<em class="parameter"><code>const <span class="type">char</span> *uri_string</code></em>);
47
<span class="returnvalue">char</span> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-to-string" title="soup_uri_to_string ()">soup_uri_to_string</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
48
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> just_path_and_query</code></em>);
50
<a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="returnvalue">SoupURI</span></a> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-copy" title="soup_uri_copy ()">soup_uri_copy</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>);
51
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-equal" title="soup_uri_equal ()">soup_uri_equal</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri1</code></em>,
52
<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri2</code></em>);
53
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-free" title="soup_uri_free ()">soup_uri_free</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>);
55
<span class="returnvalue">char</span> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-encode" title="soup_uri_encode ()">soup_uri_encode</a> (<em class="parameter"><code>const <span class="type">char</span> *part</code></em>,
56
<em class="parameter"><code>const <span class="type">char</span> *escape_extra</code></em>);
57
<span class="returnvalue">char</span> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-decode" title="soup_uri_decode ()">soup_uri_decode</a> (<em class="parameter"><code>const <span class="type">char</span> *part</code></em>);
58
<span class="returnvalue">char</span> * <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-normalize" title="soup_uri_normalize ()">soup_uri_normalize</a> (<em class="parameter"><code>const <span class="type">char</span> *part</code></em>,
59
<em class="parameter"><code>const <span class="type">char</span> *unescape_extra</code></em>);
61
#define <a class="link" href="libsoup-2.4-SoupURI.html#SOUP-URI-SCHEME-HTTP:CAPS" title="SOUP_URI_SCHEME_HTTP">SOUP_URI_SCHEME_HTTP</a>
62
#define <a class="link" href="libsoup-2.4-SoupURI.html#SOUP-URI-SCHEME-HTTPS:CAPS" title="SOUP_URI_SCHEME_HTTPS">SOUP_URI_SCHEME_HTTPS</a>
63
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-uses-default-port" title="soup_uri_uses_default_port ()">soup_uri_uses_default_port</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>);
64
#define <a class="link" href="libsoup-2.4-SoupURI.html#SOUP-URI-VALID-FOR-HTTP:CAPS" title="SOUP_URI_VALID_FOR_HTTP()">SOUP_URI_VALID_FOR_HTTP</a> (uri)
66
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-scheme" title="soup_uri_set_scheme ()">soup_uri_set_scheme</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
67
<em class="parameter"><code>const <span class="type">char</span> *scheme</code></em>);
68
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-user" title="soup_uri_set_user ()">soup_uri_set_user</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
69
<em class="parameter"><code>const <span class="type">char</span> *user</code></em>);
70
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-password" title="soup_uri_set_password ()">soup_uri_set_password</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
71
<em class="parameter"><code>const <span class="type">char</span> *password</code></em>);
72
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-host" title="soup_uri_set_host ()">soup_uri_set_host</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
73
<em class="parameter"><code>const <span class="type">char</span> *host</code></em>);
74
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-port" title="soup_uri_set_port ()">soup_uri_set_port</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
75
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> port</code></em>);
76
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-path" title="soup_uri_set_path ()">soup_uri_set_path</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
77
<em class="parameter"><code>const <span class="type">char</span> *path</code></em>);
78
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-query" title="soup_uri_set_query ()">soup_uri_set_query</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
79
<em class="parameter"><code>const <span class="type">char</span> *query</code></em>);
80
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-query-from-form" title="soup_uri_set_query_from_form ()">soup_uri_set_query_from_form</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
81
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Hash-Tables.html#GHashTable"><span class="type">GHashTable</span></a> *form</code></em>);
82
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-query-from-fields" title="soup_uri_set_query_from_fields ()">soup_uri_set_query_from_fields</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
83
<em class="parameter"><code>const <span class="type">char</span> *first_field</code></em>,
84
<em class="parameter"><code>...</code></em>);
85
<span class="returnvalue">void</span> <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-fragment" title="soup_uri_set_fragment ()">soup_uri_set_fragment</a> (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
86
<em class="parameter"><code>const <span class="type">char</span> *fragment</code></em>);
89
<div class="refsect1" title="Description">
90
<a name="libsoup-2.4-SoupURI.description"></a><h2>Description</h2>
92
A <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> represents a (parsed) URI.
95
Many applications will not need to use <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> directly at all; on
96
the client side, <a class="link" href="SoupMessage.html#soup-message-new" title="soup_message_new ()"><code class="function">soup_message_new()</code></a> takes a stringified URI, and on
97
the server side, the path and query components are provided for you
98
in the server callback.
101
<div class="refsect1" title="Details">
102
<a name="libsoup-2.4-SoupURI.details"></a><h2>Details</h2>
103
<div class="refsect2" title="SoupURI">
104
<a name="SoupURI"></a><h3>SoupURI</h3>
105
<pre class="programlisting">typedef struct {
121
A <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> represents a (parsed) URI. <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> supports RFC 3986
122
(URI Generic Syntax), and can parse any valid URI. However, libsoup
123
only uses "http" and "https" URIs internally; You can use
124
<a class="link" href="libsoup-2.4-SoupURI.html#SOUP-URI-VALID-FOR-HTTP:CAPS" title="SOUP_URI_VALID_FOR_HTTP()"><code class="function">SOUP_URI_VALID_FOR_HTTP()</code></a> to test if a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> is a valid HTTP
128
<em class="parameter"><code>scheme</code></em> will always be set in any URI. It is an interned string and
129
is always all lowercase. (If you parse a URI with a non-lowercase
130
scheme, it will be converted to lowercase.) The macros
131
<a class="link" href="libsoup-2.4-SoupURI.html#SOUP-URI-SCHEME-HTTP:CAPS" title="SOUP_URI_SCHEME_HTTP"><code class="literal">SOUP_URI_SCHEME_HTTP</code></a> and <a class="link" href="libsoup-2.4-SoupURI.html#SOUP-URI-SCHEME-HTTPS:CAPS" title="SOUP_URI_SCHEME_HTTPS"><code class="literal">SOUP_URI_SCHEME_HTTPS</code></a> provide the
132
interned values for "http" and "https" and can be compared against
133
URI <em class="parameter"><code>scheme</code></em> values.
136
<em class="parameter"><code>user</code></em> and <em class="parameter"><code>password</code></em> are parsed as defined in the older URI specs
137
(ie, separated by a colon; RFC 3986 only talks about a single
138
"userinfo" field). Note that <em class="parameter"><code>password</code></em> is not included in the
139
output of <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-to-string" title="soup_uri_to_string ()"><code class="function">soup_uri_to_string()</code></a>. libsoup does not normally use these
140
fields; authentication is handled via <a class="link" href="SoupSession.html" title="SoupSession"><span class="type">SoupSession</span></a> signals.
143
<em class="parameter"><code>host</code></em> contains the hostname, and <em class="parameter"><code>port</code></em> the port specified in the
144
URI. If the URI doesn't contain a hostname, <em class="parameter"><code>host</code></em> will be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>,
145
and if it doesn't specify a port, <em class="parameter"><code>port</code></em> may be 0. However, for
146
"http" and "https" URIs, <em class="parameter"><code>host</code></em> is guaranteed to be non-<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
147
(trying to parse an http URI with no <em class="parameter"><code>host</code></em> will return <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>), and
148
<em class="parameter"><code>port</code></em> will always be non-0 (because libsoup knows the default value
149
to use when it is not specified in the URI).
152
<em class="parameter"><code>path</code></em> is always non-<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. For http/https URIs, <em class="parameter"><code>path</code></em> will never be
153
an empty string either; if the input URI has no path, the parsed
154
<a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> will have a <em class="parameter"><code>path</code></em> of "/".
157
<em class="parameter"><code>query</code></em> and <em class="parameter"><code>fragment</code></em> are optional for all URI types.
158
<code class="function">soup_form_decode_urlencoded()</code> may be useful for parsing <em class="parameter"><code>query</code></em>.
161
Note that <em class="parameter"><code>path</code></em>, <em class="parameter"><code>query</code></em>, and <em class="parameter"><code>fragment</code></em> may contain
162
%-encoded characters. <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-new" title="soup_uri_new ()"><code class="function">soup_uri_new()</code></a> calls
163
<a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-normalize" title="soup_uri_normalize ()"><code class="function">soup_uri_normalize()</code></a> on them, but not <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-decode" title="soup_uri_decode ()"><code class="function">soup_uri_decode()</code></a>. This is
164
necessary to ensure that <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-to-string" title="soup_uri_to_string ()"><code class="function">soup_uri_to_string()</code></a> will generate a URI
165
that has exactly the same meaning as the original. (In theory,
166
<a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> should leave <em class="parameter"><code>user</code></em>, <em class="parameter"><code>password</code></em>, and <em class="parameter"><code>host</code></em> partially-encoded
167
as well, but this would be more annoying than useful.)
169
<div class="variablelist"><table border="0">
170
<col align="left" valign="top">
173
<td><p><span class="term">const <span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.scheme"></a>scheme</code></em>;</span></p></td>
174
<td>the URI scheme (eg, "http")
178
<td><p><span class="term"><span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.user"></a>user</code></em>;</span></p></td>
179
<td>a username, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
183
<td><p><span class="term"><span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.password"></a>password</code></em>;</span></p></td>
184
<td>a password, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
188
<td><p><span class="term"><span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.host"></a>host</code></em>;</span></p></td>
189
<td>the hostname or IP address
193
<td><p><span class="term"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> <em class="structfield"><code><a name="SoupURI.port"></a>port</code></em>;</span></p></td>
194
<td>the port number on <em class="parameter"><code>host</code></em>
198
<td><p><span class="term"><span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.path"></a>path</code></em>;</span></p></td>
199
<td>the path on <em class="parameter"><code>host</code></em>
203
<td><p><span class="term"><span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.query"></a>query</code></em>;</span></p></td>
204
<td>a query for <em class="parameter"><code>path</code></em>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
208
<td><p><span class="term"><span class="type">char</span> *<em class="structfield"><code><a name="SoupURI.fragment"></a>fragment</code></em>;</span></p></td>
209
<td>a fragment identifier within <em class="parameter"><code>path</code></em>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
216
<div class="refsect2" title="soup_uri_new_with_base ()">
217
<a name="soup-uri-new-with-base"></a><h3>soup_uri_new_with_base ()</h3>
218
<pre class="programlisting"><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="returnvalue">SoupURI</span></a> * soup_uri_new_with_base (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *base</code></em>,
219
<em class="parameter"><code>const <span class="type">char</span> *uri_string</code></em>);</pre>
221
Parses <em class="parameter"><code>uri_string</code></em> relative to <em class="parameter"><code>base</code></em>.
223
<div class="variablelist"><table border="0">
224
<col align="left" valign="top">
227
<td><p><span class="term"><em class="parameter"><code>base</code></em> :</span></p></td>
232
<td><p><span class="term"><em class="parameter"><code>uri_string</code></em> :</span></p></td>
237
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
238
<td> a parsed <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>.
245
<div class="refsect2" title="soup_uri_new ()">
246
<a name="soup-uri-new"></a><h3>soup_uri_new ()</h3>
247
<pre class="programlisting"><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="returnvalue">SoupURI</span></a> * soup_uri_new (<em class="parameter"><code>const <span class="type">char</span> *uri_string</code></em>);</pre>
249
Parses an absolute URI.
252
You can also pass <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> for <em class="parameter"><code>uri_string</code></em> if you want to get back an
253
"empty" <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> that you can fill in by hand. (You will need to
254
call at least <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-scheme" title="soup_uri_set_scheme ()"><code class="function">soup_uri_set_scheme()</code></a> and <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-set-path" title="soup_uri_set_path ()"><code class="function">soup_uri_set_path()</code></a>, since
255
those fields are required.)
257
<div class="variablelist"><table border="0">
258
<col align="left" valign="top">
261
<td><p><span class="term"><em class="parameter"><code>uri_string</code></em> :</span></p></td>
266
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
267
<td> a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.
274
<div class="refsect2" title="soup_uri_to_string ()">
275
<a name="soup-uri-to-string"></a><h3>soup_uri_to_string ()</h3>
276
<pre class="programlisting"><span class="returnvalue">char</span> * soup_uri_to_string (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
277
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> just_path_and_query</code></em>);</pre>
279
Returns a string representing <em class="parameter"><code>uri</code></em>.
282
If <em class="parameter"><code>just_path_and_query</code></em> is <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>, this concatenates the path and query
283
together. That is, it constructs the string that would be needed in
284
the Request-Line of an HTTP request for <em class="parameter"><code>uri</code></em>.
286
<div class="variablelist"><table border="0">
287
<col align="left" valign="top">
290
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
291
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
295
<td><p><span class="term"><em class="parameter"><code>just_path_and_query</code></em> :</span></p></td>
296
<td>if <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>, output just the path and query portions
300
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
301
<td> a string representing <em class="parameter"><code>uri</code></em>, which the caller must free.
308
<div class="refsect2" title="soup_uri_copy ()">
309
<a name="soup-uri-copy"></a><h3>soup_uri_copy ()</h3>
310
<pre class="programlisting"><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="returnvalue">SoupURI</span></a> * soup_uri_copy (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>);</pre>
312
Copies <em class="parameter"><code>uri</code></em>
314
<div class="variablelist"><table border="0">
315
<col align="left" valign="top">
318
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
319
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
323
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
324
<td> a copy of <em class="parameter"><code>uri</code></em>, which must be freed with <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-free" title="soup_uri_free ()"><code class="function">soup_uri_free()</code></a>
331
<div class="refsect2" title="soup_uri_equal ()">
332
<a name="soup-uri-equal"></a><h3>soup_uri_equal ()</h3>
333
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> soup_uri_equal (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri1</code></em>,
334
<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri2</code></em>);</pre>
336
Tests whether or not <em class="parameter"><code>uri1</code></em> and <em class="parameter"><code>uri2</code></em> are equal in all parts
338
<div class="variablelist"><table border="0">
339
<col align="left" valign="top">
342
<td><p><span class="term"><em class="parameter"><code>uri1</code></em> :</span></p></td>
343
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
347
<td><p><span class="term"><em class="parameter"><code>uri2</code></em> :</span></p></td>
348
<td>another <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
352
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
353
<td> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>
360
<div class="refsect2" title="soup_uri_free ()">
361
<a name="soup-uri-free"></a><h3>soup_uri_free ()</h3>
362
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_free (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>);</pre>
364
Frees <em class="parameter"><code>uri</code></em>.
366
<div class="variablelist"><table border="0">
367
<col align="left" valign="top">
369
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
370
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
376
<div class="refsect2" title="soup_uri_encode ()">
377
<a name="soup-uri-encode"></a><h3>soup_uri_encode ()</h3>
378
<pre class="programlisting"><span class="returnvalue">char</span> * soup_uri_encode (<em class="parameter"><code>const <span class="type">char</span> *part</code></em>,
379
<em class="parameter"><code>const <span class="type">char</span> *escape_extra</code></em>);</pre>
381
This %-encodes the given URI part and returns the escaped
382
version in allocated memory, which the caller must free when it is
385
<div class="variablelist"><table border="0">
386
<col align="left" valign="top">
389
<td><p><span class="term"><em class="parameter"><code>part</code></em> :</span></p></td>
394
<td><p><span class="term"><em class="parameter"><code>escape_extra</code></em> :</span></p></td>
395
<td>additional reserved characters to escape (or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>)
399
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
400
<td> the encoded URI part
407
<div class="refsect2" title="soup_uri_decode ()">
408
<a name="soup-uri-decode"></a><h3>soup_uri_decode ()</h3>
409
<pre class="programlisting"><span class="returnvalue">char</span> * soup_uri_decode (<em class="parameter"><code>const <span class="type">char</span> *part</code></em>);</pre>
411
Fully %-decodes <em class="parameter"><code>part</code></em>.
413
<div class="variablelist"><table border="0">
414
<col align="left" valign="top">
417
<td><p><span class="term"><em class="parameter"><code>part</code></em> :</span></p></td>
422
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
423
<td> the decoded URI part, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if an invalid percent
424
code was encountered.
431
<div class="refsect2" title="soup_uri_normalize ()">
432
<a name="soup-uri-normalize"></a><h3>soup_uri_normalize ()</h3>
433
<pre class="programlisting"><span class="returnvalue">char</span> * soup_uri_normalize (<em class="parameter"><code>const <span class="type">char</span> *part</code></em>,
434
<em class="parameter"><code>const <span class="type">char</span> *unescape_extra</code></em>);</pre>
436
%-decodes any "unreserved" characters (or characters in
437
<em class="parameter"><code>unescape_extra</code></em>) in <em class="parameter"><code>part</code></em>.
440
"Unreserved" characters are those that are not allowed to be used
441
for punctuation according to the URI spec. For example, letters are
442
unreserved, so <a class="link" href="libsoup-2.4-SoupURI.html#soup-uri-normalize" title="soup_uri_normalize ()"><code class="function">soup_uri_normalize()</code></a> will turn
443
<code class="literal">http://example.com/foo/b%61r</code> into
444
<code class="literal">http://example.com/foo/bar</code>, which is guaranteed
445
to mean the same thing. However, "/" is "reserved", so
446
<code class="literal">http://example.com/foo%2Fbar</code> would not
447
be changed, because it might mean something different to the
450
<div class="variablelist"><table border="0">
451
<col align="left" valign="top">
454
<td><p><span class="term"><em class="parameter"><code>part</code></em> :</span></p></td>
459
<td><p><span class="term"><em class="parameter"><code>unescape_extra</code></em> :</span></p></td>
460
<td>reserved characters to unescape (or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>)
464
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
465
<td> the normalized URI part, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if an invalid percent
466
code was encountered.
473
<div class="refsect2" title="SOUP_URI_SCHEME_HTTP">
474
<a name="SOUP-URI-SCHEME-HTTP:CAPS"></a><h3>SOUP_URI_SCHEME_HTTP</h3>
475
<pre class="programlisting">#define SOUP_URI_SCHEME_HTTP _SOUP_ATOMIC_INTERN_STRING (_SOUP_URI_SCHEME_HTTP, "http")
478
"http" as an interned string. This can be compared directly against
479
the value of a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>'s <em class="structfield"><code>scheme</code></em>
483
<div class="refsect2" title="SOUP_URI_SCHEME_HTTPS">
484
<a name="SOUP-URI-SCHEME-HTTPS:CAPS"></a><h3>SOUP_URI_SCHEME_HTTPS</h3>
485
<pre class="programlisting">#define SOUP_URI_SCHEME_HTTPS _SOUP_ATOMIC_INTERN_STRING (_SOUP_URI_SCHEME_HTTPS, "https")
488
"https" as an interned string. This can be compared directly
489
against the value of a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>'s <em class="structfield"><code>scheme</code></em>
493
<div class="refsect2" title="soup_uri_uses_default_port ()">
494
<a name="soup-uri-uses-default-port"></a><h3>soup_uri_uses_default_port ()</h3>
495
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> soup_uri_uses_default_port (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>);</pre>
497
Tests if <em class="parameter"><code>uri</code></em> uses the default port for its scheme. (Eg, 80 for
498
http.) (This only works for http and https; libsoup does not know
499
the default ports of other protocols.)
501
<div class="variablelist"><table border="0">
502
<col align="left" valign="top">
505
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
506
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
510
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
511
<td> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>
518
<div class="refsect2" title="SOUP_URI_VALID_FOR_HTTP()">
519
<a name="SOUP-URI-VALID-FOR-HTTP:CAPS"></a><h3>SOUP_URI_VALID_FOR_HTTP()</h3>
520
<pre class="programlisting">#define SOUP_URI_VALID_FOR_HTTP(uri) ((uri) && ((uri)->scheme == SOUP_URI_SCHEME_HTTP || (uri)->scheme == SOUP_URI_SCHEME_HTTPS) && (uri)->host && (uri)->path)
523
Tests if <em class="parameter"><code>uri</code></em> is a valid <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> for HTTP communication; that is, if
524
it can be used to construct a <a class="link" href="SoupMessage.html" title="SoupMessage"><span class="type">SoupMessage</span></a>.
526
<div class="variablelist"><table border="0">
527
<col align="left" valign="top">
530
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
531
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
535
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
536
<td> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if <em class="parameter"><code>uri</code></em> is a valid "http" or "https" URI.
542
<p class="since">Since 2.24</p>
545
<div class="refsect2" title="soup_uri_set_scheme ()">
546
<a name="soup-uri-set-scheme"></a><h3>soup_uri_set_scheme ()</h3>
547
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_scheme (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
548
<em class="parameter"><code>const <span class="type">char</span> *scheme</code></em>);</pre>
550
Sets <em class="parameter"><code>uri</code></em>'s scheme to <em class="parameter"><code>scheme</code></em>. This will also set <em class="parameter"><code>uri</code></em>'s port to
551
the default port for <em class="parameter"><code>scheme</code></em>, if known.
553
<div class="variablelist"><table border="0">
554
<col align="left" valign="top">
557
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
558
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
562
<td><p><span class="term"><em class="parameter"><code>scheme</code></em> :</span></p></td>
570
<div class="refsect2" title="soup_uri_set_user ()">
571
<a name="soup-uri-set-user"></a><h3>soup_uri_set_user ()</h3>
572
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_user (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
573
<em class="parameter"><code>const <span class="type">char</span> *user</code></em>);</pre>
575
Sets <em class="parameter"><code>uri</code></em>'s user to <em class="parameter"><code>user</code></em>.
577
<div class="variablelist"><table border="0">
578
<col align="left" valign="top">
581
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
582
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
586
<td><p><span class="term"><em class="parameter"><code>user</code></em> :</span></p></td>
587
<td>the username, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
594
<div class="refsect2" title="soup_uri_set_password ()">
595
<a name="soup-uri-set-password"></a><h3>soup_uri_set_password ()</h3>
596
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_password (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
597
<em class="parameter"><code>const <span class="type">char</span> *password</code></em>);</pre>
599
Sets <em class="parameter"><code>uri</code></em>'s password to <em class="parameter"><code>password</code></em>.
601
<div class="variablelist"><table border="0">
602
<col align="left" valign="top">
605
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
606
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
610
<td><p><span class="term"><em class="parameter"><code>password</code></em> :</span></p></td>
611
<td>the password, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
618
<div class="refsect2" title="soup_uri_set_host ()">
619
<a name="soup-uri-set-host"></a><h3>soup_uri_set_host ()</h3>
620
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_host (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
621
<em class="parameter"><code>const <span class="type">char</span> *host</code></em>);</pre>
623
Sets <em class="parameter"><code>uri</code></em>'s host to <em class="parameter"><code>host</code></em>.
626
If <em class="parameter"><code>host</code></em> is an IPv6 IP address, it should not include the brackets
627
required by the URI syntax; they will be added automatically when
628
converting <em class="parameter"><code>uri</code></em> to a string.
630
<div class="variablelist"><table border="0">
631
<col align="left" valign="top">
634
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
635
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
639
<td><p><span class="term"><em class="parameter"><code>host</code></em> :</span></p></td>
640
<td>the hostname or IP address, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
647
<div class="refsect2" title="soup_uri_set_port ()">
648
<a name="soup-uri-set-port"></a><h3>soup_uri_set_port ()</h3>
649
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_port (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
650
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> port</code></em>);</pre>
652
Sets <em class="parameter"><code>uri</code></em>'s port to <em class="parameter"><code>port</code></em>. If <em class="parameter"><code>port</code></em> is 0, <em class="parameter"><code>uri</code></em> will not have an
653
explicitly-specified port.
655
<div class="variablelist"><table border="0">
656
<col align="left" valign="top">
659
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
660
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
664
<td><p><span class="term"><em class="parameter"><code>port</code></em> :</span></p></td>
672
<div class="refsect2" title="soup_uri_set_path ()">
673
<a name="soup-uri-set-path"></a><h3>soup_uri_set_path ()</h3>
674
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_path (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
675
<em class="parameter"><code>const <span class="type">char</span> *path</code></em>);</pre>
677
Sets <em class="parameter"><code>uri</code></em>'s path to <em class="parameter"><code>path</code></em>.
679
<div class="variablelist"><table border="0">
680
<col align="left" valign="top">
683
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
684
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
688
<td><p><span class="term"><em class="parameter"><code>path</code></em> :</span></p></td>
696
<div class="refsect2" title="soup_uri_set_query ()">
697
<a name="soup-uri-set-query"></a><h3>soup_uri_set_query ()</h3>
698
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_query (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
699
<em class="parameter"><code>const <span class="type">char</span> *query</code></em>);</pre>
701
Sets <em class="parameter"><code>uri</code></em>'s query to <em class="parameter"><code>query</code></em>.
703
<div class="variablelist"><table border="0">
704
<col align="left" valign="top">
707
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
708
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
712
<td><p><span class="term"><em class="parameter"><code>query</code></em> :</span></p></td>
720
<div class="refsect2" title="soup_uri_set_query_from_form ()">
721
<a name="soup-uri-set-query-from-form"></a><h3>soup_uri_set_query_from_form ()</h3>
722
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_query_from_form (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
723
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Hash-Tables.html#GHashTable"><span class="type">GHashTable</span></a> *form</code></em>);</pre>
725
Sets <em class="parameter"><code>uri</code></em>'s query to the result of encoding <em class="parameter"><code>form</code></em> according to the
726
HTML form rules. See <a class="link" href="libsoup-2.4-HTML-Form-Support.html#soup-form-encode-hash" title="soup_form_encode_hash ()"><code class="function">soup_form_encode_hash()</code></a> for more information.
728
<div class="variablelist"><table border="0">
729
<col align="left" valign="top">
732
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
733
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
737
<td><p><span class="term"><em class="parameter"><code>form</code></em> :</span></p></td>
738
<td>a <a href="http://library.gnome.org/devel/glib/unstable/glib-Hash-Tables.html#GHashTable"><span class="type">GHashTable</span></a> containing HTML form information
745
<div class="refsect2" title="soup_uri_set_query_from_fields ()">
746
<a name="soup-uri-set-query-from-fields"></a><h3>soup_uri_set_query_from_fields ()</h3>
747
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_query_from_fields (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
748
<em class="parameter"><code>const <span class="type">char</span> *first_field</code></em>,
749
<em class="parameter"><code>...</code></em>);</pre>
751
Sets <em class="parameter"><code>uri</code></em>'s query to the result of encoding the given form fields
752
and values according to the * HTML form rules. See
753
<a class="link" href="libsoup-2.4-HTML-Form-Support.html#soup-form-encode" title="soup_form_encode ()"><code class="function">soup_form_encode()</code></a> for more information.
755
<div class="variablelist"><table border="0">
756
<col align="left" valign="top">
759
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
760
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
764
<td><p><span class="term"><em class="parameter"><code>first_field</code></em> :</span></p></td>
765
<td>name of the first form field to encode into query
769
<td><p><span class="term"><em class="parameter"><code>...</code></em> :</span></p></td>
770
<td>value of <em class="parameter"><code>first_field</code></em>, followed by additional field names
771
and values, terminated by <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.
778
<div class="refsect2" title="soup_uri_set_fragment ()">
779
<a name="soup-uri-set-fragment"></a><h3>soup_uri_set_fragment ()</h3>
780
<pre class="programlisting"><span class="returnvalue">void</span> soup_uri_set_fragment (<em class="parameter"><code><a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a> *uri</code></em>,
781
<em class="parameter"><code>const <span class="type">char</span> *fragment</code></em>);</pre>
783
Sets <em class="parameter"><code>uri</code></em>'s fragment to <em class="parameter"><code>fragment</code></em>.
785
<div class="variablelist"><table border="0">
786
<col align="left" valign="top">
789
<td><p><span class="term"><em class="parameter"><code>uri</code></em> :</span></p></td>
790
<td>a <a class="link" href="libsoup-2.4-SoupURI.html#SoupURI" title="SoupURI"><span class="type">SoupURI</span></a>
794
<td><p><span class="term"><em class="parameter"><code>fragment</code></em> :</span></p></td>
805
Generated by GTK-Doc V1.14</div>
b'\\ No newline at end of file'