Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Perl CGI on a CD?

by dmckee (Scribe)
on Apr 05, 2001 at 22:38 UTC ( [id://70214]=perlquestion: print w/replies, xml ) Need Help??

dmckee has asked for the wisdom of the Perl Monks concerning the following question:

I'm considering making a CD index of a load of images, and feel that HTML is probably the best way of storing the information: it saves having to write an entirely new proprietary program, as well as allowing complex design and platform independance.

However, I can't see any easy ways of creating a search engine. I could install Apache and Perl, but I'd have to have copies for every different system. I could use JavaScript, but it seems an incredibly difficult way of working, especially since it can't access external files.

Quite frankly, I can't see how to proceed, with or without Perl: so I am asking for the wisdom of the Perl Monks: who else can I ask?...

Dave

Eight years involved with the nuclear industry have taught me that when nothing can possible go wrong and every avenue has been covered, then is the time to buy a house on the next continent. Terry Pratchett

Replies are listed 'Best First'.
You have static data (was: Re: Perl CGI on a CD?)
by Corion (Patriarch) on Apr 06, 2001 at 01:35 UTC

    Since your data on the CD will be static, I would use the following way :

    Write a small, simplish JavaScript search engine, which has the image and search data hardcoded as arrays. The data part of the JavaScript lands in the search.html file in <script> tags, while the "search engine" is in a separate .js file. The database is statically created via a Perl script from your main database, this of course means that you will have to modify the build process for your CDrom and run the magic database creation Perl script before burning the stuff.

    This solution would have the benefit that you can also create a static subindex (in HTML) where the images are listed after different criteria, and you essentially become platform independent (that is, as long as you don't use fancy CSS and/or fancy JavaScript).

    The other solution would be to burn IndigoPerl and the built-in Apache server on the CD, but then your users would need to start the Apache server before they could access the CD - a suboptimal solution IMO.

      Note that if you do go the Javascript route, it may also be worth the effort to make sure that you include a copy of a browser that you know works with that particular JS, unless you are absolutely sure that every user that you will be distributing this CD to has the latest and greatest in browsers. I would figure that with both IE and Netscape, there would be little problem including a copy on such a disk, but you'd have to check their respective companies on that front.
      Dr. Michael K. Neylon - mneylon-pm@masemware.com || "You've left the lens cap of your mind on again, Pinky" - The Brain
Re: Perl CGI on a CD?
by Anonymous Monk on Apr 05, 2001 at 22:50 UTC
    I've seen a search engine on a CD like you describe, it was written in Java so that it would be executed by the browser rather than a web server. You might also try JavaScript, or any other language that's recognized by your browser. Unless PerlScript is recognized by your browser, it will probably be better to code it in another language.
(Guildenstern) Re: Perl CGI on a CD?
by Guildenstern (Deacon) on Apr 05, 2001 at 23:21 UTC
    IndigoStar has a product called Microweb that lets you do just what you're asking. You can check it out here. According to the docs, it'll let you use Perl and PHP (among others) for cgis.

    Update: After a little more research, I found out that Microweb is $299 a copy. Yowch! I don't know how disabled the shareware version is, but it may be okay.

    Guildenstern
    Negaterd character class uber alles!
      Actually the shareware version is fully functional, but you get a message (This is not a registered copy...) on starting it. So you can test it thoroughly before you buy.

      neophyte Niederrhein.pm

Re: Perl CGI on a CD?
by the_slycer (Chaplain) on Apr 05, 2001 at 23:41 UTC
    O'Reilly's CD bookshelf comes with a search engine as well. You might want to poke around at their site and see if they have it available. Just by quickly glancing at it, it appears as though it's javascript though.
Re: Perl CGI on a CD?
by arturo (Vicar) on Apr 06, 2001 at 17:09 UTC

    Depends who you distribute it to, but perhaps Java might be the answer? Write the search engine as an applet. The biggest problem here is that you'd have to get permission from the users at run-time to let the applet touch stuff on their local drives.

    arturo, Perl heretic (for the moment!)

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://70214]
Approved by root
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (2)
As of 2024-04-19 20:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found