Contents Up Previous Next Web Site Home Page

~ Arctan Computer Ventures'  WordPuzzle Pro ~

WebScripts - Exporting for the Wordwide Web

A good medium for distributing your creations is the Word Wide Web. By placing your puzzles on the Internet via a Web Site, billions of people have the potential of seeing your work! Most Internet Service Providers provide some free Web Space for you to dabble with. Many will host a dedicated domain for very little cost. And with batch registrars such as EasySpace, you can now set up a domain very cheaply - so long as it hasn't gone already!

WordPuzzle Pro makes the process very easy for you. You can produce a web page from your puzzle at the click of a button. It's then up to you to place the web page onto your web site. There are many easy-to-use FTP programs around that will make this process a breeze. Ask your ISP for advice. A future version of WordPuzzle Pro may include an inbuilt FTP option - watch this space! 

With the introduction of a new facility called WebScripts, you can produce web pages in two different formats - fixed, and interactive. The fixed format uses straight HTML to produce static web pages with the content you require. You can then customize the page under preset categories according to how you want it to look. The interactive format uses JavaScript that dynamically generates HTML frames so that you have a crossword that can be completed dynamically by the user - a bit like completing the crossword within WordPuzzle Pro itself, although somewhat simplified - and it works using most modern browsers - so the puzzler doesn't even need the program to interactively complete the puzzle!

WebScripts are text files that give the bare bones HTML on which a page is based, with embedded commands that link into WordPuzzle Pro. Thus, if you are a proficient JavaScripter or HTML designer, you might want to dabble in creating your own WebScripts - go ahead! Do note however, that the two provided scripts are copyrighted to Arctan Computer Ventures, and should not be altered or redistributed - except to tweak for your own uses. Note, that the copyright and identifying information should never be remove from the generated HTML files, nor the permanent link to the WordPuzzle Pro home page - it's small and unobtrusive, so shouldn't bother most people.

Sections
Basic Export Operation
Customization using Parameters
WebScripts - Template & Results Screens
More About HTML Export
More About JavaScript Export
Basic Export Operation From the Grid screen, click on the Puzzle menu and click on the WWW Script Generator... option. A window appears entitled Export to Web Document...

To close this window again, click on the Close button (situation in the top right hand corner of the window).

Towards the top of the window, there are four headings, situation on four folder tabs. These are:-

Export Options: Basic customizations, such as location of templates, which template to apply, and the locations of the created document and linked images. Also buttons to generate / view the document.
Template Parameters: Customizations specific to the chosen template, such a colours, whether to include certain facilities, plus any information generated by WordPuzzle Pro that is to be inserted into the WebScript in order to generate the given document. These are categorised for easy access.
Script: The original script is displayed for your information (prior to processing). You can edit the script from here too.
Results: The script after processing has been applied (based on the template parameters). This is the result that will be stored as a web document.

Taking the Export Options section, the screen is split into four groups.

The top group, headed Template Information, gives the location of the templates, which is (by default) the webscript directory under the installation directory. You can click on the ... button next to the directory to select another directory, but this is generally unnecessary.

Next to the Template heading, JavaScript Crossword Template with Frames is selected. The drop-down edit box shows all valid templates within the current directory. Normally, the only other option is Standard HTML crossword template. To set the current template to be the default one to use for all puzzles (stored in registry), click on the Set Default Template button.

The next group, headed Output Locations, identifies the place where the resulting web page is to be stored. As default, this is the output directory under the installation directory, and a file called eg.htm

The Graphics Path (Rel) edit box shows the relative location where images will be copied out of the puzzle. If blank, graphics files will be stored in the same location as the main web document. You can choose another directory either by typing a relative reference, or by using the ... button to select a directory using a dialog box. You may wish to convert pictures in your puzzle to JPEGs before you continue, as this is the standard format for Web graphics, and can often considerably reduce the size of image files.

The third group down, headed Other Options, gives other miscellaneous options. These are stored with your puzzle. The Use Color names where available checkbox means that when a colour used within the puzzle matches one of the standard colours as defined in NetScape Navigator, the English version will be used rather than the coded RGB version - e.g. Black will show as black rather than #000000. This improves readability, but some browsers may not understand all colours.

The save overrides with puzzle option indicates that anything that you change under the Template Parameters tab (i.e. provide an override value), will be stored with the puzzle, so that they are retained next time you use the WebScript section.

The bottom-most section contains two buttons. The left-most button will generate the script and images (if appropriate), stored to the indicated file.

The right-most button will do the same, and then launch the currently registered browser to show the newly created document, ready for you try.

Customization Using Parameters The second tab, labelled Template Parameters contains a list of parameters that you can alter to customize the results to your requirements.

The parameters are categorized according to their function. Choose a category from the drop-down list marked Parameter Categories:-, and a list of parameters will be displayed.

Click on one of the parameter names, and you will see a description of the parameter pop-up as a tool-tip. In the section at the bottom of the screen, the default value for the parameter (as defined either by the script or by the program according to how your puzzle is set-up) is shown in a non-editable text box marked Parameter Default. A box below this shows the overridden value, next to a title Parameter Override. In order to override a parameter, click on the tick-box to the left of its name in the list.

If the parameter is either text or a number, type the value in the text box.

If the parameter is a True/False type of parameter, then you will need to enable or disable the option by clicking on the displayed check-box.

If the parameter is a color, you can type the name or code for the color in the text box, choose a standard colour from the drop-down list-box, or click on the colour box in order to show a pop-up colour picker, from where you can select your required colour.

If the parameter is an image, you can type the name of the image in the text box, which must match the name of an image contained in the image organizer. Alternatively, if you click in the space to the right of the edit box, the image organizer will be displayed, and you can pick an image, and the name will be filled into the text box automatically for you.

The customizations are many and varied. The first example puzzle puzz001.xwd is a good example of a customized JavaScript crossword. It may be worth looking at this for an example of customization.

WebScripts - Template & Results Screens The Template section shows the text of the selected script in a read-only box. If you wish to edit a script (making sure you do not invalidate the copyright requirements), you can right-click over the box, and choose the Edit Script File option. The script file will be opened in a full-screen window using the notepad text editor, as bundled with the Windows operating system.

If you wish to see the results after the parameters have been applied to the template, click on the Results tab. This has no equivalent edit function, as at this stage, the results may not have been saved to a file.

More About HTML Export The Standard HTML Crossword Template is used when you want a static, possibly printable HTML text page for inclusion on your web site. Although not as snazzy as a dynamic JavaScript crossword, this type of template is easier to look at, easy to print out, and works with a wider range of browsers. It may be a good idea to include both types of puzzle on your web site for safety's sake!

The most important settings can be found under the about category for information. Note that the title parameter is used to internally identify the script, and is often used by search engines, whereas the heading parameter will be actually displayed on the page.

The colors and images section gives a list of items on the page that can be altered in terms of background images and colours.

The settings category gives some basic items that can be switched on and off in the puzzle - e.g. different sections such as sets of clues, hints, explanations, bars etc.

The specs section can generally be ignored, as it is mainly used by the application for internal processing.

The URLs section show links to other pages that can be incorporated on the page.

More About JavaScript Export The JavaScript Crossword Template With Frames is an interactive version of your puzzle that will work with most modern browsers. The user can fill in an empty crossword grid with what they think are the correct answers using dynamically using a standard web browser. They can obtain hints and explanations if they are available, and incorrect letters can be coloured differently if required. All this is generated automatically for you. If you don't want to include some facilities, or slightly alter the look of the puzzle, you can alter a number of parameters to achieve much.

The JavaScript parameters have the same categories, although slightly different parameters, to the straight HTML script. One addition category is the clue details category, which lists the clues, hints etc.  in a comma-separated list. You can override this if you like, although this is generally not necessary.

(c) Copyright 2000-1 Arctan Computer Ventures Ltd.   All Rights Reserved.
If you have any issues regarding this on-line help, please contact the author by clicking here.
This Page was last updated: 06 July 2001 23:35