Ignore:
Timestamp:
2000-11-21T16:33:05+13:00 (23 years ago)
Author:
paynter
Message:

Supports rtf file as an input type, looks in packages dir for pdftohtml

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/bin/script/gsConvert.pl

    r1654 r1684  
    9999    elsif ($input_type eq "doc") {
    100100    print &convertDOC($input_filename, $output_filestem, $output_type);
     101    print "\n";
     102    }
     103    elsif ($input_type eq "rtf") {
     104    print &convertRTF($input_filename, $output_filestem, $output_type);
    101105    print "\n";
    102106    }
     
    394398    ($dirname, $input_filename, $output_filestem) = @_;
    395399
    396     $cmd = "pdftohtml -F -d $dirname -o \"$output_filestem.html\" \"$input_filename\"";
    397     $cmd .= " > $output_filestem.out";
    398    
     400    # formulate the command
     401    my $p_home = &util::filename_cat($ENV{'GSDLHOME'}, "packages", "unix", "pdftohtml");
     402    my $pdftohtml = &util::filename_cat($p_home, "pdftohtml_0_20", "pdftohtml.bin");
     403    return 0 unless (-e "$pdftohtml");
     404
     405    $cmd = "ulimit -t 20;";
     406    $cmd .= "$pdftohtml -noframes";
     407    $cmd .= " \"$input_filename\" \"$output_filestem.html\"";
     408    $cmd .= " >\"$output_filestem.out\" 2>\"$output_filestem.err\"";
     409
    399410    if (system($cmd)>0)
    400411    {
Note: See TracChangeset for help on using the changeset viewer.