+ All Categories
Home > Documents > The IBM-Informix WebBlade

The IBM-Informix WebBlade

Date post: 31-Jan-2016
Category:
Upload: chinue
View: 99 times
Download: 0 times
Share this document with a friend
Description:
The IBM-Informix WebBlade. The Most Productive tool in the IBM-Informix portfolio ?. Paul Watson Unemployed Using Informix since the beginning of time V7 since it was released – first UK installation V9 since 9.10. Can you write HTML ? Can you write SQL ?. The End. Agenda. Example Sites - PowerPoint PPT Presentation
43
Web Datablade Atlanta 2005 The IBM-Informix WebBlade The Most Productive tool in the IBM-Informix portfolio ?
Transcript
Page 1: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

The IBM-Informix WebBlade

The Most Productive tool in the IBM-Informix portfolio ?

Page 2: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

• Paul Watson

– Unemployed

– Using Informix since the beginning of time

– V7 since it was released – first UK installation

– V9 since 9.10

Page 3: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

• Can you write HTML ?

• Can you write SQL ?

Page 4: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

• The End

Page 5: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Agenda

• Example Sites

• How it Works

• Installation

• How you use it

Page 6: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Page 7: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Page 8: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Page 9: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Page 10: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Page 11: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Movie File

Page 12: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

How it Works

• Supported Platforms

– All IDS V9 platforms

• Supported Web Servers

– Apache V1 and V2– Netscape– Microsoft IIS

Page 13: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Architecture

Page 14: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Installation

• Untar the file

• Run install script

– Answer the difficult questions

• What web server are you using

• What is INFORMIXDIR

• Where is the configuration file MI_WEBCONFIG

• Provide a username

• Where is the smart blobspace

Page 15: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Setup [Apache]

• If Apache has not been built with DSO then rebuild apache for an easy life

• Edit httpd.conf– LoadModule informix_module libexec/explode.so

<Location /private/databases/boris/admin >SetHandler informix_explodeAuthType BasicAuthName "admin"require valid-user

</Location>

• Copy library to correct location

• Restart apache

Page 16: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Setup [Informix]

• Run webconfig

webconfig –addmap –p /private/databases/boris/admin –n ddw –u

• This will update the configuration file, MI_WEBCONFIG

Page 17: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Test Setup

• Run webconfig – verify

• If all the questions have been answered correctly then it just works

• Checking: /games/3

: database=boris

: user=wboris

: password=<encrypted>

: config_name=ddw

Connect : Success

Config : 15 variables found

Schema : ddw (source_table=wbPages, content_column=object, id_column=ID)

AppPages: 318

Page 18: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

MI_WEBCONFIG FILE

• Used to configure the library

<global>

debug_file /var/oninit/webdriver.log

debug_level 2

anchorvar WEB_HOME/

config_user admin

config_password c1b82752477fe6c62370eceb896687e

</global>

<setvar>

INFORMIXDIR /home/informix

INFORMIXSERVER oninit_net

DBDATE=DMY4

</setvar>

Page 19: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

MI_WEBCONFIG FILE (cont).

<map path=/private/databases/wbe/admin>

database wbe

user wwbe

password c4e582c979d323b07742efe3fd8684c3

password_key 38d8e369

config_name admin

config_security on

</map>

<map path=/wbe>

database wbe

user wwbe

password c4e582c979d323b07742efe3fd8684c3

password_key 38d8e369

Config_name ddw

</map>

Page 20: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Setup

Page 21: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Setup (cont.)

Page 22: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Webconfig

Use to configure and test the installation

-addmap -p <url Prefix> -n <config name> -d <database -u <user> [-s <server>]

-convert -p <url Prefix> -n <config name> -f <old-config filename>

-verify [-p <url Prefix>]

-secure [-iis]

Page 23: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Webpwencrypt

Use to generrate new passwords for entry into the MI_WECONFIG file

webpwencrypt <database> <user> <key>

Page 24: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Application Development

• Can you write SQL? Have you got a HTML manual?

• If you are sad and lonely, write the code by hand.

• Use Data Director for Web

– Site Manager

– Application Page Editor

Page 25: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Page Structure

• Html

• SQL statements

• Tags

• Processing Blocks

Page 26: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Page Structure

• Html

– Hello World

Insert into webpages(name, path, extension, object)Values(‘hello’, “/”, ‘html’,‘hello world’)

Access via

http://local/test/hello.html

Page 27: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Page Structure

• SQL

<?MISQL sql=“select tabname from systables;”>$1

</?MISQL>

<?MISQL sql=“execute function sp_whoami();”>$1

</?MISQL>

Page 28: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Page Structure

• Tags

insert into wbtags(name,object)values(whoami, ‘<?MISQL sql=“execute function

sp_whoami();”>$1</?MISQL>’);

Use in the html

<body><?whoami></body>

Page 29: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Web Page Structure

• Processing Blocks

IF THEN

FOR Loops

WHILE Loops

FOREACH Loops

MIBLOCKs

<?MIBLOCK cond”$(=,var,1)”><b>Var is $1 </b>

<?MIELSE><b>Var should be $1 </b>

<?MIBLOCK>

Page 30: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Forms

• Get and Post actions

• Pseudo Code– If ACTION = POST

• Process Form

– If ACTION = GET• Display form

Page 31: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Forms

<?MIBLOCK cond=“$(EQ,$action,GET)”<FORM>

<input name=action type=hidden>POST</input><input name=MIval type=hidden>$MIval</input>

<input name=var>0</input>

<?submit></FORM>

<?/MIBLOCK>

<?MIBLOCK cond=“$(EQ,$action,POST)”><?MISQL sql=“insert into table

values($var);”><?/MISQL><?/MIBLOCK>

Page 32: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Session Management

• Session Type– Url or cookie or auto

• Session Home– WEB_HOME

• http://localhost/mysite/?MIval=mypage.html

• Session location– File system location for temporary files

• Session Duration– How long is a session valid

Page 33: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Session Variables

• Magic Variable $session

– <?MIVAR name=session.myvar>Set this variable<?/MIVAR>

– <?MIVAR name=session.mynum>20<?/MIVAR>

Page 34: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Caching

• Two levels

– Tags

Allows tags to be evaluated once and the expand by all referring pages

– Page Level

Caches entire page on disk

Cache administration pages

Page 35: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Deferred Variables

• If the page is cached a mechanism is required to allow some elements to be evaluated at runtime

– For example, HTTP_HOST, HTTP_REFERER

• Configured via the Web admin pages

Page 36: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Deferred Variables

<body>

Coming from $HTTP_REFERER IP [$REMOTE_ADDR] <br>

Current Server is $HTTP_HOST <br>

Cached Variable $myvar <br>

</body>

Page 37: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Data Director: Site Manager

Page 38: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Data Director: Site Manager (cont.)

Page 39: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Data Director: Site Manager (cont.)

Page 40: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Data Director: Site Manager (cont.)

Page 41: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Data Director: Application Page Editor

Page 42: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Problems

• 64 bit Apache 2 – doesn’t work

• Doesn’t work on W2K or XP

Page 43: The IBM-Informix WebBlade

Web Datablade Atlanta 2005

Questions ?


Recommended