X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=bin%2Fsqlt.cgi;h=c6d89fee010b2523413e26ebcaf05ce27a42943c;hb=d0fcb05d6b4b6126e080ff90558da0cc31c06b78;hp=51ba210228e7cc6261b4c6c11cfe7ab855d06ffe;hpb=42b19e6f4403a7fbfce0f4e33b936e476407f98d;p=dbsrgits%2FSQL-Translator.git diff --git a/bin/sqlt.cgi b/bin/sqlt.cgi index 51ba210..c6d89fe 100755 --- a/bin/sqlt.cgi +++ b/bin/sqlt.cgi @@ -1,9 +1,9 @@ #!/usr/bin/perl # ------------------------------------------------------------------- -# $Id: sqlt.cgi,v 1.2 2003-08-27 04:01:14 kycl4rk Exp $ +# $Id$ # ------------------------------------------------------------------- -# Copyright (C) 2003 Ken Y. Clark +# 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 @@ -38,9 +38,6 @@ use strict; use CGI; use SQL::Translator; -use vars '$VERSION'; -$VERSION = sprintf "%d.%02d", q$Revision: 1.2 $ =~ /(\d+)\.(\d+)/; - my $q = CGI->new; eval { @@ -60,7 +57,7 @@ eval { ? $q->param('diagram_output_type') : $producer eq 'GraphViz' ? $q->param('graphviz_output_type') - : 'png' + : '' ; my $t = SQL::Translator->new( @@ -110,6 +107,9 @@ eval { 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"; @@ -544,10 +544,11 @@ sub show_form { =head1 AUTHOR -Ken Y. Clark Ekclark@cpan.orgE +Ken Y. Clark Ekclark@cpan.orgE. =head1 SEE ALSO -perl, SQL::Translator. +L, +L =cut