Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: URGENTLY in need of COOKIE help
Hi Dwight
> Procedure COOKIE_CHECK (company out varchar2)
> IS
> cook_comp owa_cookie.cookie;
> cook_date owa_cookie.cookie;
> BEGIN
> cook_comp := owa_cookie.get('cCompany');
> cook_date := owa_cookie.get('cDate');
> IF cook_comp.num_vals >0 THEN
> company := cook_comp.vals(1);
> IF (substr(cook_date.vals(1),0,4) <> to_char(sysdate, 'DDYY')) THEN
> owa_util.redirect_url('http://bl.mcit.com');
> END IF;
> Else
> owa_util.redirect_url('http://bl.mcit.com');
> END IF;
> END;
Everything looks in order.
There are probably two things that could be a problem: 1. You say all applications are in the same domain, have you had a look at the cookies file to see if the domain values are identical. 2. The owa_cookie.get cannot read the cookie from the cookies file because it might be written with different parameters, format etc.
A possible workaround is to call an asp procedure from your machine using utl_http.request_pieces(url); to check the cookie. This allows you to call other html files/cgi scripts from within your procedure. OR if all else fails you could do a straight redirection from your PL/SQL to the asp apps and let them handle it and redirect the client back if neccesaary.
-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum Received on Wed Sep 23 1998 - 00:27:32 CDT