HOPEX Power Studio (EN) : Customizing Web Sites : Managing Web Sites: Advanced Functions : Managing Web Site Files
   
Managing Web Site Files
 
Generated File and Folder Structure
Configuring User Options
Checking File Names
Object identifier
File naming rules
Respecting specific naming rules
Index page naming rules
Image naming rules
Integrating External References
External reference integration standard mode
External reference management configuration
Macro content
Generated File and Folder Structure
The Web site is generated in a folder indicated in the properties of each Web site (see "To create a Web site from a Web site template:", page 406 for a description of these properties).
For each site, the following structure is generated:
The described structure is generated by the standard sites provided. The generation can be customized if a different structure is required.
The environment folder includes image files such as bullets and the company logo, which are independent of the repository content, as well as the Web site style sheet (xxx.CSS).
The “Images” folder contains the diagrams generated from the repository contents.
The “Pages” folder contains the HTML files that describe the site repository objects, as well as the files required for site navigation.
*For each object, there can be several HTML files; for example, the one that defines the two frames in the main window (menu on the left, and object description on the right), and the two files that define the content of these two frames. Depending on the type of object, there may be additional files; for example, an object described by a diagram will have additional HTML files used to display its drawing, etc.
To move a site, simply select the root folder for the site structure and copy it to another location. The generated HTML addresses are relative and remain valid wherever the site is placed. Example: BACKGROUND=“../STANDARD/BKGROUND.GIF”.
Configuring User Options
To configure user options:
1. From HOPEX menu bar, select Tools > Options.
2. In the Options of user window, double-click the "Web Sites" icon.
You can:
specify the Generated images format (Bitmap, JPEG, SVG, PNG).
modify the Default parent URL (http://www.mega.com).
specify the templates used for the Home Page and Site Map.
The Home Page and Site Map are generated from files found in the MEGA_STD folder of the folder in which HOPEX was installed. These files have the extension “.mth”: "HomeLeft_us.mth" for the Home Page, "SiteMap_us.mth" for the Site Map with navigator at the left. If you want to customize these files, copy them into the "Mega_Usr" sub-folder and refer to "Modifying Home Page and Site Map Files".
modify the folder that contains the standard files (for example, the images corresponding to the various object types) and the images and pages generated.
process external references as being relative to the Web site.
HOPEX Power Studio - Publisher offers you the possibility of importing external references into the HOPEX site. For more detailed information, see "Integrating External References".
specify the case for names of generated files (first letter upper or lower-case).
delete pages of an earlier generation before any new generation.
Modification of these parameters is valid for all Web sites generated.
Checking File Names
The file “Sitedef.ini” found in the root folder in which the site is generated (Intranet is the default) indicates for each object the correspondence between its absolute identifier and the name of the file describing its main page.
For each object in the site, a paragraph like this is created:
[245D261330A3002D]
PageName = 245D261330A3002D
Available = Yes
Object = Sales Department Org-Unit
MetaClass = Org-Unit
Object identifier
The identifier for the object is given inside brackets. This identifier never changes once the object is created, in order to retain all links and properties even if the object is renamed.
File naming rules
The PageName value indicates the name of the main page. When the site for the object with this absolute identifier is regenerated, this string of characters is used to name the HTML files, followed by a letter and then the HTM extension. PageName is used even if the object name has been changed. This ensures that when a site points to another site, links remain valid (the indicated address remains constant).
 
*The generated HTML pages are built of several frames that are called by the main page. There is an HTM file specifying the contents of each frame. For example, for the object “Sales Department Org-Unit”, the files generated could be “245D261330A3002D.htm”, which is the name of the main page describing the object and is fixed, supplemented for example by “245D261330A3002D_M.htm", "245D261330A3002D_D", etc.
Respecting specific naming rules
When specific rules must be followed for naming pages, simply perform an initial generation, modify the file names to comply with the rules, and regenerate the site so that the generated file names are in compliance with the rules in effect. For example, simply modifying the above paragraph to look like this means the HTML files will have the prefix A1_DR instead of DIREC2:
[245D261330A3002D]
PageName = A1_DR
Available = Yes
Object = Sales Department Org-Unit
MetaClass = Org-Unit
The line “Available = Yes” indicates that the object is still present in the site. If the object was included during a previous generation but is no longer part of the site (such as an organizational process now deleted from the project), this line becomes “Available = No”.
*As the file “Sitedef.ini” is intended to ensure that file names are retained during successive page generation operations, though an object may no longer be referenced in the site it is still retained in this file. If the object is later reincluded, the page names will remain identical.
The object type and name are then indicated in the “Object” line (in the example, “Object = Sales Department Org-Unit”).
Index page naming rules
An index page comprises a menu page (_M) and a content page (_C).
Menu page
 
Naming rule
Index page name
Without naming rule (without SiteDef.ini)
ParentPageName_M.htm
With specific naming rule (with Sitedef.ini)
IndexPageIdentifier_M.htm
 
Content page
 
Naming rule
Index page name
Without naming rule (without SiteDef.ini)
ParentPageName_C.htm
With specific naming rule (with Sitedef.ini)
IndexPageIdentifier_C.htm
*When several index pages are specified for the same object type (alphabetical index, index by characteristic, etc.), the index pages are suffixed by an order number (for example, xxxxx_C_PIDX1.htm, xxxx_C_PIDX2.htm).
Image naming rules
Images are named as follows:
HexaIdAbs of described object _HexaIdAbs of diagram_I.png (or .bmp, .svg, .jpg depending on image format)
Integrating External References
HOPEX Power Studio - Publisher offers you the possibility of importing external references into the HOPEX site.
*To do this, you must create external references with predefined folder (see "Using External References", page 415).
External reference integration standard mode
To integrate external references in the HOPEX site:
1. Verify that the external references are specified using a predefined folder.
2. Indicate that the address of external references is relative to the Web site.
From HOPEX menu bar, select Tools > Options, then double-click the Web Sites icon and select External references relative to site.
3. Generate the Web site.
4. Start the "XRefCopy.vbs" file in the "Intranet" folder to copy the external references in a sub-folder of the site.
By default, this sub-folder is called REFEXT. You can modify it in the user configuration (in the workspace, select Options > Tools then double-click the Web Sites icon).
The external references are now accessible from the Web site.
External reference management configuration
External reference path generation can be configured if the standard method described above is not suitable.
You can carry out this parameterization using a macro, connecting it to the Web site or Web site template by the "External reference manager" link.
To do this:
1. In the pop-up menu of the Web site, select Explore.
2. In the empty "External reference manager" folder, click Connect.
The Query window appears.
3. Select the required macro.
Macro content
If no macro is connected to the Web site, the "ExternalReferenceManager" macro provided by default is taken. This macro carries out processing described in "External reference integration standard mode".
You can create your own macros. The macro must contain the following methods:
Start of generation
This method indicates start of generation.
Sub StartExternalReference(oWebGenCtx)
End Sub
Method called for external references
Sub ExternalReferencePathGet(oExternalReference, oWebGenCtx,enFilter , strResultPath)
This method is called for each external reference. It retrieves the path of the external reference to be displayed in strResultPath and manages copy.
 
End of generation
Sub StopExternalReference()
End Sub