Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Gopher (protocol)
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
====Item types==== In a Gopher menu's source code, a one-character code indicates what kind of content the client should expect. This code may either be a digit or a letter of the alphabet; letters are [[case-sensitive]]. The [[technical specification]] for Gopher, {{IETF RFC|1436}}, defines 14 item types. The later gopher+ specification defined an additional 3 types.<ref>{{cite web |title=Gopher+ protocol specification |url=https://github.com/jgoerzen/pygopherd/blob/master/doc/standards/Gopher%2B.txt |publisher=[[GitHub]]}}</ref> A one-character code indicates what kind of content the client should expect. Item type {{code|3}} is an [[error code]] for [[exception handling]]. Gopher client authors improvised item types {{code|h}} (HTML), {{code|i}} (informational message), and {{code|s}} ([[sound file]]) after the publication of RFC 1436. Browsers like Netscape Navigator and early versions of Microsoft Internet Explorer would prepend the item type code to the selector as described in {{IETF RFC|4266}}, so that the type of the gopher item could be determined by the url itself. Most gopher browsers still available, use these prefixes in their urls. {| class="wikitable" ! colspan="2" {{partial|Canonical types}} |- | {{okay|'''0'''}} || [[Text file]] |- | {{okay|'''1'''}} || Gopher submenu |- | {{okay|'''2'''}} || [[CCSO Nameserver]] |- | {{okay|'''3'''}} || Error code returned by a Gopher server to indicate failure |- | {{okay|'''4'''}} || [[BinHex]]-encoded file (primarily for [[Macintosh]] computers) |- | {{okay|'''5'''}} || [[DOS]] file |- | {{okay|'''6'''}} || [[uuencoded]] file |- | {{okay|'''7'''}} || Gopher [[full-text search]] |- | {{okay|'''8'''}} || [[Telnet]] |- | {{okay|'''9'''}} || [[Binary file]] |- | {{okay|'''+'''}} || Mirror or alternate server (for [[Load balancing (computing)|load balancing]] or in case of primary server [[downtime]]) |- | {{okay|'''g'''}} || [[GIF]] file |- | {{okay|'''I'''}} || [[Image file]] |- | {{okay|'''T'''}} || [[Telnet 3270]] |- ! colspan="2" {{partial|gopher+ types}} |- | {{okay|''':'''}} || [[Bitmap|Bitmap image]] |- | {{okay|''';'''}} || [[Video file format|Movie file]] |- | {{okay|'''<'''}} || [[Audio file format|Sound file]] |- ! colspan="2" {{unofficial|Non-canonical types}} |- |style="background:#adffe6; text-align:center" | '''d''' || Doc. Seen used alongside PDF and .doc files |- | style="background:#adffe6; text-align:center" | '''h''' || [[HTML]] file |- | style="background:#adffe6; text-align:center" | '''i''' || Informational message, widely used.<ref>{{cite web|url=https://sunriseprogrammer.blogspot.com/2019/03/directory-entry-says-what-current.html|title=Directory entry says what? Current Gopher type field types|date=5 March 2019}}</ref> |- | style="background:#adffe6; text-align:center" | '''p''' || image file "(especially the [[Portable Network Graphics|PNG]] format)" |- | style="background:#adffe6; text-align:center" | '''r''' || document RTF file ("[[Rich Text Format]]") |- | style="background:#adffe6; text-align:center" | '''s''' || [[Sound file]] (especially the [[WAV]] format) |- | style="background:#adffe6; text-align:center" | '''P''' || [[PDF]] (Portable Document Format) file |- | style="background:#adffe6; text-align:center" | '''X''' || [[XML]] (Extensible Markup Language) file |} Here is an example gopher session where the user requires a gopher menu ({{code|/Reference}} on the first line): <pre> /Reference 1CIA World Factbook /Archives/mirrors/textfiles.com/politics/CIA gopher.quux.org 70 0Jargon 4.2.0 /Reference/Jargon 4.2.0 gopher.quux.org 70 + 1Online Libraries /Reference/Online Libraries gopher.quux.org 70 + 1RFCs: Internet Standards /Computers/Standards and Specs/RFC gopher.quux.org 70 1U.S. Gazetteer /Reference/U.S. Gazetteer gopher.quux.org 70 + iThis file contains information on United States fake (NULL) 0 icities, counties, and geographical areas. It has fake (NULL) 0 ilatitude/longitude, population, land and water area, fake (NULL) 0 iand ZIP codes. fake (NULL) 0 i fake (NULL) 0 iTo search for a city, enter the city's name. To search fake (NULL) 0 ifor a county, use the name plus County -- for instance, fake (NULL) 0 iDallas County. fake (NULL) 0 </pre> The gopher menu sent back from the server, is a sequence of lines each of which describes an item that can be retrieved. Most clients will display these as [[hypertext]] links, and so allow the user to navigate through gopherspace by following the links.<ref name="wwwunleashed"/> This menu includes a text resource (itemtype {{code|0}} on the third line), multiple links to submenus (itemtype {{code|1}}, on the second line as well as lines 4β6) and a non-standard information message (from line 7 on), broken down to multiple lines by providing dummy values for selector, host and port.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)