/*
*
* Package Name: OWT_HTP
* Orion Web Toolkit
* Author: J.Rimblas
* Date: 17-JUN-2001
*/
create or replace package body owt_htp
as
FUNCTION get_oracle_sid return VARCHAR2
IS
l_oracle_sid VARCHAR2(40);
BEGIN
select value
into l_oracle_sid
from v$parameter
where name = 'db_name';
return l_oracle_sid;
exception
when others then
return 'no_instance';
END;
PROCEDURE cell_filler (p_width VARCHAR2 := 'width=2%')
IS
BEGIN
HTP.tabledata (
HTF.fontopen (0, 'Verdana', '2') || c_nbsp || HTF.fontclose,
cattributes => p_width
);
END;
PROCEDURE table_header (text IN VARCHAR2, p_attributes VARCHAR2 := '')
IS
BEGIN
HTP.tabledata (
HTF.fontopen ('#FBFAE8', 'Verdana', '2') ||
HTF.strong (text) ||
HTF.fontclose,
cattributes => 'bgcolor="' ||
c_list_header_color ||
'" ' ||
p_attributes
);
END;
PROCEDURE header_data (
text IN VARCHAR2,
p_color VARCHAR2 := c_default_bg_color,
p_attributes VARCHAR2 := ''
)
IS
BEGIN
HTP.tabledata (
HTF.fontopen (0, 'Verdana', '2') || text || HTF.fontclose,
cattributes => 'bgcolor=' || p_color || ' ' || p_attributes
);
END;
PROCEDURE sub_table_header (text IN VARCHAR2, p_attributes VARCHAR2 := '')
IS
BEGIN
HTP.tabledata (
HTF.fontopen ('#FBFAE8', 'Verdana', '1') ||
HTF.strong (text) ||
HTF.fontclose,
cattributes => 'bgcolor="' ||
c_sub_list_header_color ||
'"' ||
p_attributes
);
END;
PROCEDURE table_data (
text IN VARCHAR2,
p_color VARCHAR2 := c_default_bg_color,
p_attributes VARCHAR2 := ''
)
IS
BEGIN
HTP.tabledata (
HTF.fontopen (0, 'Verdana', '1') || text || HTF.fontclose,
cattributes => 'bgcolor=' || p_color || ' ' || p_attributes
);
END;
PROCEDURE create_blank_row (
colspan_in IN VARCHAR2,
msg_in IN VARCHAR2 := 'No Data Found'
)
IS
BEGIN
HTP.tabledata (
'' || msg_in || '',
cattributes => 'align="center" bgcolor="' ||
c_list_color1 ||
'" colspan="' ||
colspan_in ||
'"'
);
END create_blank_row;
PROCEDURE create_footer
IS
BEGIN
HTP.nl;
HTP.nl;
HTP.print ('');
HTP.italic ('Developed by Orion Consulting, Inc.');
END create_footer;
PROCEDURE create_msg (msg_text_in IN VARCHAR2)
IS
BEGIN
HTP.tableopen ('width=100%');
HTP.tablerowopen;
HTP.tabledata (
HTF.fontopen (ccolor => c_msg_color, cface => 'Verdana') ||
'' ||
msg_text_in ||
'' ||
HTF.fontclose,
cattributes => 'align=center'
);
HTP.tablerowclose;
HTP.tableclose;
END create_msg;
end owt_htp; -- End of owt_HTP
/
show errors