#!/usr/bin/perl
# -------------------------------------------------------------------
-# $Id: sqlt.cgi,v 1.2 2003-08-27 04:01:14 kycl4rk Exp $
+# $Id$
# -------------------------------------------------------------------
-# Copyright (C) 2003 Ken Y. Clark <kclark@cpan.org>
+# Copyright (C) 2002-2009 SQLFairy Authors
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
use CGI;
use SQL::Translator;
-use vars '$VERSION';
-$VERSION = sprintf "%d.%02d", q$Revision: 1.2 $ =~ /(\d+)\.(\d+)/;
-
my $q = CGI->new;
eval {
? $q->param('diagram_output_type')
: $producer eq 'GraphViz'
? $q->param('graphviz_output_type')
- : 'png'
+ : ''
;
my $t = SQL::Translator->new(
elsif ( $output_type eq 'ps' ) {
$text_type = 'postscript';
}
+ elsif ( $producer eq 'HTML' ) {
+ $text_type = 'html';
+ }
my $header_type = $image_type ? "image/$image_type" : "text/$text_type";
=head1 AUTHOR
-Ken Y. Clark E<lt>kclark@cpan.orgE<gt>
+Ken Y. Clark E<lt>kclark@cpan.orgE<gt>.
=head1 SEE ALSO
-perl, SQL::Translator.
+L<perl>,
+L<SQL::Translator>
=cut