Show TOC Entering content frame

This graphic is explained in the accompanying text Layout Maintenance for Web Requests: Example Locate the document in its SAP Library structure

The following example illustrates the HTML pages and the corresponding source codes.

The request consists of two pages. The first page (page_form) is intended for entering request data. The second page (page_confirm) issues a confirmation to the requester that the request was forwarded successfully.

 

Request Form (page_form)

The following graphic displays the layout of the request form (page_form):

This graphic is explained in the accompanying text

Graphic: Request Form in the Web Client

 

<%@ page language="abap" %>

<html>

  <style> </style>

  <head>  </head>

  <body>

 

    <font color="#FF0000">

      <div id="messageText"><%= application->message_text( ) %></div>

    </font>

 

    <form method="POST" action="<%= application->action( ) %>">

 

    <table>

    <tr>

      <td>Name, first name</td>

      <td><input type="text" size="20"

         name="//request/applicant/name/first_name"

         value="<%= application->get( '//request/applicant/name/first_name' ) %>" >

          <input type="text" size="20"

          name="//request/applicant/name/first_name"

          value="<%= application->get( '//request/applicant/name/last_name' ) %>" >

      </td>

    </tr>

    <tr>

      <td>E-Mail</td>

      <td><input type="text" size="43"

            name="//request/applicant/email"

            value="<%= application->get( '//request/applicant/email' ) %>" ></td>

    </tr>

    </table>

 

<!-- radiobutton -->

    <table>

    <tr>

      <td> Typ: </td>

      <td> <input type="radio" name="//request/car/type" value="1"

      <%= application->checked( path = '//request/car/type' value = '1' ) %>

      <%= application->disabled( '//request/car/type' ) %> />

       Car </td>

    </tr>

    <tr>

      <td> </td>

      <td> <input type="radio" name="//request/car/type” value="2"

      <%= application->checked( path = '//request/car/type' value = '2' ) %>

      <%= application->disabled( '//request/car/type' ) %> />

       Motorcycle </td>

    </tr>

    </table>

 

    <p> </p>

 

<!-- select feld -->

    length:

    <select <%= application->disabled( '//request/car/length' ) %> size="1"

      name="//request/car/length">

    <option

      <%= application->selected( path = '//request/car/length' value = '1' ) %>>

      shorter than 2m</option>

    <option

      <%= application->selected( path = '//request/car/length' value = '2' ) %>>

      longer than 2m</option>

    </select>

 

    <p> </p>

 

<!-- Checkbox -->

    Diesel:

    <input name="//request/car/engine" type="hidden" value=""/>

    <input type="checkbox"

       name="//request/car/engine"  value="X"

       <%= application->checked( path = '//request/car/engine' value = 'X' ) %>

       <%= application->disabled( '//request/car/engine' ) %> />

 

    <p> </p>

 

<!-- Set hidden fields for navigation ----------------------------------- >

    <input name="uws_next_page" type="hidden" value="page_confirm"/>

    <input name="uws_prev_page" type="hidden" value="page_form"/>

    <input name="uws_exit_url"  type="hidden" value="http://www.sap.com"/>

<!-- Fields and buttons for checking and submitting entries --------------- >

     <% if not application->mode( ) = 'DISPLAY'. %>

    <input type="submit" value="Check"  name="onInputProcessing(CHECK) ">

    <input type="submit" value="Submit"  name="onInputProcessing(SUBMIT)">

    <% endif. %>

 

<!—Buttons to scroll forwards and backwards for forms with more than one page --------->

<!—are not needed in this case ------------------------------------------>

<!-- <input type="submit" value="S. forward”

            name="onInputProcessing(NEXT_PAGE)"> -->

<!-- <input type="submit" value="S. back”

            name="onInputProcessing(PREV_PAGE)"> -->

<!-- <input type="submit" value="exit" 

            name="onInputProcessing(EXIT)"/> -->

<!—Setting the dark, system control parameters   ----------------------->

    <%= application->insert_hidden_parameters( ) %>

<!-------------------------------------------------------------------------------->

    </form>

  </body>

</html>

 

 

Confirmation Page (page_confirm)

The number of the created process is issued on this page via the Scripting order <%= application->external_id( ) %>.

The layout of this page is as follows:

This graphic is explained in the accompanying text

Graphic: Confirmation page in the Web Client

 

<%@ page language="abap" %>

<html>

  <head>

    <title> </title>

  </head>

  <body>

    <form method="post">

      <!--  default font-->

      <font face="Arial" size="2">

        <!--  error message-->

        <table>

          <tr>

            <td>

              <font color="#FF0000">

                <div id="messageText"><%= application->message_text( ) %></div>

              </font>

            </td>

          </tr>

        </table>

        <p> </p>

        Thank you! <br>

        Your request was created under the number <%= application->external_id( )%>

        <p> </p>

        <%= application->insert_hidden_parameters( ) %>

      </font>

    </form>

  </body>

</html>

 

 

 

Leaving content frame