Displaying Text Counters
- Inserting a text counter after the sentence "You are visitor number"
at the bottom of your home page.
- Open your home page in a text editor .
- Insert the sentence and mgiCounter tag.
- Save your home page.
- FTP your home page to the web server running MGI.
- View your home page in a browser.
Step 1: Open your home page in a text editor .
- Open your home page in a text editing program that allows you to view
and modify the HTML of your page.
|Caution: Always insert MGI tags in a text editor
or the HTML view of a graphic page editor. Never insert MGI tags in the
graphic view of a graphic page editor.|
Step 2: Insert the sentence and mgiCounter tag.
- Insert your cursor in the HTML of your home page where you want the
mgiCounter tag to display. To put a counter at the very bottom of your
home page, insert the cursor before the ending </BODY> tag. Type
the sentence "You are visitor number" and the mgiCounter tag
on your home page. In the name parameter, enter a unique counter name.
You are visitor number <mgiCounter name="index">
|Tip: Counters are tracked in a database by counter name. Create
unique counters by using the name of the page displaying the counter.|
Step 3: Save your home page.
- Save the changes you have made to your home page.
Step 4: FTP your home page to the web server running MGI.
- Upload your home page from your local computer to the web server using
an FTP program.
Step 5: View your home page in a browser.
- View your home page in a browser. At the bottom of your home page the
sentence "You are visitor number 1" will appear. The next person
who views your home page sees the sentence "You are visitor number
2". The counter increments by 1 every time the page is viewed.
|Caution: MGI tags will not work if you view the
page locally in a browser. MGI tags only function when they are processed
by MGI and served by a web server.|
[Return to the Displaying Page Counters
Main Menu] [Understanding
MGI Menu] [Using MGI Menu] [Referencing MGI Menu]