Skip to content

guiquansun/PDF-Compactor

Repository files navigation

PDF Compactor Project

a web application that allows users to upload a pdf file and return a compacted version of the file based on the user's specified DPI.

Features

  • Compress the uploaded pdf file accroding to the radio box or the dpi entered by client
  • Show the original size and the compressed size on the page
  • History page helps clients check and download the pdf files(both original and compressed) uploaded by themselves
  • Initial page tells clients the number of times the page has finished processing so far
  • When the uploaded file is not a pdf file, or the pdf file size is bigger than 30 mb, the client will see the corresponding error

Implementation Overview

frontend

  • upload pdf file from client's computer
  • user determine the dpi used for compression

backend

  • store the uploaded file in sever
  • execute the compression command based on the client's requirement
  • delete history files (both original and compressed)

Process Of the whole full_stack

frontend-backend-diagram.png

Tools

Frontend

Bootstrap + HTML + JQuery + CSS

Backend

Node.js + express + multer + Ghostscript

The pdf compression rools URL

https://github.com/ourarash/shrinkpdf

Start The Project

git clone https://github.com/guiquansun/PDF-Compactor.git 
cd PDF-Compactor
npm install
  • Run:
node app.js
  • Test:
npm test

first-page

- Upload a pdf file and the page is switched.

second-page

- Click Process button to do the compression

third-page

- See your history files

fourth-page

Future Work

  • Upload multiple files simultaneously by users, and compress these files by backend server.
  • Upload files from Google Drive or Dropbox
  • Use other PDF compression tools that are more efficient and have higher speed.

Group members

Linxin Mai linxinma@usc.edu

Guiquan Sun gsun@usc.edu

YouTube link:

https://www.youtube.com/watch?v=6Zd7mUN6C9A&feature=youtu.be

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published