git: de065e22f8 - main - man.cgi: improve error message for empty inputs or wrong queries
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 06 Sep 2026 14:23:53 UTC
The branch main has been updated by wosch:
URL: https://cgit.FreeBSD.org/doc/commit/?id=de065e22f83c2ad4e06c8759c094186d3cd4a736
commit de065e22f83c2ad4e06c8759c094186d3cd4a736
Author: Wolfram Schneider <wosch@FreeBSD.org>
AuthorDate: 2026-09-06 14:23:16 +0000
Commit: Wolfram Schneider <wosch@FreeBSD.org>
CommitDate: 2026-09-06 14:23:16 +0000
man.cgi: improve error message for empty inputs or wrong queries
Event: Berlin Hackathon 202609
---
website/content/en/cgi/man.cgi | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/website/content/en/cgi/man.cgi b/website/content/en/cgi/man.cgi
index e0bb8fddcb..3a74516c1f 100755
--- a/website/content/en/cgi/man.cgi
+++ b/website/content/en/cgi/man.cgi
@@ -1758,9 +1758,13 @@ sub apropos {
close(APROPOS);
if ( !$acounter ) {
- print "Sorry, no data found for `$query'.\n";
- print qq{You may look for other }
- . qq{<a href="https://www.freebsd.org/search/">FreeBSD Search Services</a>.<br/><br/>\n};
+ if ($query eq '') {
+ print "<hr/>Empty input. Please type a manual page and search again.\n<hr/>\n";
+ } else {
+ print "Sorry, no data found for `$query'.\n";
+ print qq{You may look for other }
+ . qq{<a href="https://www.freebsd.org/search/">FreeBSD Search Services</a>.<br/><hr/>\n};
+ }
}
&html_footer;
}
@@ -1972,7 +1976,7 @@ sub man {
print
qq{Please try a <a href="$BASE?apropos=1&manpath=freebsd-release-ports&query=$html_name">keyword search</a>.\n};
print qq{<p>You may look for other }
- . qq{<a href="https://www.freebsd.org/search/">FreeBSD Search Services</a>.</p>\n};
+ . qq{<a href="https://www.freebsd.org/search/">FreeBSD Search Services</a>.</p><hr/>\n};
&html_footer;
return;
}