Both sides previous revisionPrevious revisionNext revision | Previous revision |
tutorials:gopher [2012/01/28 19:29] – memnon | tutorials:gopher [2012/01/28 19:57] (current) – memnon |
---|
===== Creating your Gopherspace ===== | ===== Creating your Gopherspace ===== |
| |
You can use the command "mkgopher" (after you run it, type "setup" in the line "MKGOPHER>"; you can type help for more details) to create a directory in your $HOME called gopher (This directory is a link to /ftp/pub/users/$USER/ ). On it, you can put all the files you want to be available in your Gopherspace. | You can use the command "mkgopher" (after you run it, type "setup" in the line "MKGOPHER>"; you can type "help" for more details) to create a directory in your $HOME called gopher (This directory is a link to /ftp/pub/users/$USER/ ). On it, you can put all the files you want to be available in your Gopherspace. |
| |
You can use mkgopher to publish documents, create directories, etc. You can also manage your Gopherspace manually. If you decide to do so, remember that the server needs the right permissions to be able to read your content. That is, files need to be group readable (chmod g+r $HOME/gopher/yourfile), directories need also to be group executable (chmod g+rx $HOME/gopher/yourdir), etc. | You can use mkgopher to publish documents, create directories, etc. You can also manage your Gopherspace manually. If you decide to do so, remember that the server needs the right permissions to be able to read your content. That is, files need to be group readable (chmod g+r $HOME/gopher/yourfile), directories need also to be group executable (chmod g+rx $HOME/gopher/yourdir), etc. |
==== Caveat ==== | ==== Caveat ==== |
| |
Besides what was said in the last paragraph of the figlet.cgi example, there's also another thing to stress. In that example, and in content that will be server as a virtual directory (or with an itemtype 1, or 7), won't be displayed if you access your script via floodgap proxy (and maybe others). In this case you will need to format the output of your script. Luckily this is very easy. For instance, in the figlet.cgi example you will need to modify the echo ... line this way: | Besides what was said in the last paragraph of the figlet.cgi example, there's also another thing to stress. In that example (as with anything that will be served as a virtual directory (or with an itemtype 1 or 7), content won't be displayed if you access your script via floodgap proxy (and maybe others). In this case you will need to format the output of your script. Luckily this is very easy. For instance, in the figlet.cgi example you will need to modify the echo ... line this way: |
echo "i$i<TAB><TAB>error.host<TAB>1" | echo "i$i<TAB><TAB>error.host<TAB>1" |
where <TAB> is a tab character (you should already know this!) and error.host and 1 are, respectively, a fake server and port number (you could also have written fake instead of error.host and 300 instead of 1). | where <TAB> is a tab character (you should already know this!) and error.host and 1 are, respectively, a fake server and port number (you could also have written fake instead of error.host and 300 instead of 1). |
| |