1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371
|
<!doctype html public "-//W3C//DTD HTML 3.2 Final//EN">
<html>
<head>
<title>Creating User Home Pages for the WN Server</title>
<link rev="made" href="mailto:john@math.nwu.edu">
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
<meta http-equiv="last-modified" content="Fri, 09 Oct 1998 18:18:09 GMT">
<meta http-equiv="keywords" content="user home pages">
</head>
<body bgcolor="#FFFFFF">
<p>
<a href="http://hopf.math.nwu.edu/"><img
src="images/powered.jpg"
border="0"
width="190"
height="41"
align="right"
alt="WN home page"
></a>
</p>
<strong>Version 2.0.3</strong>
<br>
<!-- pnuts --> <a href="appendixD.html">[Previous]</a> <a href="appendixF.html">[Next]</a> <a href="manual.html">[Up]</a> <a href="manual.html">[Top]</a> <a href="dosearch.html">[Search]</a> <a href="docindex.html">[Index]</a>
<br clear="right">
<hr size="4">
<!-- #start -->
<h2 align="center">Creating User Home Pages for the <em>WN</em>
Server</h2>
<hr size="4">
<p>
This document is for the ordinary user, not the system "webmaster". It
is intended as a short description of how to use the <em>WN</em> server
to set up your home page (and related documents if you wish). It is not
a primer on writing HTML. There are many of those -- <a
href="#html">some are listed below</a>. Instead it deals with what to do
with a home page document after it is created to put it "on the Web". We
assume that your system administrator has already set up the <em>WN</em>
server in such a way that users are permitted to have home pages in their
own directories. If that isn't the case you will have to persuade your
local administrator to do so or read the full "<a
href="manual.html">User's Guide for the <em>WN</em> Server</a>" to learn
how to do it yourself.
</p>
<h3>E.1 <a name="starting">Getting Started</a></h3>
<p>
But let's be optimistic and suppose everything is set up and working
properly. If you haven't created a home page here is a bare bones one
you can copy to expand on later:
</p>
<blockquote>
<code>
<!doctype html public "-//W3C//DTD HTML 3.2 Final//EN">
<br>
<head>
<br>
<title>John Doe's Home Page</title>
<br>
</head>
<br>
<body>
<br>
<h1>John Doe's Home Page</h1>
<br>
<br>
<p>
<br>
This is the story of my life...
<br>
</p>
<br>
</body>
</code>
</blockquote>
<p>
Your home page and any other files you want to serve must be located in
a particular subdirectory of your home directory (your home directory is
where you are when you first login) on the UNIX system which is running
the <em>WN</em> server. Usually this subdirectory is called
<code>public_html</code>, but your system webmaster may have chosen
something different. We'll assume the name is <code>public_html</code>.
</p>
<p>
It probably doesn't yet exist in your home directory. If not create it
with the command:
</p>
<blockquote>
<code>
mkdir public_html<Enter>
</code>
</blockquote>
<p>
The <code>public_html</code> directory also must have the correct
"permissions" so that the server can look inside it. For security
reasons the <em>WN</em> server isn't very powerful and it can only
access files and directories which are not heavily protected. Just to
make sure the server won't have trouble accessing your home page run the
command:
</p>
<blockquote>
<code>
chmod 755 public_html<Enter>
</code>
</blockquote>
<p>
You must place a copy of your home page in this directory and give it
the name <code>index.html</code>. One way to do this is enter the
<code>public_html</code> directory and use an editor to create the home
page file there with the name <code>index.html</code>. Alternatively,
you could create it elsewhere and copy it to the
<code>public_html</code> directory. If you need to rename it the proper
UNIX command is:
</p>
<blockquote>
<code>
mv oldname newname<Enter>
</code>
</blockquote>
<p>
Of course the server must also be able to read your home page in order
to serve it. If documents you create are automatically protected from
viewing by others you will have to change that for your home page. The
command:
</p>
<blockquote>
<code>
chmod 644 index.html<Enter>
</code>
</blockquote>
<p>
gives anyone (including the server) permission to read but not change
your home page.
</p>
<h3>E.2 <a name="security">Granting Access to Your Home Page</a></h3>
<p>
There is one more step before your home page is available to the world.
The <em>WN</em> server is very security conscious. It is much more
careful about refusing to serve documents which users did not intend to
be served. This means that in addition to serving only documents in
designated directories (such as your "<code>public_html</code>") it will
only serve documents which have been explicitly designated for serving
in some way.
</p>
<p>
Here are two different ways to grant the server permission to serve your
home page. You only need to do one of these.
</p>
<h4>E.2.1 <a name="security.lazy">A Lazy Way</a></h4>
<p>
Create a file in the <code>public_html</code> directory named
<code>index</code> which contains the line:
</p>
<blockquote>
<code>
Attribute=serveall
</code>
</blockquote>
<p>
Then execute the command:
</p>
<blockquote>
<code>
wndex<Enter>
</code>
</blockquote>
<p>
which will create the file "<code>index.cache</code>". It grants the
server permission to serve anything in this directory. If you put
documents to be served in subdirectories of <code>public_html</code>,
copy the file <code>index</code> to them also and rerun
<code>wndex</code> in these subdirectories to grant permission to serve
anything from them (actually the file "<code>index</code>" itself is
excluded from being served as are files beginning with the
'<code>.</code>' character).
</p>
<h4>E.2.2 <a name="security.better">A Better Way</a></h4>
<p>
Create a file in the <code>public_html</code> directory named
<code>index</code> which contains the line:
</p>
<blockquote>
<code>
File=index.html
</code>
</blockquote>
<p>
If you have other files you want to serve add additional lines like
"<code>File=foo.html</code>" where <code>foo.html</code> is the name of
the file you want to serve. Then execute the command:
</p>
<blockquote>
<code>
wndex<Enter>
</code>
</blockquote>
<p>
Files which are HTML files should have names which end with the suffix
"<code>.html</code>". Files which are ASCII text files should end with
"<code>.txt</code>" and GIF image files should end with
"<code>.gif</code>". Executing the "<code>wndex</code>" (pronounced
"windex") command will create the file "<code>index.cache</code>" as
before, but now the server will only have permission to serve those
files whose names are listed explicitly in your <code>index</code> file.
</p>
<p>
If you put documents to be served in subdirectories of
<code>public_html</code>, you must create an <code>index</code> file in
each of them also which lists the files which can be served.
</p>
<p>
The "better way", in addition to providing better security, also enables
many of the advanced features of the <em>WN</em> server, such as
searching capabilities. In the long run if you serve multiple documents
you will probably want to use it. The trade off is that the "lazy" way
is easier since it only needs to be done once, while the "better" way
requires that you edit the <code>index</code> file and rerun
<code>wndex</code> each time you add a new file to
<code>public_html</code> to be served.
</p>
<h3>E.3 <a name="url">What's Your URL?</a></h3>
<p>
So once your home page is functional, how do you access it? Well, your
home page address (called a URL which stands for "Uniform Resource
Locator") is made up from the name of your host and your user name. For
example, if your user name is <code>jdoe</code> and the computer on
which the server is running is named <code>www.school.edu</code> then
the URL for your home page is probably:
</p>
<blockquote>
<code>
http://www.school.edu/~jdoe/
</code>
</blockquote>
<p>
The "probably" refers to the fact that there are many possible variations
which may have been chosen by your webmaster. For example, some people
don't like the '<code>~</code>' character in URL's so they might use
"<code>http://www.school.edu/homepages/jdoe/</code>". In any case there
are a couple of things to notice about your URL.
</p>
<p>
First it has a synonym:
</p>
<blockquote>
<code>
http://www.school.edu/~jdoe/index.html
</code>
</blockquote>
<p>
This is because whenever a URL ends in '<code>/</code>' the server knows
it is referring to a directory (in this case your
<code>public_html</code> directory) and looks for the default file
"<code>index.html</code>" in that directory. Thus if you want to put
some files in subdirectories of <code>public_html</code> that is fine.
But keep in mind that if you create the directory "<code>mydir</code>" in
<code>public_html</code> then
"<code>http://www.school.edu/~jdoe/mydir/</code>" will really refer to
"<code>http://www.school.edu/~jdoe/mydir/index.html</code>" and to refer
to a file "<code>foo.gif</code>" in <code>mydir</code> you should use
"<code>http://www.school.edu/~jdoe/mydir/foo.gif</code>". You should not
use the URL "<code>http://www.school.edu/~jdoe/mydir</code>" referring to
a directory but with no '<code>/</code>' at the end.
</p>
<h3>E.4 <a name="advanced">Advanced Features</a></h3>
<p>
There are many advanced features you can use with the <em>WN</em> server.
To learn to use them you will need to read parts of the <a
href="manual.html">manual</a> designed for system administrators. A good
place to start is the chapter "<a href="overview.html">An Overview of the
<em>WN</em> Server</a>" in this guide. It will give you a good idea of
some of the things the server can do. Then you will likely also want to
consult the chapter "<a href="index_desc.html">Creating Your <em>WN</em>
Data Directory</a>" in this guide. Neither of these chapters is too
long.
</p>
<h3>E.5 <a name="html">HTML References</a></h3>
<p>
To find out more about composing HTML documents consult "<a
href="http://www.ncsa.uiuc.edu/General/Internet/WWW/HTMLPrimer.html">A
Beginner's Guide to HTML</a>" (at
http://www.ncsa.uiuc.edu/General/Internet/WWW/HTMLPrimer.html) or see "<a
href="http://home.netscape.com/home/how-to-create-web-services.html">Creating
Web Sites</a>" (at
http://home.netscape.com/browsers/createsites/index.html). "<a
href="http://www.htmlhelp.com">http://www.htmlhelp.com</a>" is an
excellent site on the various web authoring standards.
</p>
<!-- #end -->
<hr size="4">
<address>
<em>WN</em> version 2.0.3
<br>
Copyright © 1998 <a href="mailto:john@math.nwu.edu">John Franks
<john@math.nwu.edu></a>
<br>
licensed under the <a href="http://www.opencontent.org/opl.html">
OpenContent Public License</a>
<br>
last-modified: Fri, 09 Oct 1998 18:18:09 GMT
</address>
<!-- pnuts --> <a href="appendixD.html">[Previous]</a> <a href="appendixF.html">[Next]</a> <a href="manual.html">[Up]</a> <a href="manual.html">[Top]</a> <a href="dosearch.html">[Search]</a> <a href="docindex.html">[Index]</a>
</body>
</html>
|