<%
/* ---------------------------------------------------------------------------------------- */
/* Copyright [2009] [System & Method Technologies]                                          */
/*                                                                                          */
/* Licensed under the Apache License, Version 2.0 (the "License");                          */
/* you may not use this file except in compliance with the License.                         */
/* You may obtain a copy of the License at                                                  */
/*                                                                                          */
/*     http://www.apache.org/licenses/LICENSE-2.0                                           */
/*                                                                                          */
/* Unless required by applicable law or agreed to in writing, software                      */
/* distributed under the License is distributed on an "AS IS" BASIS,                        */
/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.                 */
/* See the License for the specific language governing permissions and                      */
/* limitations under the License.                                                           */
/* ---------------------------------------------------------------------------------------- */
/*                                                                                          */
/* This program can be used as a basic template for loading application specific menus      */
/*                                                                                          */
/*                                                                                          */
/* Project . . . : IceBreak                                                                 */
/* Design  . . . : Niels Liisberg                                                           */
/* Function  . . : 5250 "script" sample. Default navigation                                 */
/*                                                                                          */
/* By       Date       Task    Description                                                  */
/* -------- ---------- ------- ------------------------------------------------------------ */
/* NLI      05.09.2009 0000000 New program - Subproject IceCap                              */
/* ---------------------------------------------------------------------------------------- */
H TEXT('iceCap: Simple menu outline')
H BNDDIR('EXTUTILITY')
/include qasphdr,extUtility
d path            s             32    varying
d menu            s             10       
																														
// ----------------------------------------------------------------------------------------
 /free                                                      
						
	SetContentType('text/plain; charset=windows-1252');
	
	path = qryStr('path': form('path'));
	menu = qrystr('node': form('node'));
	if menu = 'root' or menu = '';
		menu = qrystr('menu');
	endif;
	
	select;
		when menu = 'NETLINKS';
			exsr menuNETLINKS;
		when menu = 'IBMI';
			exsr menuIBMI;
		other;
			exsr mainMenu;
	endSl; 
	
	return; 

// ----------------------------------------------------------------------------------------
begsr mainMenu;

	extMenuBegin(path);
	extSubMenu ('Links on the net': 'NETLINKS');
	extSubMenu ('IBMi commands'   : 'IBMI');
	extMenuEnd();
endsr;
// ----------------------------------------------------------------------------------------
begsr menuNETLINKS;

	extMenuBegin(path);
	extMenuItem('Google'          : 'http://google.com');
	extMenuItem('wikipedia'       : 'http://wikipedia.org');
	extMenuEnd();
endsr;
// ----------------------------------------------------------------------------------------
begsr menuIBMI;

	extMenuBegin(path);
	extMenuItem('work spool files'    : 'icecap.aspx?func=wrksplf');
	extMenuItem('work system status'  : 'icecap.aspx?func=wrksyssts');
	extMenuItem('Command entry'       : 'icecap.aspx?func=call qcmd');
	extMenuEnd();
	
endsr;
