Tech Notes
Tech Notes |
Adding a page to an existing WebHub application
Editing WHTEKO files
If your web application has a GUI with a menu, you can probably get to the file editor by (a) using the menu, ; or (b) clicking to the Html > Files panel.
If you are using Dreamweaver, just open the WHTEKO file from within Dreamweaver.
Syntax for adding a page
Define one or more pages within the <whteko> tag.
<whpage pageid="mypagename" desc="my page description"> page text here </whpage>
Version-Specific Notes
For WebHub Components v0.895 to v2.037
Creating pages using WebHub Syntax Stage 1
From the running WebApp (e.g. htfish.exe), select the application menu based on the AppID (e.g. HTFS) and select .
You will see a list of the files already used in the application. Click on a filename (e.g. htfish.htm) to select it, and then press the [Edit File] button.
Create a new page by copying any of the sections that start pageBegin and end with the row of asterixes. Change the page name and description.
Page definition syntax--simplest
<H1>-PageID=Page Description</H1>
- pageBegin macro indicates the beginning of the page definition
- PageID: page identifier, which may not include spaces
- Page Description : often re-used as page title (see pageDesc macro in chPageHeader definition)
- endInfo macro indicates the end of the page description
Page definition syntax--planning ahead
<H1>-PageID=,,,Page Description</H1>
Here we are just adding three commas as placeholders.
Page definition syntax--for exporting
<h1>-PageID=,ExportFilename,,Page Description</h1>
- ExportFilename: filename to create when exporting. You can use any filename, including .htm or .html and any pathname. Pathname will be relative to ExportDir, which should be set under application defaults.
Page definition syntax--advanced
<h1>-PageID=PageAlias,ExportFilename,Reserved,Page Description</H1>
- PageAlias: this would be left blank if you are creating pages via an WHTEKO file. Aliases are used when you are setting up the page definitions for the entire WebApp (using TwhApplication|Edit Pages) and you want to alias one page to another. For example, you could indicate that homepage is an alias for xxx, and then JUMPs to homepage would be expanded as links to xxx. PageAlias can include AppID and ServerProfileID.
- Reserved: this area is reserved for future use.
<H1>YourPageNameWithoutSpaces=Your Page Description With Optional Spaces</H1>
The key conceptual elements in that expression are:
-pageName=pageDescription
After that line, enter whatever HTML you like for the actual page.
Then add a closing comment with lots of asterixes (you'll see lots of samples in the files).
and .
Back on the trialapp.exe (or fishapp.exe), pull down the application menu again and select Refresh. This tells the EXE to re-read the Files in the application. You can then request the page from your browser.
The URL will be /cgi-win/webhub.exe?TrialApp:YourPageNameWithoutSpaces
Wow!!!
Get it? You can update your application without shutting down your .exe.
Running DynHelp.exe v1.2.0.6 on WebHub-v2.125 built by D14
Calc time: 156 ms

