[Home] [Help]
1: package body XNP_wsgl as
2: /* $Header: XNPWSGLB.pls 120.1 2005/06/24 05:59:29 appldev ship $ */
3:
4:
5: -- Current version of WSGL
110: order by product;
111: current_user varchar2(30) := GetUser;
112: begin
113: if p_full then
114: DefinePageHead(MsgGetText(101,XNP_WSGLM.DSP101_WSGL_INFO));
115: OpenPageBody;
116: DefaultPageCaption(MsgGetText(101,XNP_WSGLM.DSP101_WSGL_INFO));
117: end if;
118: LayoutOpen(LAYOUT_TABLE, TRUE);
112: begin
113: if p_full then
114: DefinePageHead(MsgGetText(101,XNP_WSGLM.DSP101_WSGL_INFO));
115: OpenPageBody;
116: DefaultPageCaption(MsgGetText(101,XNP_WSGLM.DSP101_WSGL_INFO));
117: end if;
118: LayoutOpen(LAYOUT_TABLE, TRUE);
119: LayoutRowStart;
120: LayoutHeader(50, 'LEFT', NULL);
120: LayoutHeader(50, 'LEFT', NULL);
121: LayoutHeader(50, 'LEFT', NULL);
122: LayoutRowEnd;
123: LayoutRowStart;
124: LayoutData(MsgGetText(102,XNP_WSGLM.DSP102_WSGL));
125: LayoutData(WSGL_VERSION);
126: LayoutRowEnd;
127: LayoutRowStart;
128: LayoutData(MsgGetText(103,XNP_WSGLM.DSP103_USER));
124: LayoutData(MsgGetText(102,XNP_WSGLM.DSP102_WSGL));
125: LayoutData(WSGL_VERSION);
126: LayoutRowEnd;
127: LayoutRowStart;
128: LayoutData(MsgGetText(103,XNP_WSGLM.DSP103_USER));
129: LayoutData(current_user);
130: LayoutRowEnd;
131: for c1rec in c1 loop
132: LayoutRowStart;
135: LayoutRowEnd;
136: end loop;
137: if not p_full then
138: LayoutRowStart;
139: LayoutData(MsgGetText(105,XNP_WSGLM.DSP105_WEB_SERVER));
140: LayoutData(owa_util.get_cgi_env('SERVER_SOFTWARE'));
141: LayoutRowEnd;
142: LayoutRowStart;
143: LayoutData(MsgGetText(106,XNP_WSGLM.DSP106_WEB_BROWSER));
139: LayoutData(MsgGetText(105,XNP_WSGLM.DSP105_WEB_SERVER));
140: LayoutData(owa_util.get_cgi_env('SERVER_SOFTWARE'));
141: LayoutRowEnd;
142: LayoutRowStart;
143: LayoutData(MsgGetText(106,XNP_WSGLM.DSP106_WEB_BROWSER));
144: LayoutData(owa_util.get_cgi_env('HTTP_USER_AGENT'));
145: LayoutRowEnd;
146: LayoutRowStart;
147: LayoutData(MsgGetText(125,XNP_WSGLM.DSP125_REPOS_APPSYS));
143: LayoutData(MsgGetText(106,XNP_WSGLM.DSP106_WEB_BROWSER));
144: LayoutData(owa_util.get_cgi_env('HTTP_USER_AGENT'));
145: LayoutRowEnd;
146: LayoutRowStart;
147: LayoutData(MsgGetText(125,XNP_WSGLM.DSP125_REPOS_APPSYS));
148: LayoutData(p_app);
149: LayoutRowEnd;
150: LayoutRowStart;
151: LayoutData(MsgGetText(126,XNP_WSGLM.DSP126_REPOS_MODULE));
147: LayoutData(MsgGetText(125,XNP_WSGLM.DSP125_REPOS_APPSYS));
148: LayoutData(p_app);
149: LayoutRowEnd;
150: LayoutRowStart;
151: LayoutData(MsgGetText(126,XNP_WSGLM.DSP126_REPOS_MODULE));
152: LayoutData(p_mod);
153: LayoutRowEnd;
154: end if;
155: LayoutClose;
153: LayoutRowEnd;
154: end if;
155: LayoutClose;
156: if p_full then
157: htp.header(LayNumberOfPages, MsgGetText(104,XNP_WSGLM.DSP104_ENVIRONMENT));
158: owa_util.print_cgi_env;
159: ClosePageBody;
160: end if;
161: exception
159: ClosePageBody;
160: end if;
161: exception
162: when others then
163: raise_application_error(-20000, 'XNP_WSGL.Info
'||SQLERRM);
164: end;
165:
166: --------------------------------------------------------------------------------
167: -- Name: IsSupported
268: htp.para;
269: end if;
270: exception
271: when others then
272: raise_application_error(-20000, 'XNP_WSGL.LayoutOpen
'||SQLERRM);
273: end;
274:
275: --------------------------------------------------------------------------------
276: -- Name: LayoutClose
304: end if;
305: htp.para;
306: exception
307: when others then
308: raise_application_error(-20000, 'XNP_WSGL.LayoutClose
'||SQLERRM);
309: end;
310:
311: --------------------------------------------------------------------------------
312: -- Name: LayoutRowStart
347: LayOutputLine := LayVertBorderChars;
348: end if;
349: exception
350: when others then
351: raise_application_error(-20000, 'XNP_WSGL.LayoutRowStart
'||SQLERRM);
352: end;
353:
354: --------------------------------------------------------------------------------
355: -- Name: LayoutRowEnd
395: end if;
396: LayOutputLine := '';
397: exception
398: when others then
399: raise_application_error(-20000, 'XNP_WSGL.LayoutRowEnd
'||SQLERRM);
400: end;
401:
402: --------------------------------------------------------------------------------
403: -- Name: LayoutHeader
468: end if;
469: end if;
470: exception
471: when others then
472: raise_application_error(-20000, 'XNP_WSGL.LayoutHeader
'||SQLERRM);
473: end;
474:
475: --------------------------------------------------------------------------------
476: -- Name: LayoutData
513: end if;
514:
515: exception
516: when others then
517: raise_application_error(-20000, 'XNP_WSGL.LayoutData
'||SQLERRM);
518: end;
519:
520: --------------------------------------------------------------------------------
521: -- Name: LayoutData
529: begin
530: LayoutData(to_char(p_date));
531: exception
532: when others then
533: raise_application_error(-20000, 'XNP_WSGL.LayoutData2
'||SQLERRM);
534: end;
535:
536: --------------------------------------------------------------------------------
537: -- Name: LayoutData
546: begin
547: LayoutData(to_char(p_number));
548: exception
549: when others then
550: raise_application_error(-20000, 'XNP_WSGL.LayoutData3
'||SQLERRM);
551: end;
552:
553: --------------------------------------------------------------------------------
554: -- Name: LayoutPadTextToLength
607: p_text := l_pre || p_text || l_post;
608: end if;
609: exception
610: when others then
611: raise_application_error(-20000, 'XNP_WSGL.LayoutPadTextToLength
'||SQLERRM);
612: end;
613:
614: --------------------------------------------------------------------------------
615: -- Name: DefinePageHead
626: OpenPageHead(p_title, p_bottomframe);
627: ClosePageHead;
628: exception
629: when others then
630: raise_application_error(-20000, 'XNP_WSGL.DefinePageHead
'||SQLERRM);
631: end;
632:
633: --------------------------------------------------------------------------------
634: -- Name: OpenPageHead
653: end if;
654: end if;
655: exception
656: when others then
657: raise_application_error(-20000, 'XNP_WSGL.OpenPageHead
'||SQLERRM);
658: end;
659:
660: --------------------------------------------------------------------------------
661: -- Name: ClosePageHead
671: htp.headClose;
672: end if;
673: exception
674: when others then
675: raise_application_error(-20000, 'XNP_WSGL.ClosePageHead
'||SQLERRM);
676: end;
677:
678: --------------------------------------------------------------------------------
679: -- Name: OpenPageBody
702: htp.p('');
703: end if;
704: exception
705: when others then
706: raise_application_error(-20000, 'XNP_WSGL.OpenPageBody
'||SQLERRM);
707: end;
708:
709: --------------------------------------------------------------------------------
710: -- Name: ClosePageBody
731: end if;
732: LayNumberOfPages := LayNumberOfPages - 1;
733: exception
734: when others then
735: raise_application_error(-20000, 'XNP_WSGL.ClosePageBody
'||SQLERRM);
736: end;
737:
738: --------------------------------------------------------------------------------
739: -- Name: InBottomFrame
779: begin
780: htp.header(nvl(p_headlevel, LayNumberOfPages), p_caption);
781: exception
782: when others then
783: raise_application_error(-20000, 'XNP_WSGL.DefaultPageCaption
'||SQLERRM);
784: end;
785:
786: --------------------------------------------------------------------------------
787: -- Name: BuildWherePredicate
840: -- Support user defined expression
841: elsif (substr(ltrim(l_field1), 1, 1) = '#') then
842: l_predicate := p_sli || ' ' || substr(ltrim(l_field1),2);
843: -- Special case where 'Unknown' string is entered for an optional col in a domain
844: elsif (l_field1 = MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN)) then
845: l_predicate := p_sli || ' is null';
846: -- Add
847: elsif (instr(l_field1, '%') <> 0) or (instr(l_field1, '_') <> 0) then
848: if p_datatype = TYPE_DATE then
1129: p_sli || ') ' || p_operator || ' ''' || upper(p_field) || '''';
1130: end if;
1131: exception
1132: when others then
1133: raise_application_error(-20000, 'XNP_WSGL.CaseInsensitivePredicate
'||SQLERRM);
1134: return null;
1135: end;
1136:
1137: --------------------------------------------------------------------------------
1198: end if;
1199:
1200: exception
1201: when others then
1202: raise_application_error(-20000, 'XNP_WSGL.SearchComponents
'||SQLERRM);
1203: return null;
1204: end;
1205:
1206: --------------------------------------------------------------------------------
1272: end if;
1273: LayMenuLevel := p_menu_level;
1274: exception
1275: when others then
1276: raise_application_error(-20000, 'XNP_WSGL.NavLinks
'||SQLERRM);
1277: end;
1278:
1279: --------------------------------------------------------------------------------
1280: -- Name: TablesSupported
1316:
1317: --------------------------------------------------------------------------------
1318: -- Name: EmptyPageURL
1319: --
1320: -- Description: Create URL for call to XNP_WSGL.EmptyPage
1321: --
1322: -- Parameters: p_attributes IN Body attributes
1323: --
1324: --------------------------------------------------------------------------------
1323: --
1324: --------------------------------------------------------------------------------
1325: function EmptyPageURL(p_attributes in varchar2 default null) return varchar2 is
1326: begin
1327: return 'XNP_wsgl.emptypage?P_ATTRIBUTES=' ||
1328: replace(replace(replace(p_attributes,' ','%20'),
1329: '"', '%22'),
1330: '=', '%3D');
1331: end;
1392: New_Button_JS || '; ' ||p_type||'_OnClick(this)">'')');
1393: htp.p ('//-->');
1394: htp.p ('');
1395:
1396: if XNP_WSGL.IsSupported ('NOSCRIPT')
1397: then
1398:
1399: htp.p ('
1405: end if; -- buttonJS is null
1406:
1407: exception
1408: when others then
1409: raise_application_error(-20000, 'XNP_WSGL.SubmitButton
'||SQLERRM);
1410: end;
1411:
1412: --------------------------------------------------------------------------------
1413: -- Name: RecordListButton
1456: htp.p ('document.write ('''')');
1457: htp.p('//-->');
1458: htp.p('');
1459:
1460: if XNP_WSGL.IsSupported ('NOSCRIPT')
1461: then
1462:
1463: htp.p ('
1475: '" onClick="alert(msg'||to_char(LayNumberOfRLButs)||')">'')');
1476: htp.p('//-->');
1477: htp.p('');
1478:
1479: if XNP_WSGL.IsSupported ('NOSCRIPT')
1480: then
1481:
1482: htp.p ('
1487:
1488: end if;
1489: exception
1490: when others then
1491: raise_application_error(-20000, 'XNP_WSGL.RecordListButton
'||SQLERRM);
1492: end;
1493:
1494: --------------------------------------------------------------------------------
1495: -- Name: CountHits
1594: P_DVREC.NumOfVV := I_ROWS;
1595: dbms_sql.close_cursor(I_CURSOR);
1596: exception
1597: when others then
1598: raise_application_error(-20000, 'XNP_WSGL.LoadDomainValues
'||SQLERRM);
1599: end;
1600:
1601: --------------------------------------------------------------------------------
1602: -- Name: ValidDomainValue
1617: P_VALUE in OUT NOCOPY varchar2) return boolean is
1618: I_LOOP integer;
1619: begin
1620: if not P_DVREC.Initialised then
1621: raise_application_error(-20000, 'XNP_WSGL.ValidDomainValue
'||MsgGetText(201,XNP_WSGLM.MSG201_DV_INIT_ERR));
1622: end if;
1623: -- if P_VALUE is null and P_DVREC.ColOptional then
1624: if P_VALUE is null then
1625: return true;
1653:
1654: return false;
1655: exception
1656: when others then
1657: raise_application_error(-20000, 'XNP_WSGL.ValidDomainValue
'||SQLERRM);
1658: end;
1659:
1660: --------------------------------------------------------------------------------
1661: -- Name: DomainMeaning
1675: P_VALUE in varchar2) return varchar2 is
1676: I_LOOP integer;
1677: begin
1678: if not P_DVREC.Initialised then
1679: raise_application_error(-20000, 'XNP_WSGL.DomainMeaning
'||MsgGetText(201,XNP_WSGLM.MSG201_DV_INIT_ERR));
1680: end if;
1681: if P_DVREC.UseMeanings then
1682: for I_LOOP in 1..P_DVREC.NumOfVV loop
1683: if P_VALUE = P_DVREC.Vals(I_LOOP) then
1687: end if;
1688: return P_VALUE;
1689: exception
1690: when others then
1691: raise_application_error(-20000, 'XNP_WSGL.DomainMeaning
'||SQLERRM);
1692: end;
1693:
1694: --------------------------------------------------------------------------------
1695: -- Name: DomainValue
1708: P_MEANING in varchar2) return varchar2 is
1709: I_LOOP integer;
1710: begin
1711: if not P_DVREC.Initialised then
1712: raise_application_error(-20000, 'XNP_WSGL.DomainValue
'||MsgGetText(201,XNP_WSGLM.MSG201_DV_INIT_ERR));
1713: end if;
1714: if P_DVREC.UseMeanings then
1715: for I_LOOP in 1..P_DVREC.NumOfVV loop
1716: if P_MEANING = P_DVREC.Meanings(I_LOOP) then
1720: end if;
1721: return P_MEANING;
1722: exception
1723: when others then
1724: raise_application_error(-20000, 'XNP_WSGL.DomainValue
'||SQLERRM);
1725: end;
1726:
1727:
1728: --------------------------------------------------------------------------------
1750: exception
1751: when no_data_found then
1752: return ret_array;
1753: when others then
1754: raise_application_error(-20000, 'XNP_WSGL.DomainValue2
'||SQLERRM);
1755: end;
1756:
1757: --------------------------------------------------------------------------------
1758: -- Name: BuildDVControl
1800: l_events := l_events || ' onSelect="'||P_DVREC.ColAlias||'_OnSelect(this)"';
1801: end if;
1802: end if;
1803: if not P_DVREC.Initialised then
1804: raise_application_error(-20000, 'XNP_WSGL.BuildDVControl
'||MsgGetText(201,XNP_WSGLM.MSG201_DV_INIT_ERR));
1805: end if;
1806: if P_DVREC.UseMeanings then
1807: L_DISPLAY_VAL := DomainMeaning(P_DVREC, P_CURR_VAL);
1808: else
1853: 'VALUE="'||P_DVREC.Vals(I_LOOP)||'"');
1854: end if;
1855: end loop;
1856: if P_CTL_STYLE = CTL_QUERY and P_DVREC.ColOptional then
1857: L_RET_VALUE := L_RET_VALUE || htf.formSelectOption(MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN));
1858: end if;
1859: L_RET_VALUE := L_RET_VALUE || htf.formSelectClose;
1860: elsif (P_DVREC.ControlType = DV_CHECK) and (P_CTL_STYLE <> CTL_QUERY) then
1861: if P_CURR_VAL = P_DVREC.Vals(1) then
1916: cattributes=>l_events);
1917: else
1918: L_RET_VALUE := L_RET_VALUE ||
1919: htf.formRadio('P_'||P_DVREC.ColAlias,
1920: MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN),
1921: cattributes=>l_events);
1922: end if;
1923: L_RET_VALUE := L_RET_VALUE || ' ' || MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN);
1924:
1919: htf.formRadio('P_'||P_DVREC.ColAlias,
1920: MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN),
1921: cattributes=>l_events);
1922: end if;
1923: L_RET_VALUE := L_RET_VALUE || ' ' || MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN);
1924:
1925: end if;
1926: else
1927: raise_application_error(-20000, 'XNP_WSGL.BuildDVControl
'||MsgGetText(202,XNP_WSGLM.MSG202_DV_CTL_ERR));
1923: L_RET_VALUE := L_RET_VALUE || ' ' || MsgGetText(1,XNP_WSGLM.CAP001_UNKNOWN);
1924:
1925: end if;
1926: else
1927: raise_application_error(-20000, 'XNP_WSGL.BuildDVControl
'||MsgGetText(202,XNP_WSGLM.MSG202_DV_CTL_ERR));
1928: return '';
1929: end if;
1930: return L_RET_VALUE;
1931: exception
1929: end if;
1930: return L_RET_VALUE;
1931: exception
1932: when others then
1933: raise_application_error(-20000, 'XNP_WSGL.BuildDVControl
'||SQLERRM);
1934: end;
1935:
1936: --------------------------------------------------------------------------------
1937: -- Name: BuildTextControl
1989: htf.formTextareaClose;
1990: end if;
1991: exception
1992: when others then
1993: raise_application_error(-20000, 'XNP_WSGL.BuildTextControl
'||SQLERRM);
1994: end;
1995:
1996: --------------------------------------------------------------------------------
1997: -- Name: BuildQueryControl
2038: if not p_range then
2039: return htf.formText(cname=>l_name1, csize=>p_size, cattributes=>l_events);
2040: else
2041: return htf.formText(cname=>l_name1, csize=>p_size, cattributes=>l_events) || ' ' ||
2042: htf.bold(MsgGetText(119,XNP_WSGLM.DSP119_RANGE_TO)) || ' ' ||
2043: htf.formText(cname=>l_name2, csize=>p_size, cattributes=>l_events);
2044: end if;
2045: exception
2046: when others then
2043: htf.formText(cname=>l_name2, csize=>p_size, cattributes=>l_events);
2044: end if;
2045: exception
2046: when others then
2047: raise_application_error(-20000, 'XNP_WSGL.BuildQueryControl
'||SQLERRM);
2048: end;
2049:
2050: --------------------------------------------------------------------------------
2051: -- Name: BuildDerivationControl
2087:
2088: ';
2089: exception
2090: when others then
2091: raise_application_error(-20000, 'XNP_WSGL.BuildDerivationControl
'||SQLERRM);
2092: end;
2093:
2094: --------------------------------------------------------------------------------
2095: -- Name: HiddenField
2102: begin
2103: htp.formHidden(p_paramname, replace(p_paramval,'"','"'));
2104: exception
2105: when others then
2106: raise_application_error(-20000, 'XNP_WSGL.HiddenField
'||SQLERRM);
2107: end;
2108:
2109: --------------------------------------------------------------------------------
2110: -- Name: HiddenField
2123: exception
2124: when no_data_found then
2125: null;
2126: when others then
2127: raise_application_error(-20000, 'XNP_WSGL.HiddenField2
'||SQLERRM);
2128: end;
2129:
2130: --------------------------------------------------------------------------------
2131: -- Name: DisplayMessage
2156: end if;
2157: if p_type = MESS_INFORMATION then
2158: htp.bold(l_mess);
2159: elsif p_type = MESS_SUCCESS then
2160: htp.bold(''||htf.italic(MsgGetText(121,XNP_WSGLM.DSP121_SUCCESS))||
2161: '
'||l_mess);
2162: elsif p_type = MESS_WARNING then
2163: -- NB, MESS_WARNING not used at present, just issue error message
2164: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2160: htp.bold(''||htf.italic(MsgGetText(121,XNP_WSGLM.DSP121_SUCCESS))||
2161: '
'||l_mess);
2162: elsif p_type = MESS_WARNING then
2163: -- NB, MESS_WARNING not used at present, just issue error message
2164: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2165: '
'||l_mess);
2166: elsif p_type = MESS_ERROR then
2167:
2168: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2164: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2165: '
'||l_mess);
2166: elsif p_type = MESS_ERROR then
2167:
2168: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2169: '
'||l_mess);
2170: elsif p_type = MESS_ERROR_QRY then
2171: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2172: '
');
2167:
2168: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2169: '
'||l_mess);
2170: elsif p_type = MESS_ERROR_QRY then
2171: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2172: '
');
2173: htp.bold(p_context);
2174: htp.para;
2175: htp.small(l_mess);
2177: htp.para;
2178: htp.bold(p_action);
2179: end if;
2180: elsif p_type = MESS_EXCEPTION then
2181: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2182: '
');
2183: htp.bold(MsgGetText(217,XNP_WSGLM.MSG217_EXCEPTION, p_location));
2184: htp.para;
2185: htp.p(l_mess);
2179: end if;
2180: elsif p_type = MESS_EXCEPTION then
2181: htp.bold(''||htf.italic(MsgGetText(122,XNP_WSGLM.DSP122_ERROR))||
2182: '
');
2183: htp.bold(MsgGetText(217,XNP_WSGLM.MSG217_EXCEPTION, p_location));
2184: htp.para;
2185: htp.p(l_mess);
2186: htp.para;
2187: htp.bold(MsgGetText(218,XNP_WSGLM.MSG218_CONTACT_SUPPORT));
2183: htp.bold(MsgGetText(217,XNP_WSGLM.MSG217_EXCEPTION, p_location));
2184: htp.para;
2185: htp.p(l_mess);
2186: htp.para;
2187: htp.bold(MsgGetText(218,XNP_WSGLM.MSG218_CONTACT_SUPPORT));
2188: end if;
2189: htp.para;
2190: ClosePageBody;
2191: end;
2291: CurrentURL := CurrentURL||owa_util.get_cgi_env('SCRIPT_NAME')||'/'||p_url;
2292: end if;
2293: exception
2294: when others then
2295: raise_application_error(-20000, 'XNP_WSGL.RegisterURL
'||SQLERRM);
2296:
2297: end;
2298:
2299: --------------------------------------------------------------------------------
2318: return false;
2319: exception
2320: when others then
2321:
2322: raise_application_error(-20000, 'XNP_WSGL.NotLowerCase
'||SQLERRM);
2323: return true;
2324: end;
2325:
2326: --------------------------------------------------------------------------------
2335: begin
2336: htp.p('');
2337: exception
2338: when others then
2339: raise_application_error(-20000, 'XNP_WSGL.RefreshURL
'||SQLERRM);
2340: end;
2341:
2342: --------------------------------------------------------------------------------
2343: -- Name:
2374: pos_modname := instr(lower(http_referrer), lower(substr(path_info, 1, pos_dollar)));
2375: if (pos_host <> 0 and pos_script > pos_host and pos_modname > pos_script) then
2376: return false;
2377: else
2378: DisplayMessage(MESS_ERROR, MsgGetText(231,XNP_WSGLM.MSG231_ACCESS_DENIED));
2379: return true;
2380: end if;
2381: exception
2382: when others then
2379: return true;
2380: end if;
2381: exception
2382: when others then
2383: raise_application_error(-20000, 'XNP_WSGL.ExternalCall
'||SQLERRM);
2384: return true;
2385: end;
2386:
2387: --------------------------------------------------------------------------------
2395: function CalledDirect(p_proc in varchar2) return boolean is
2396: begin
2397: URLComplete := true;
2398: if (lower(p_proc) = lower(substr(owa_util.get_cgi_env('PATH_INFO'),2))) then
2399: DisplayMessage(MESS_ERROR, MsgGetText(231,XNP_WSGLM.MSG231_ACCESS_DENIED));
2400: return true;
2401: else
2402: return false;
2403: end if;
2402: return false;
2403: end if;
2404: exception
2405: when others then
2406: raise_application_error(-20000, 'XNP_WSGL.CalledDirect
'||SQLERRM);
2407: return true;
2408: end;
2409:
2410: --------------------------------------------------------------------------------
2427: CurrentURL := CurrentURL || p_paramname || '=' || EscapeURLParam(p_paramval);
2428: end if;
2429: exception
2430: when others then
2431: raise_application_error(-20000, 'XNP_WSGL.AddURLParam
'||SQLERRM);
2432: end;
2433:
2434: --------------------------------------------------------------------------------
2435: -- Name:
2450: exception
2451: when no_data_found then
2452: null;
2453: when others then
2454: raise_application_error(-20000, 'XNP_WSGL.AddURLParam2
'||SQLERRM);
2455: end;
2456:
2457: --------------------------------------------------------------------------------
2458: -- Name:
2495: URLCookieSet := true;
2496: end if;
2497: exception
2498: when others then
2499: raise_application_error(-20000, 'XNP_WSGL.StoreURLLink
'||SQLERRM);
2500: end;
2501:
2502: --------------------------------------------------------------------------------
2503: -- Name:
2526: URLCookie := owa_cookie.get('WSG$'||modname||'URL'||next_level);
2527: CaptionCookie := owa_cookie.get('WSG$'||modname||'CAP'||next_level);
2528: if (nvl(URLCookie.num_vals,0) > 0) and (nvl(CaptionCookie.num_vals,0) > 0) then
2529: if not any_done then
2530: NavLinks(p_style, MsgGetText(20,XNP_WSGLM.CAP020_RETURN_LINKS), 0);
2531: any_done := true;
2532:
2533: end if;
2534: NavLinks(p_style, replace(CaptionCookie.vals(1),'_',' '), 1, URLCookie.vals(1));
2536: end loop;
2537: end if;
2538: exception
2539: when others then
2540: raise_application_error(-20000, 'XNP_WSGL.ReturnLinks'||'
'||SQLERRM);
2541: end;
2542:
2543: --------------------------------------------------------------------------------
2544: -- Name:
2574: function ValidateChecksum(p_buff in varchar2, p_checksum in varchar2)
2575: return boolean is
2576: begin
2577: if (nvl(to_number(p_checksum),-1) <> Checksum(p_buff)) then
2578: DisplayMessage(MESS_ERROR, MsgGetText(231,XNP_WSGLM.MSG231_ACCESS_DENIED));
2579: return false;
2580: else
2581: return true;
2582: end if;
2687:
2688: --------------------------------------------------------------------------------
2689: function MAX_ROWS_MESSAGE return varchar2 is
2690: begin
2691: return MsgGetText(203,XNP_WSGLM.MSG203_MAX_ROWS,to_char(MAX_ROWS));
2692: end;
2693: end;