Main Stories
Slash Boxes

Slash Open Source Project

Slashcode Log In

Log In

[ Create a new account ]

Article Poll

Poll I found this article to be
Very Helpful
Not Helpful
Not Very Helpful
[ Results | Polls ]
Comments:0 | Votes:1

Using [% PERL %] in templates?

posted by Krow on 06:16 AM June 6th, 2002   Printer-friendly   Email story
I am trying to add some perl to my templates, but every time I do, I get an error.

perl error - EVAL_PERL not set

I have read the TT docs and can't figure out how to combine their instructions with the setup of slash.

Has anyone figured out where or how to properly set EVAL_PERL?

This discussion has been archived. No new comments can be posted.
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login
Loading... please wait.
  • I'm not sure if this is the correct solution or not, but what I did was added it to the blocks where TT is configured in Slash/ In the version of I have ( 2001/10/19), I inserted the line:

    EVAL_PERL => 1,

    At lines 341 and 352.

    I hope this helps!

    • Thanks, however that was what I tried first.

      Still generates the error.

      any other ideas?

      • by Anonymous Coward
        If you are running under mod_perl, have you restarted httpd after editing the Perl module?
        • It was pointed out to me that slashcode explicitly disables the use of [% PERL %] in templates (some sort of security issue).

          So after much digging around I realized that the real way to handle my problem was to write my perl into one of the template toolkit perl modules and just call that function from the template. Works great.