Design and Implementation

In JavaScript there are 3 ways to get the result of a function call to print on the monitor, and you've seen two; before the page is created, as you saw the alert call, and interactively after the page is displayed, as with conversions.

Improving memory bank webpage

The memory bank web page is useful, but it needs to be a fancier and include some other cool features, in this section we program the memory bank page to splash mew pages onto a screen.
Opening a new window differs from linking to a new home page. Because a link replaces the page being displayed, while the new window allows both to be displayed. It's very easy to open a new
window and it's handy if we want a page to remain on the screen even when the memory bank page is closed.

Splashing a new page

A memory bank page that may have two rows, will differ from the rows on other memory banks m they may have a title on the left or right, depending on design. When a user clicks on the bottom a new
page is displayed. It's easy to get a new page to display; all we need to do is open it. In order to open a page we must give the location of the page just as if we were using a <a href=...> or <img src.../> as shown.

isNaN(value)

The isNaN() function determines whether a value is an illegal number (Not-a-Number).
This function returns true if the value is NaN, and false if not. IsNan

Although colour is normally taken care of using Cascading Style Sheets (CSS), HTML does allow you to specify colours as element attributes when using the Transitional DTD. The most common way of doing this is using a <font> ... </font> tag.
This allows you to affect the way in which the text in-between the tags is displayed. adding a "color" attribute to it allows you to change its colour (note the American spelling in the attribute name).

A counting Page

It is common when searching for things or watching sports to keep track of count. It's easy to get a scrap of paper and tally numbers, but is equally easy to click a mouse.
So we write the counter assistant application. Clicking on the count button increments the total field;
the meaning field can be filled with any text to remind us which counter is which among several.
A counter assistant page uses an interesting approach, it writes a function to create a row of the table, placing the entire XHTML. Text in the function.
The strategy to use a sequence of document. write ( ) functions..

Final touches to memory bank

ADD note - the date can be added at the top after the red motto text, centred. JavaScript which gives us many ways to manipulate dates, but here we use the date
only as a function. We could write a function to insert the date into html document but it is a single line so we write code.
<scripts type = 'text/JavaScript> Document. write('<p>' + (date().to string()) + '</p>')

Add web link

Our memory bank page has concentrated on programming computations, but it's a web page, so we can include useful links too.
These links are probably bookmarked in your browser, but by placing them in the memory bank page, they
are available even when you're using a different computer or browser. The links should be anything useful
like an online dictionary and thesaurus for writing term papers, or a link to the fluency class home page
The links should be either in a column or in a table, placing one link per row. Because the links are highlighted with a different colour, they would appear to be in their own column. An alternative is to add another row at the bottom which spans both columns and fill it with the links, it might be more presentable.
IsNan

Back To Top