Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

HTML::Template

by Anonymous Monk
on Sep 13, 2001 at 19:05 UTC ( #112206=perlquestion: print w/replies, xml ) Need Help??
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I want to use this module on my site, but my web host won't install this module how do I install it locally so I have access to HTML::Template???

Replies are listed 'Best First'.
Re: HTML::Template
by Graham (Deacon) on Sep 13, 2001 at 19:17 UTC
    Firstly, I assume you have some form of shell account on this host so you can install locally.

    perlfaq8 has the answer under How do I keep my own module/library directory?

Re: HTML::Template
by George_Sherston (Vicar) on Sep 13, 2001 at 19:12 UTC
    Get a copy from CPAN, then save it in a directory you do have access to and put
    BEGIN {unshift @INC, 'path'}
    at the start of your script, where "path" is the filepath from where your script is to the directory where you installed the module. @INC contains tells perl where to look for modules that you use, so after you've done that you should be able to call the module the same way you call pre-installed modules.

    Hope that works for you the way it works for me!

    George Sherston
        Yes, and as princepawn /msg'd me, it also gives access to modules in sub paths, so all round a better answer. Just goes to show, new lessons to be had everywhere :)

        George Sherston
Re: HTML::Template
by MZSanford (Curate) on Sep 13, 2001 at 19:13 UTC
    you could install the module into a directory under your home directory, and then add a use lib '/home/dir/lib'; line to each script. To install the module in a special place can usually be done with the following (if i recall):
    perl Makefile.PL PREFIX=/home/dir/lib make make test make install

    my own worst enemy
    -- MZSanford
Re: HTML::Template
by Zaxo (Archbishop) on Sep 13, 2001 at 19:15 UTC

    You can install any modules you need in your home directory. You should read the CPAN.pm docs to see how to set up the build environment. That done, say use lib 'wherever'; to include that location in the search path.

    After Compline,
    Zaxo

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://112206]
Approved by root
help
Chatterbox?
[perldigious]: Also coincidentally, I'm currently in the middle of a winter storm that has dropped 1 foot of snow and is expected to drop another. I might have to adapt this for customers/vendors who come visit and put it at the beggining of every presentation I give.
[Discipulus]: the photo was removed... Cyrano de Berjerac was not of the same idea..
[stevieb]: perldigious: video near our hq in Montreal. Here in Calgary, it's -28c... we've only got 3" of snow so far, but there are several feet in the mountains already
[perldigious]: Snowshoeing time stevieb? I need to buy a pair so I can walk my German Shepherd properly through the country.

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (11)
As of 2016-12-06 16:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (112 votes). Check out past polls.