"Zentara" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On Mon, 3 Mar 2003 16:07:26 -0500, [EMAIL PROTECTED] (Todd Wade) wrote:
>
> >
> >"Zentara" <[EMAIL PROTECTED]> wrote in message
> >>
> >> You might want to try assigning a variable name to param("quantity")
> >> first, before you set up the table. I don't know why, but sometimes
> >> the scripts don't like it any other way. I've run into this type of
> >> thing before, and just take the easy way out, and assign a variable.
> >
> >This is not true at all.
>
> Well what ever the reason is, it has worked that way sometimes for me.
> When you start deeply nesting and quoting in tables and here documents,
> Perl will sometimes fail to interpolate unless you force the value into
> a variable.  I guess I havn't learned the trick yet.

Sorry, not true at all. There really is no trick. Interpolating is
interpolating is interpolating.

When you start ?deeply nesting? and quoting in tables and here documents,
perl will never fail to interpolate unless you don't understand the syntax
and semantics of injecting values into literals.

Perhaps you could post an example, because I am very curious. But taking an
educated guess at the problem you are having, I would say you are talking
about getting CGI.pm's param() function to return in a string.

my( $string ) = "you ordered $q->param('quantity') foobars\n";

The quoting mechanism knows nothing about evaluating expressions. That's
what concatenation is for:

my( $string ) = "you ordered " . $q->param('quantity') . " foobars\n";

Todd W.



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to