About Web targets
A Web target is a collection of files and components used
to create a Web application. A Web application can represent part
or all of a Web site. Web applications created using PowerBuilder
Web targets deliver dynamic, interactive content by integrating
database data, scripting for client- and server-side events, and
access to components stored on middle-tier servers. Using the PowerBuilder
development environment simplifies how you develop and maintain
these types of Web applications.
Development environment
PowerBuilder lets you develop both PowerScript and Web targets
in a workspace. You can add as many targets to a workspace as you
want, and open and edit objects in multiple targets. If your Web
application uses DataWindows and EAServer components, you can work
with all of them in a single workspace. PowerBuilder provides an intuitive
user interface, combined with wizards that step you through complex
or repetitive tasks to help you develop pages faster and spend less
time on Web site maintenance.
Deployment environment
You can deploy Web applications to PowerDynamo, Active Server
Pages (ASP), or JSP page servers. The page servers can in turn access
components on transaction servers such as EAServer or the Microsoft
Transaction Server. Web applications developed with PowerBuilder
for deployment to PowerDynamo are best supported in EAServer environments.
With PowerDynamo and EAServer you can use 4GL Web technology to
manage page data and easily integrate middle-tier components
into Web pages.
The 4GL extensions to the Web Target object model have been
duplicated for JSP targets in Java classes that can be deployed
to Tomcat, EAServer, or other JSP 1.2 compatible servers. If you
use Tomcat as a JSP server, you can still access components running
on EAServer in your Web applications.
For more information on 4GL Web technology, see Chapter 9, “Developing 4GL Web Pages”.
What kinds of applications can you develop?
The applications you build with PowerBuilder for Web site targets
(ASP and PowerDynamo) can include simple text-based HTML
pages as well as complex HTML pages with:
- Client- and server-side scripting
- Database content
- Web DataWindows
- Components, such as EAServer components (including
Enterprise JavaBeans) or ActiveX controls - Component transaction server access
All of the above elements can also be included in JSP targets
that you deploy to a JSP server.
Dynamic, data-driven applications
Dynamic business-critical Web applications typically use application
servers to display data stored in a database, and present interactive
interfaces through which users execute business transactions in
real time. The Web DataWindow, easily created within the Web Target
development environment, gives your page real-time access to databases
for retrieval and update.
Open applications
Web targets you build in PowerBuilder support an open architecture.
The basic Web Target object model supports server-side programming
for multiple application servers, enabling you to develop Web targets
for deployment to multiple servers. To provide dynamic content for
your Web applications, you can create scripts in JavaScript, or
any ECMA-compliant script (DynaScript, VBScript, JScript, and others).
For JSP targets, you can create server-side scripts in Java.
4GL applications
4GL extensions to the Web Target object model provide server-side
event processing and generate server-side code automatically from
selections you make in the Web Target user interface. For Web site
targets, 4GL applications must be used with EAServer. For JSP targets,
4GL applications can be deployed to Tomcat, EAServer, or other JSP
1.2 compatible JSP servers.
Do you need to know Java or HTML?
HTML is one of the underlying technologies for your Web site,
so it helps to know what it can and cannot do. However, you can
edit pages in the Web target HTML editor without knowing HTML syntax.
Page view (one of three views) in the HTML editor feels more like
a word processor than a code editor.
You can also create styles in the Style Sheet editor without
knowing the syntax for style definitions. If you do know HTML, the
editors help you create more complex HTML layouts like tables and
forms.
For JSP targets, you can edit pages in the HTML editor without
knowing Java syntax. When you drag and drop controls onto a page,
the HTML editor adds code that you can see in the Source view. For
4GL pages, this includes Java code to construct the control using
4GL object model classes.
If you need to create scripts, you will certainly need to
know about the objects on your page and their events, as well as
the syntax of your scripting language. The System Tree shows you
the HTML object model as well as providing an object view of your
document.
Advantages of the Web Target development environment
The Web Target development environment simplifies the configuration
and coding tasks for your applications. Wizards and dialog boxes
let you provide the information an application needs while the development
tool takes care of implementation details.
Simplifies Web application creation The re are three different wizards you can use to
create a new Web target: the Web Site wizard, the PowerDynamo Web
Site wizard, and the JSP Target wizard. The Web Site wizard prompts
you for a target name and suggests default Source and Build folders.
The PowerDynamo Web Site wizard helps you create a complete PowerDynamo
database Web site and mapping. The JSP Target wizard prompts you
to select a JSP server and select connection properties for the server.
Both the PowerDynamo Web Site wizard and the JSP Target wizard step you
through Deployment Configuration wizard screens.
Helps automate deployment configuration You access the Deployment Configuration wizard through the
Web target properties sheet. When you set up a deployment configuration,
you specify the type of server you want your Web files to run on–the
available choices depend on your target type.
For Web site targets, you can choose among the PowerDynamo,
Active Server Pages, or Basic (a file system that can be used by
a Web server of your choice) deployment controllers. Deployment
controllers adjust the scripting syntax of target files to conform
to server requirements. For JSP targets, you can choose either Tomcat
or EAServer as your JSP server.
Dynamically extends supported object models The Web Target object model extends the programming interface
for your Web pages by simplifying how you include connections to
databases, Web DataWindows, and EAServer components, and how you
handle error reporting. The entries you make in dialog boxes generate
server scripts that you can extend and customize.
The Web Target object model supports an open architecture.
However, 4GL extensions cannot be used with ASP Web site targets.
Automates link management The build process for Web targets verifies the links between
files, writing warnings for broken links or bad syntax to the Output
window. It does not attempt to fix the links and it does not prevent deployment
of the target files.
Offers debugging for PowerDynamo Web pages The debugger lets you make sure that your scripts use the
appropriate syntax for PowerDynamo. It provides information about
errors in your scripts so that you can correct them.
Enables the use of a team environment If you create Web targets in a team environment, you can control
file access though the source control system you have configured
for your workspace. You work with the source control system the
same way you do for PowerScript targets in PowerBuilder, except that
for Web targets, the files you obtain from the source control server
do not need to be compiled.