in reply to Re^2: Create a html page on fly
in thread Create a html page on fly

Once you have created the HTML file you need to print the location of the new file as a URL, something like:
... close $htmlout; my $url = "http://example.com/directory/$filename"; print "Location: $url\n\n";