Welcome! Log In Create A New Profile

Advanced

Re: [PATCH 1 of 2] Enhanced website navigation with 2-level menu and directive search

Liam Crilly via nginx-devel
August 30, 2022 08:54AM
# HG changeset patch
# User Liam Crilly <liam.crilly@nginx.com>
# Date 1659696328 -3600
# Fri Aug 05 11:45:28 2022 +0100
# Node ID 1087570ec093271d10de8e901122c99003a79b6d
# Parent 60851da88db689f3bfaa54453977ec9803b00509
Added search box to navigate directly to directive or variable docs.

This patch adds a search box below the logo as a shortcut to constructing a
nginx.org/r/... URI. Directive names and variables can be entered here.
A corresponding location block is required in nginx.conf:
location = /s {
rewrite ^ /r/$arg_q;
}

diff -r 60851da88db6 -r 1087570ec093 dtd/content.dtd
--- a/dtd/content.dtd Tue Jul 19 16:53:15 2022 +0100
+++ b/dtd/content.dtd Fri Aug 05 11:45:28 2022 +0100
@@ -147,6 +147,21 @@
versions CDATA #IMPLIED
>

+<!ELEMENT form (form+) >
+<!ATTLIST form
+ action CDATA #IMPLIED
+ method CDATA #IMPLIED
+ id CDATA #IMPLIED
+>
+
+<!ELEMENT input (input+) >
+<!ATTLIST input
+ type CDATA #IMPLIED
+ name CDATA #IMPLIED
+ size CDATA #IMPLIED
+ value CDATA #IMPLIED
+>
+
<!ENTITY nbsp "&#160;">
<!ENTITY times "&#215;">
<!ENTITY lsquo "&#8216;">
diff -r 60851da88db6 -r 1087570ec093 xsls/body.xsls
--- a/xsls/body.xsls Tue Jul 19 16:53:15 2022 +0100
+++ b/xsls/body.xsls Fri Aug 05 11:45:28 2022 +0100
@@ -29,6 +29,14 @@
</a>
</h1>
<div>
+ directive/variable search
+ <form action="/s" method="GET">
+ <input type="text" name="q" size="14"></input>
+ <input type="submit" value="go"></input>
+ </form>
+ <br/>
+ </div>
+ <div>
!! "document(concat($XML, '/menu.xml'))
/menus/menu[@lang = $lang]/item";
</div>
_______________________________________________
nginx-devel mailing list -- nginx-devel@nginx.org
To unsubscribe send an email to nginx-devel-leave@nginx.org
Subject Author Views Posted

Re: [PATCH 1 of 2] Enhanced website navigation with 2-level menu and directive search

Liam Crilly via nginx-devel 203 August 30, 2022 08:54AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 92
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready