James H. Zisch - Computer Services

Solutions : Site Management : XML Generator Utility

 

XML Generator Utility


Description
Requirements
Usage
FAQs

Description

XML Generator Utility generates an XML data file using the Item Information Dataset (IID) as input.

XML Generator Utility does not support use of RDBMS data sources; however, if using the JHZ-CS supportive RDBMS Solutions combined with the JHZ-CS DB Maintenance the Item Information Dataset (IID) should be correctly sychronized reflecting the current data and is supported by this utility.

Web Server Requirements:

  • Operating Systems Supported: Unix, Linux, Macintosh OS X® and Windows®
  • HTTP 1.x with CGI (Common Gateway Interface) PERL 5.x (check with your ISP or Server Administrator; this requirement is typically supported on most systems)
  • Optional: SENDMAIL (supported on most all Unix/Linux platforms), or PERL NET:SMTP (available from CPAN) (commonly used on Windows® server platforms) with an SMTP system pre-installed and configured. This optional requirement supports automatic email notification to the webmaster when execution errors are detected.

XML Generator Utility
Installation and Usage

FILENAME: gx.html

PURPOSE:

Describes XML Generator Utility dependencies, requirements, installation and usage.

DEPENDENCIES:

cm.pl - Configuration Management configuration and common logic modules (see: xx.html)
jhzcs.pl - JHZ-CS configuration and common logic modules (see: jhzcs.html)
IID (Item Information Dataset)

REQUIREMENTS:

Logic Modules

gx.cgi - logic module
db_tabs.pl - data mapping (required only for SQL RDBMS data source usage)

Output Template

embedded within gx.cgi

PACKING (PARTS) LIST

PACKING LIST
PRODUCT ID: GX
COMPONENT TYPE SIZE AUTH*
cgi-bin/cm/cm.incl TEXT 5198 700
cgi-bin/cm/cm.pl TEXT 1399 750
cgi-bin/cm/gx/gx.cgi TEXT 4338 750
cgi-bin/cm/gx/gx.incl TEXT 9131 700
cgi-bin/geog.pl TEXT 11750 750
cgi-bin/jhzcs.pl TEXT 47225 750
cgi-bin/license.incl TEXT 7565 700
images/JHZCS.gif BINARY 745 750
logs/errorlog.txt TEXT 91 750
*AUTH - Authorization/permissions octal equilvalents where:
7=RWX, 6=RW, 5=RX, 4=R (R=Read W=Write X=Executable)
1 char indicates Octal number
2 char Owner
3 char Group
4 char All Others

INSTALLATION:

It is strongly recommended that you read the entire installation process steps prior to performing any installations. Each solution has specific instruction that must be followed precisely.

The Installation Process

The installation process follows this order:

  1. Download solution to PC development platform and expand installation package (use any standard archive application such as WinZip®, StuffIt Expander® or TAR command)
  2. Modify configuration settings
  3. Upload to server
  4. Set access authorization permissions
  5. Test
  6. Customize Templates
  7. Test

Authorize non-Logic Components

Authorize non-logic components as follows:

  • authorized all images for read and execute access; see NOTE FOR NON-LOGIC COMPONENTS below
  • authorized all static HTML ".html" documents for read access; see NOTE FOR NON-LOGIC COMPONENTS below
  • authorized all HTML Templates ".htm" documents for read access at the logic level; see NOTE FOR LOGIC COMPONENTS below
  • authorized all images for read and execute access; see NOTE FOR NON-LOGIC COMPONENTS below.

NOTE FOR NON-LOGIC COMPONENTS: Use the minimum required permissions to achieve most secure configuration; permission requirements for non-logic modules are dependent on the server configuration whether authorization is required for group only or for both group and other.

Modify Logic Components

Modify all logic components "*.cgi" and "*.pl" logic modules as follows:

  • first line of code (#!) correctly points to the PERL executable on the server (use command "which perl" or consult your server administrator)
  • all "requires" statements contained in all "*.cgi" and "*.pl" logic modules must use absolute directory paths (beginning with a forward slash "/")

Authorize Logic Components

Authorize logic components and dependent components (HTML and Email templates, and others) as follows:

  • authorized as all "*.pl" logic modules for read access; see NOTE FOR LOGIC COMPONENTS below.
  • authorized as all "*.cgi" logic modules for read and execute access; see NOTE FOR LOGIC COMPONENTS below.
  • authorized all HTML and Email Templates documents for read access at the logic level; see NOTE FOR LOGIC COMPONENTS below

NOTE FOR LOGIC COMPONENTS: Use the minimum required permissions to achieve most secure configuration; permission requirements for logic modules are dependent on the server configuration whether authorization is required for owner only (i.e., Apache with SUExec active), or for both owner and group.

Change "absolute-path-to" occurring in the configuration section of gx.cgi with the appropriate values in order to point to the items correctly. NOTE: These must be absolute file paths starting with a forward slash (/).

############################################################
#
#	CONFIGURATION SECTION
#

require "/absolute-path-to/cgi-bin/cm/cm.pl";

$input_filepath		= "/absolute-path-to/product.dat";
$output_filepath	= "/absolute-path-to/gx_output.xml";

#
#	END CONFIGURATION SECTION
#
############################################################

Set Configuration variables and template in "gx.cgi".

  • $input_filepath (input file path)
  • $output_filepath (output file path)

Uploading to Web Server

All dependent and required components must be installed and successfully configured. All components, with the excpetion of images, must be FTP uploaded as TEXT. Images must be FTP uploaded as BINARY.

TEST:

None. All data column names found in the first record of input file will be used for generation of the XML parameters.

USAGE:

This is a back end administration utility invoked via the URL that points to it. The default install location would point to "http://yourdomain/cgi-bin/cm/gx/gx.cgi" where "yourdomain" would be replaced accordingly.

FAQs

Can I modify XML Generator Utility to create multiple files supporting different input/output files?

Yes. Make a new copy of "gx.cgi" and modify it as desired.

JHZ-CS Solutions are distributed exclusively under terms and conditions of the JHZ-CS Software License Agreement.