Index: src/yelp-window.c
===================================================================
--- src/yelp-window.c	(revision 3159)
+++ src/yelp-window.c	(working copy)
@@ -1817,7 +1817,7 @@
 	gtk_tree_model_get (model, &iter,
 			    YELP_DOCUMENT_COLUMN_ID, &id,
 			    -1);
-	uri = g_strdup_printf ("%s#%s", priv->base_uri, id);
+	uri = g_strdup_printf ("%s?%s", priv->base_uri, id);
 	yelp_window_load (window, uri);
 	g_free (uri);
     }
@@ -2727,7 +2727,7 @@
     
     /* Use a silly fake URI to stop gecko doing silly things */
     if (data->window->priv->current_frag)
-	uri = g_strdup_printf ("%s#%s", data->window->priv->base_uri, 
+	uri = g_strdup_printf ("%s?%s", data->window->priv->base_uri, 
 			       data->window->priv->current_frag);
     else
 	uri = g_strdup (data->window->priv->base_uri);
Index: src/yelp-html.c
===================================================================
--- src/yelp-html.c	(revision 3159)
+++ src/yelp-html.c	(working copy)
@@ -77,10 +77,13 @@
     debug_print (DB_FUNCTION, "entering\n");
     debug_print (DB_ARG, "  uri = \"%s\"\n", uri);
 
+    g_print ("  uri = \"%s\"\n", uri);
 
 
-    if (uri[0] == '#') {
-	gchar *hash = g_strrstr (html->priv->base_uri, "#");
+
+#if 0
+    if (uri[0] == '?') {
+	gchar *hash = g_strrstr (html->priv->base_uri, "?");
 	if (hash) {
 	    gchar *tmp = g_strndup (html->priv->base_uri, 
 				    (hash - html->priv->base_uri));
@@ -93,6 +96,9 @@
     } else {
 	real_uri = g_strdup (uri);
     }
+#endif
+	real_uri = g_strdup (uri);
+
     
     if (!html->priv->frames_enabled) {
   	g_signal_emit (html, signals[URI_SELECTED], 0, real_uri, FALSE);
@@ -359,13 +365,14 @@
 	webkit_web_view_set_maintains_back_forward_list (WEBKIT_WEB_VIEW (html), FALSE);
     }
 
+    g_print("Content: \n%s\n^Base: '%s'\n\n", html->priv->content, html->priv->base_uri);
     /* TODO: Broken navigation requests: */
     /* See https://bugs.webkit.org/show_bug.cgi?id=19360 */
     webkit_web_view_load_string (WEBKIT_WEB_VIEW (html),
 				 html->priv->content,
 				 html->priv->mime,
 				 NULL,
-				 "foo");
+				 html->priv->base_uri);
     g_free (html->priv->content);
     html->priv->content = NULL;
     g_free (html->priv->mime);
Index: stylesheets/db2html.xsl.in
===================================================================
--- stylesheets/db2html.xsl.in	(revision 3159)
+++ stylesheets/db2html.xsl.in	(working copy)
@@ -66,10 +66,24 @@
 </xsl:template>
 
 <!-- == db.xref.target == -->
+<!--
 <xsl:template name="db.xref.target">
   <xsl:param name="linkend"/>
   <xsl:value-of select="concat('#', $linkend)"/>
 </xsl:template>
+-->
+<xsl:template name="db.xref.target">
+  <xsl:param name="linkend"/>
+  <xsl:param name="is_chunk"/>
+    <xsl:choose>
+      <xsl:when test="$is_chunk">
+  			<xsl:value-of select="concat('?', $linkend)"/>
+      </xsl:when>
+      <xsl:otherwise>
+  			<xsl:value-of select="concat('#', $linkend)"/>
+      </xsl:otherwise>
+    </xsl:choose>
+</xsl:template>
 
 <!-- == db2html.css.custom == -->
 <xsl:template name="db2html.css.custom">
