10.1 Validating a site
10.1.1 Browser validation
10.1.2 Formal validation
10.2 Publishing
10.2.1 Setting up a site
10.2.2 Uploading
Publishing a site means transferring the site, i.e. the pages, images and stylesheets involved, to a web server from which they may be accessed, usually but not necessarily, by the public. This process is called “Uploading”. Prior to publishing there are a few checks which should be carried out.
Validating simply means checking that the page or site operates as intended. Designers may by now have a plethora of files some of which are obsolete or are not required for the published site. A good practice is to create a new folder structure and in it place those files, and only those files, which are needed.
This can be done using your usual file manager e.g. Windows Explorer but the Nvu File Manager can be set up to do this task by ‘Publishing’ these to a new folder.
Nvu provides a Markup Cleaner Tools > Markup Cleaner which can be used to remove redundant code which clutters the file but does not contribute to the page content. This does not necessarily remove all redundant content but makes a good contribution to it.
The next stage of validation has already been taken care of by Nvu. Users have a high assurance that the code generated represents valid HTML or CSS. The site should next be run using a browser. Possible problems include you having omitted to transfer files to the correct folders, naming the folders incorrectly, including getting the case wrong. It is also possible that, when you linked stylesheets, Nvu used absolute addresses instead of relative addresses (see section 4.2.4.1). Sort these problems out first.
The site should be checked on a range of different browsers. Several modern Mozilla based browsers behave very similarly so do not provide additional confidence. Check with browsers from other sources and be very conscious that a few visitors may still be using very old browsers.
Browsers are often very tolerant of incorrect code. A much more rigorous test is to submit pages to the W3C validators. There are two: one checks that the page code conforms to the HTML specification the second that the style sheet (internal and external linked) code conforms to the CSS specification. Nvu provides direct access to the first of these.
To validate a page. Open it in Nvu. On the Menu choose Tools > Validate HTML. A validator window opens and the page is automatically submitted for validation. The result will be displayed in the window.
To validate pages with internal stylesheets or separate external stylesheets the validators may be used independently. The URLs are given in the References (Appendix 2). Pages may be validated either from the local disk or after the files have been uploaded.
While the W3C validators check rigorously for conformity with specifications this does not guarantee that the code will run correctly. Unfortunately none of the current browsers fully support the specifications! This is why browser validation is an essential step.
You can publish your web pages to a web server on which you have an account. Your ISP probably offers limited free space but you can buy space from profes-sional hosting providers.
To publish a site you need to know the settings for the space so that you can set up your system.
Files may be uploaded using any available FTP program but Nvu has built-in facilities which are integrated with the Site Manager which makes this task very simple.
While setting up Site Manager you may already have configured the ‘remote’ site (sections 8.4 and 8.2), if not, either proceed as detailed there, go directly to Publish Settings via Edit > Publishing Site settings.
If you have several sites set up and you have one site that you always or usually publish to you may wish to click on the name of this site then ‘Set as default’. This simplifies uploading.
Click OK.
Open the page that you want to upload. An easy way to do this is from the Site Manager.
1. Click the PUBLISH button.
2. On the 'Publish Page' window on the 'Publish' tab, if it is not your default, in the 'Site name' box select the site to which you want to publish. The 'Page title' and 'File name' should already be completed.
3. If the page is to be uploaded to a sub-directory, rather than the root directory, enter the name of a sub-directory and any of the other data if required.
Note This directory must exist. Nvu cannot create it.
4.
If it is the first time to upload the page and if it includes images or
uses external style sheets check the box ‘Include images and
other files’. (If it is not the first time and these other
files have not changed the box may be left unchecked.) The files will
be placed in the same directory as the page. If you want them to go in
a sub-directory check the box ‘Use this site
sub-directory’ and name the directory. In this case the
directory will be created if needed.
Note
this is a sub-directory of the root directory not any directory
detailed in the previous point. If you want to use such a directory
this must be explicitly detailed e.g.
pagesubdirectory/filessubdirectory/
Note all the files, e.g. Images and style sheets, will be placed in the same directory. This is the arrangement used by many web sites and is the only arrangement supported by the Site Manager Publisher.
5. You should not need to refer to the 'Settings' tab as the data should be collected via the Site name you have selected but you may view the data and change if you wish.
6.
Click ‘Publish’. A 'Publishing'
window will appear and uploading will commence. (If you are on a
dial-up connection this will be connected.)
7. Within a short time you should receive confirmation of correct publication similar to the first figure.
8. One possible source of problems occurs if you are prevented from accessing the site by a firewall. In this case you may receive a ‘Publishing failed’ message similar to the second figure.
The ‘Troubleshooting’ button takes you to the Nvu help system but this is short of aid in this area at present.
Other possible problems include
Once you have published a page, if you need to publish it again, your settings (e.g. subdirectories) should be remembered by Nvu. You will not see steps 2 to 4 again unless changes have been made to the page.
C’est fini!

Nvu User Guide - Based on Nvu version 0.9 - Updated 01-Apr-2005