• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 275
  • Last Modified:

Writing text string so that it is a hyperlink to a file

I'm am writing summary information about input files to an output file (currently a text file). I'd like to allow a user to click on information of interest in the output file and have it hyperlink to the file the information refers to.

I guess I have to change my output file to an HTML file? What is the least painful way to create such an output file? Is there a way to easily write a string of text to the output file and declare it as a hyperlink to a file (or to anything I want)?
0
jobhelp
Asked:
jobhelp
1 Solution
 
ahoffmannCommented:
use CGI;
my $q=new CGI;
print $q->header, $q->start_html, "your text", $q->a({href=>"http://you.tld/lpath/link"}, "click me"), end_html;
exit (0);
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now