[prev in list] [next in list] [prev in thread] [next in thread]
List: mason
Subject: Re: [Mason] $r declared ... where?
From: "P. Fleury" <fleury () users ! sourceforge ! net>
Date: 2003-03-03 11:47:04
[Download RAW message or body]
In Mason 1.0x, it used to be in package HTML::Mason::Commands, but in
newer version, I think it has changed.
You can do the following to check if the variable exists:
eval { $r->uri };
$m->out('no \$r variable') if $@;
I have not access to my Linux box here, so there may be typos...
--Pascal
Gareth Kirwan wrote:
> Ah - it's in the use vars declaration - but when does it then get
> assigned ?
>
> My problem is that I want to test for whether or not it's declared ...
> so that if it is then a module can do one thing ... otherwise
> something else...
>
> Gareth
>
> -----Original Message-----
> *From:* mason-users-admin@lists.sourceforge.net
> [mailto:mason-users-admin@lists.sourceforge.net]*On Behalf Of
> *Gareth Kirwan
> *Sent:* 03 March 2003 10:05
> *To:* mason-users@lists.sourceforge.net
> *Subject:* [Mason] $r declared ... where?
>
> I've been trying to test the existence of $r ( so a module can use
> it if it's declared ) - but can't find out where it is ...
> not in %::, %main or UNIVERSAL ...
>
> Cheers
>
> Gareth Kirwan
> Programming & Development,
> Thermeon Europe Ltd,
> gbjk@thermeoneurope.com <mailto:gbjk@thermeoneurope.com>
> Tel: +44 (0) 1293 864 303
> Thermeon Europe e-Card: gbjk
> <http://www.thermeoneurope.com/e-Card/?uid=gbjk>
>
>
> --
> This message has been scanned for viruses and
> dangerous content by Thermeon Europe using *MailScanner*
> <http://www.mailscanner.info/>, and is
> believed to be clean.
> --
> This message has been scanned for viruses and
> dangerous content by Thermeon Europe using *MailScanner*
> <http://www.mailscanner.info/>, and is
> believed to be clean.
>
>
> --
> This message has been scanned for viruses and
> dangerous content by Thermeon Europe using *MailScanner*
> <http://www.mailscanner.info/>, and is
> believed to be clean.
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Mason-users mailing list
Mason-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mason-users
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic