Broken links on a website are one of the worst types of errors, which often drive potential users away from the site. To test for broken links, open a Web page on your computer. The Home Page, which usually uses the file name “index.html,” is a good place to start.
Click on the “Window” menu, then “Results” and “Link Checker.” In the Link Checker panel that opens at the bottom of the screen, click on the right-pointing arrow next to “Files.” There are three options: to check the current document, to check links for the entire local site, and to check links for selected files. Unless you have a website with only one page, the best way to go is to choose to check links for the entire site. On complicated sites, which have gone through multiple iterations in development and contain lots of CSS and specialized fonts it is quite likely you will find some broken links. If so, click on the “Save Report” icon at the left of the panel. To review the types of problems quickly, click on “Broken Links” on the “Show” line and select broken links, external links, or orphaned links.
To fix broken links, select one from the list. The name will reduce in size and a folder option pops up on the right. This opens a “Select File” dialog box where you can work through finding the correct file and fixing the broken link. The following image shows some deliberately created broken links for this example.
Only the most painstaking work in website development can avoid inserting a few tag or syntax errors. Dreamweaver CS4 has a Validator tool for testing websites that quickly finds these problems. Use this tool by clicking on the “Edit” menu, then select the “Validator” category. A quicker way to get to this if the panel from above is still open is to click on “Validation.” Click on the right-pointing arrow and choose “Settings.” With either method, by default there will be a checkmark in the HTML 4.0 box. Add any additional areas you want checked, then click “Options.” In options, put checkmarks in the types of reporting you want. Go back to the drop-down menu that included Settings and select what to check—the current document, current website, or selected files. When the check finishes, each error will have a line number and description of the problem. You can find out more about the errors by clicking on the “More Info” button on the left. Save the report as described in the previous section.