Top

Using WebScript

The WebScript Language

This section describes WebScript language features and syntax. For a complete WebScript example and a discussion of how scripts operate within the larger context of a WebObjects application, see Using WebScript in a WebObjects Application.

The topics included in this section are:

Using WebScript in a WebObjects Application

This section discusses using WebScript in the context of a WebObjects application. For a detailed discussion of the structure of a WebObjects application, see the chapter Getting Started. The topics included in this section are:

  • The Role of Scripts in a WebObjects Application
  • This section describes where scripts fit in to the overall structure of a WebObjects application.

  • Visitors Example
  • This simple example is used to illustrate how a script operates within the larger context of a WebObjects application. The Visitors example is a one-page application that takes the name of the current visitor, and displays the most recent visitor as well as the total count of visitors to the page.

  • Variables and Scope
  • This section discusses the global and session variables you declare in an application script, and the transaction and persistent variables you use in a component script.

  • Accessing and Sharing Variables
  • This section describes how you access variables declared in one script from another.

    Debugging

    For information on debugging WebScript, see the section "Debugging" in the chapter "Compiling and Debugging WebObjects Applications."

    WebScript Language Summary

    This section provides a reference summary of the statements, operators, and keywords used by the WebScript language. Read this section if you want a quick overview of what's in the WebScript language.

    Special Topics

    The following topics apply to special audiences.

  • Object-Oriented Concepts: a Quick Overview
  • If you're new to object-oriented programming, read this section for a quick overview of object-oriented concepts.

  • What Are the Origins of WebScript?
  • This section describes the origins of the WebScript syntax.

  • A Note to Objective-C Developers
  • If you're an Objective-C developer and you want to know how WebScript compares to Objective-C, read this section.

    Table of Contents Next Section