Solved

can perl access CD-ROMS

Posted on 1998-06-03
4
146 Views
Last Modified: 2010-03-04
hello everyone
i dont think this is exactly a Perl question but, is there some way to access CD-ROM information via the web...im looking for any information on any of the ways to do this...basically all i need to know is if a person who requests a certain predefined file from their browsser can be delivered this file from a CD back to thier browser...
0
Comment
Question by:wired
  • 2
4 Comments
 
LVL 2

Accepted Solution

by:
tpryor earned 50 total points
Comment Utility
Yes you can, as long as you have the correct correct path to the file on the cd rom, using server redirection. In perl simply...
print "Location: $file_path", "\n\n";

thats it,
t
0
 
LVL 84

Expert Comment

by:ozo
Comment Utility
That would tell your browser to access the file if $file_path is a URL for the file
You'd get the same thing if you typed $file_path as the URL in your browser
if you want your Perl program to access the file, you can
  open(FILEHANDLE,"<$file_path") or die "Can't open $file_path because $!");

0
 

Author Comment

by:wired
Comment Utility
thank you!
0
 
LVL 2

Expert Comment

by:tpryor
Comment Utility
Both work.
It depends on what you want to do.
If you need to pre-process the file or wrap it in a html header and footer then the way ozo suggested is the way to go.
If no preprocessing is nessasary then use my way it will just serve it up as is.

t
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

I've just discovered very important differences between Windows an Unix formats in Perl,at least 5.xx.. MOST IMPORTANT: Use Unix file format while saving Your script. otherwise it will have ^M s or smth likely weird in the EOL, Then DO NOT use m…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now