★ wanayoo — archive 1999 http://java.webdeveloper.com/MenuApplet/config.htmlNouvelle recherche | Portail wanayoo
Computer Digital Expo

The PC, Console and Hand-held Game Business Event


Find a Web Host With:
CGI Access
DB Support
NT Servers
UNIX Servers
Telnet Access

advanced search
Internet News
Internet Investing
IT
Windows Technology
Linux/Open Source
Developer
Interactive Marketing
xSP Resources
Small Business
Wireless Internet
Downloads
Internet Resources
Internet Lists
International
EarthWeb
Career Resources

Search internet.com
Advertise
Corporate Info
Newsletters
E-mail Offers
Be a Commerce Partner
Internet Jobs
Shop For Computers
Track Defects Online
Tech Magazines - FREE
Reach IT Professionals
Find a Web HostFind a Web Host
Software Store
Hacker's Secrets
Register Domains
Build an Online Store
FlashKit
Gif.com
HierMenusCentral
JavaBoutique
JavaScript.com
JavaScriptSource
WebDev Jobs
JustSMIL
ScriptSearch
StreamingMediaWorld
Web Hosts
WebDevelopersJournal WDVL
WebDeveloper.com
WebReference.com
XMLFiles.com
CGI
HTML
Java
JavaScript
Web Design and Promotion
Web Site Development
E-mail Address:


Can you receive
HTML e-mail?

Yes   No

Zip Code:


MenuApplet


MenuApplet How to

This is a short description about how to configure the MenuApplet java applet.

1. What is menu Applet?

This is a navigation pallet applet that can run in a floating window
	or in a frame. It is very useful in big sites because it helps the
	visitor to find a web page without navigating through the site.

2. Files the applet needs to work.

MenuApplet.class
LabelButton.class
MenuApplet.ini - configuration file.

These files must be placed in the same directory.

Other files:

MenuApplet_How_to.html, screen.gif - this documentation.

3. How this applet looks.

You can see two columns.
The first one, labelled "Select" is the column with categories.
The second one, labelled "Go to" contain Links.
Clicking on a category the applet loads its links in the "Go to" menu.
The configuration of the categories is loaded from the MenuApplet.ini file.

4. Installation.

	First you have to write the MenuApplet.ini file. This is a sample:

+Test pages+
\test1\ "test_html/test1.html"
\test2\ "test_html/test2.html"
\test3\ "test_html/test3.html"
\test4\ "test_html/test4.html"
\test5\ "test_html/test5.html"

+Links+
\My page\	"http://www.obs-us.com/people/mihai"
\Real Media\	"http://www.real.com"
\Netscape\	"http://home.netscape.com"
\Yahoo\		"http://www.yahoo.com"
\Altavista\	"http://altavista.com"
\CNN\		"http://cnn.com"

All lines that doesn't start with '+' or '\' character are ignored
A line starting with a '+' means that the following characters
	until the first '+' are the name of a category (select menu).
A line starting with a '\' means that the following characters until the
	first '\' are the name of a link (go to menu). These lines starting
	with '\', must be after a category line. All these lines until the next
	category name or the end of the file are the links for the category.
After a link name, between quotes, it is the e URL of the link. It can be
	a relative URL from the class files, or an absolute URL.
	The absolute one must start with "http://"

Important!
The maximum number of categories or number of links in a category is 20.
	It means that the maximum number of links is 20*20=400.


The applet tag.
This is a sample:

<APPLET CODE=MenuApplet.class WIDTH=260 HEIGHT=150>
	<PARAM NAME=TargetWindow VALUE="LoadHere">
		<!--this parameter can have following values:
			"_blank"
				Display the document in a new window
			"WindowName"
				Display the document in a window
					named windowname
			"_self"
				Display the document in the window (frame)
					that contains the applet
			"_parent"
				Display the document in the parent frame
			"_top"
				Display the document in the top-level frame

		the default value is "_self"
		 -->
</APPLET>

The tag has only one parameter, named TargetWindow.

How to calculate the size of the applet.

HEIGTH=(n+1)*18, where n is the maximum number
	of the categories or links in a category

WIDTH >= 12+(p*7)+(q*7). p is the number of characters in the longest
	category name. q the number of characters in the longest name of a link.

If the WIDTH is larger, the "Go to" section of the applet will be larger.
	The "select" section will preserve its width.

If  the longest name of the categories contains very wide
	characters can be truncated. In this case add one or
	more space characters after its name in the ini file.

If the applet is too narrow for the "go to section",
	just make the WIDTH attribute in the APPLET tag bigger.

How to make the applet to work in a floating window.

You need a little java script that will bring up a window with the applet.
	For example you can place a button in the page:

<FORM>
	<INPUT TYPE="button" NAME="Button1"
		VALUE="Open Menu Window!" onClick="window.open('menu.html',
		'displayWindow', 'menubar=no,height=166,width=244')">
</FORM>

The width and the height of the new window must be about 20
	pixels bigger than the width and the height of the applet.

If the window you want to load the links in doesn't have a name,
	just add in the head section of the HTML file the following code:

<HEAD>

<SCRIPT LANGUAGE="JavaScript">
<!--
window.name="LoadHere";
//-->
</SCRIPT>
</HEAD>

The TargetWindow parameter in the APPLET tag must be "LoadHere".

If you use the applet in a frame  (not in a floating window)
	or if you want to load the documents in a frame,
	the frame it is already named in the FRAMESET tag.


5. License

Menu Applet 1.0
Copyright (C) 1998  Mihai Munteanu

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

You can contact me at:

* http://www.obs-us.com/people/mihai
* e-mail:  m.munteanu@shef.ac.uk   or   mmm@deltanet.roknet.ro
* Mihai Munteanu
  str. M.Eminescu 44
  2200 Brasov, ROMANIA
* fax: +40 (0)68 410330

Back to the MenuApplet page


Applet Index
(sorted alphabetically)

A B C D E F G H I J K
L M N O P Q R S T U
V W X Y Z #s
The Java Source
(applets w/source code)

A B C D E F G H I J K
L M N O P Q R S T U
V W X Y Z

How to Add Java Applets to Your Site

New on the Java Boutique:

New Article:
J2EE Deployment Specification
Why is it that J2EE applications written in the same language, Java, may not coexist on different servers? While the answer isn't simple Sun has set out to alleviate these problems with the "J2EE Deployment Specification".
... [more articles]

New Tutorial:
Designing Packages for Stability
Are your designs stable? This month Samudra will focus on the change impact relationship involved in designing classes showing us how to take them into account when designing the package relationship.
... [more Tutorials]

Year in Review:
The Best of 2002
The year 2002 saw 201 new applets posted to JavaBoutique. Check out the 2 most popular apps from each month of 2002!
... [popular applets]

Elsewhere on internet.com:

WebDeveloper Java
Lots of Java information on webdeveloper.com

WDVL Java
Thorough Java resource at the Web Developer's Virtual Library.

ScriptSearch Java
Hundreds of free Java code files to download.

internet.com logo




Developer News

JBoss Group: Defections Aren't a Big Deal

IE Object Tag Buffer Overflow Patched

SCO Shuts Down German Site



Database Journal Launched!
Jupiter Media has announced the launch of Database Journal. DBJ offers SQL courses and other database related resources for beginner to expert developers.



JWizardPane
Build modern wizard style interface quickly. API easy to use. Bulti-in show dialog and frame support.
Download of the Week
BSCOutline v5.10
BSCOutline Java Outline Applet is a customizable tree view control for use in Web pages, similar to that used by Windows File Manager or Explorer. BSCOutline has been written to be the simple to use and small to store.

JB User Poll
How does .NET fit into your programming?
The JavaBoutique Top 15:
1. ChompText
2. PingPong
3. PulseText
4. DJPopMenu
5. RushHour
6. NavBar
7. 3DMaze
8. AScroll2
9. Encyclo
10. Nibbly
11. AnimLetters_anim
12. Distorter
13. BMMenu
14. SiteBrowser
15. Viewer
Want more? Check out our Top 100!

Refer-It
Affiliate Program and Referral Directory.
New on internet.com
AOL 9.0 Represents Streaming Sea Change
After years of investment, AOL's own multimedia player technology represents an emerging agnostic standard among competing media player formats.

Lessons From the Lemonade Stand
10 ways for your small business to succeed at e-commerce..

Global Biz Still Unprepared
Record-breaking digital attacks and threats of more serious disasters have not inspired organizations to adopt complete business continuity plans for dealing with catastrophes.


Copyright 2003 Jupitermedia Corporation All Rights Reserved.
Legal Notices,  Licensing, Reprints, & Permissions,  Privacy Policy.
http://www.internet.com/