Oracle Web Application Programming for PL/SQL Developers

Solutions Specification for main_frame

Description: This will be your entry URL for the sample application. It contains two frames. Name the top frame 'top' and the bottom frame 'main'. The top frame should load top_menu and the main frame should load splash.

Sample Frameset

top

(load top_menu here)

main

(load splash here)

Sample Code

CREATE OR REPLACE PROCEDURE MAIN_FRAME AS 
--------------------------------------------------------
-- FILENAME:     main_frame
-- FILEDATE:     01.20.2003
-- CREATED BY:   Susan Boardman
-- DESCRIPTION:  Creates application frameset if visitor
--               cookie exists.  Otherwise, calls the 
--               visitor_name page to request visitor name.
-- URL        :  main_frame 
--------------------------------------------------------
    v_val VARCHAR2(100);
  BEGIN 
    IF cookie_exists('VISITOR') THEN 
      htp.p('
         <HTML> 
         <HEAD>
          <TITLE>University Maintenance Website</TITLE>
         </HEAD>
         <FRAMESET ROWS="133,*">
             <FRAME NAME="top" SCROLLING="no" NORESIZE
                TARGET="main" SRC="top_menu">
             <FRAME NAME="main" SRC="splash" TARGET="main">
           <NOFRAMES>
              <BODY>
              <P>This page uses frames, but your browser doesn''t support them. </P>
              </BODY>
           </NOFRAMES>
         </FRAMESET>
         </HTML>
         ');
ELSE
  htp.script('document.location="visitor_name";');
  END IF;
END;

Select a Sample Application Code Unit

  1. main_frame (15.2)
  2. top_menu (13.3) / (15.2)
  3. splash (13.1)
  4. student_main_frame (6.3)
  5. students_left_nav (6.3)
  6. search_student (12.4)
  7. get_student (12.4)
  8. student_list (12.4)
  9. student_personal_info (12.4)
  10. student_zipcode (18.5)
  11. update_student (18.5)
  12. instruct (Package Spec and Body)
    • grade_calc (9.2)
    • v_font (9.4)
    • c_instruct_list (9.4)
    • inst_tbl_type (9.4)
    • instruct_table (9.4)
    • [PL/SQL block to load instruct_table] (9.4)
    • instruct_personal_info (11.3)
    • instructor_list_info (11.3)
    • showzip (11.3)
    • instructors_frame (11.1)
    • instructors_left_nav (11.1)
    • update_instructor (11.2)
    • instructor_list_class (11.3)
    • instruct_classes (11.3)
    • student_list (11.2)
  13. classes_main_frame (6.3)
  14. classes_left_nav (6, Building App)
  15. classes_list (6, Building App)
  16. classes_location (13.4)
  17. classes_location_update (13.4)
  18. set_cookie (15.2)
  19. get_cookie (15.2)
  20. cookie_exists (15.2)
  21. visitor_name (15.2)
  22. process_visitor_name (15.2)
  23. student_list_update (not in book)

Main Solutions Page