Return-Path: Delivered-To: apmail-perl-embperl-archive@perl.apache.org Received: (qmail 36568 invoked by uid 500); 4 Apr 2001 18:22:38 -0000 Mailing-List: contact embperl-help@perl.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Delivered-To: mailing list embperl@perl.apache.org Received: (qmail 36524 invoked from network); 4 Apr 2001 18:22:35 -0000 Message-ID: <3ACB6664.72ACF65@spamless.genwax.com> Date: Wed, 04 Apr 2001 11:22:28 -0700 From: ___cliff rayman___ X-Mailer: Mozilla 4.75 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: =?iso-8859-1?Q?St=E9phane?= Peiry , embperl@perl.apache.org Subject: Re: $udat initialisation References: <3ACB5697.4060801@colt.ch> Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N the tied %udat does a shallow check to see if anything needs to be stored. i think most of us who use it do something like this in code that changes %udat: $udat:{TIME}=time; this guarantees that the shallow check will be successful and that the tied %udat is stored in the session. you can invoke a session write directly if you prefer, see the documenation. -- ___cliff rayman___cliff@genwax.com___http://www.genwax.com/ St�phane Peiry wrote: > Hi Everybody, > > Are there any known problems with $udat initialisation? > > As example I have the file 'one.html' which contains the following > (Embperl code): > > [- > $hold{thing} = "Hello"; > $udat{some} = {%hold}; > -] > > [+ $udat{some}{thing} +] > > (I use %hold because.. I cannot initialize directly $udat as > $udat{some}{thing} = "Hello" .. am I missing something..?) > > File 'two.html' (wich I call afther one.html) contains: > > [+ $udat{some}{thing} +] > > Hence I would expect this last one to print out "Hello", if I > had previously made a call to 'one.html'. But it doesnt, it > prints the following error msg: > > Can't use an undefined value as a HASH reference at > /usr/local/apache/htdocs/monitoring/two.html line 2 > > Anyway, if I write a third file 'three.html' wich contains > just a line more than the 'two.html': > > [- $udat{blahblah} = "blahblah" -] > [+ $udat{some}{thing} +] > > then it answers appropriatly "Hello" wich is what I wanted in the first > place.... > Why is it so? > > Thanks for any help/infos/comments on this, > St�phane > > --------------------------------------------------------------------- > To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org > For additional commands, e-mail: embperl-help@perl.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org For additional commands, e-mail: embperl-help@perl.apache.org