[ic] Embedding Perl Problem
Stefan Hornburg
racke@linuxia.de
05 Dec 2000 09:02:48 +0100
Doug Alcorn <doug@lathi.net> writes:
> "Dallas Vogels" <dvogels@forestind.com> writes:
>
> > ------------------------------------------
> > [perl]
> > $Config->{PriceField} = 'can_price';
> > [perl]
> > ------------------------------------------
> >
> > The code sits in a HTML page however the text 'can_price' (with out the
> > single quotes) is output on the HTML page. How do I stop this from
> > happening?
>
> The [perl] tag outputs the page the result of the last command
> executed inside the tags (much like the return value of a perl
> subroutine).
Every Perl sub does this.
sub {return "bla";} is equivalent to sub {"bla";}
> I think common practice is to 'return "";' as the last
> part of your [perl] tag if you don't want any output in your page.
Just ''; suffices.
Ciao
Racke
--
LinuXia Systems && Cobolt NetServices, eCommerce and more
Shop- und Datenbanklösungen mit MiniVend, Firewalls auf Debian-Basis
http://www.linuxia.de - http://www.cobolt.net
--> Junior Officer of the MiniVend/Interchange Bug Patrol <---