GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - unidoc/unipdf-examples: Examples for creating and processing PDF files with UniPDF https://github.com/unidoc/unipdf

BranchesTags
Open more actions menu

Latest commit

 

History

608 Commits
608 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
accessibility
accessibility
 
 
advanced
advanced
 
 
analysis
analysis
 
 
annotations
annotations
 
 
arabic-text
arabic-text
 
 
attachment
attachment
 
 
barcode
barcode
 
 
compress
compress
 
 
concurrent-processing
concurrent-processing
 
 
drawing
drawing
 
 
extract-bullet-lists
extract-bullet-lists
 
 
extract
extract
 
 
forms
forms
 
 
grayscale
grayscale
 
 
grid
grid
 
 
hebrew-text
hebrew-text
 
 
image
image
 
 
invoice
invoice
 
 
javascript
javascript
 
 
jbig2
jbig2
 
 
license
license
 
 
metadata
metadata
 
 
multi-font-encoder
multi-font-encoder
 
 
ocr
ocr
 
 
outlines
outlines
 
 
pages
pages
 
 
pdfa
pdfa
 
 
redact
redact
 
 
render
render
 
 
report
report
 
 
sanitize
sanitize
 
 
search-and-replace
search-and-replace
 
 
security
security
 
 
signatures
signatures
 
 
svg
svg
 
 
table-info
table-info
 
 
tables
tables
 
 
templates
templates
 
 
testing
testing
 
 
text
text
 
 
watermarks
watermarks
 
 
writer
writer
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
build_examples.sh
build_examples.sh
 
 
go.mod
go.mod
 
 
go.sum
go.sum
 
 

Repository files navigation

Examples

This example repository demonstrates many use cases for UniDoc's UniPDF library. Example code should make it easy for users to get started with UniPDF. Feel free to add to this by submitting a pull request.

While the majority of examples are fully in pure Go, there are a few examples that demonstrate additional functionality that requires CGO and external dependencies. Those examples are clarified by filename suffix "_cgo.go".

Disclaimer

IMPORTANT: The code examples provided in this repository are for educational and demonstration purposes only. They are provided "as is" without warranty of any kind, either express or implied. These examples are intended to help developers understand how to use the UniPDF library and may not be suitable for production environments without additional security hardening, error handling, and testing.

UniDoc (the maintainers of this repository) shall not be held responsible for any risks, damages, or issues arising from the use of these code examples in production or any other environment. Users are solely responsible for reviewing, testing, and adapting the code to meet their specific requirements and security standards before deploying to production systems.

It is strongly recommended that you:

  • Conduct thorough security reviews and testing
  • Implement proper input validation and sanitization
  • Add appropriate error handling and logging
  • Follow security best practices for your specific use case
  • Consult with security professionals when handling sensitive data

License codes

UniPDF requires license codes to operate, there are two options:

  • Metered License API keys: Free ones can be obtained at https://cloud.unidoc.io
  • Offline codes: Can be purchased at https://unidoc.io/pricing

Most of the examples demonstrate loading the Metered License API keys through an environment variable UNIDOC_LICENSE_API_KEY.

Examples for Offline License Key loading can be found in the license subdirectory.

Build all examples

Building with go modules:

Simply run the build script which builds all the binaries to subfolder bin/

$ ./build_examples.sh

Building with GOPATH:

Building with GOPATH requires a slightly different approach due to the /v5 semantic import portion of the unipdf import paths. There are two options:

Both options start with:

  • go get github.com/unidoc/unipdf/... to download the packages

Then one can decide between the two options:

  1. Remove the /v5/ in the unipdf import paths, e.g. use github.com/unidoc/unipdf/core instead of github.com/unidoc/unipdf/v5/core
  2. Alternatively create a symbolic link from the v5 subdirectory of unipdf to the unipdf repository, i.e.
ln -s $GOPATH/src/github.com/unidoc/unipdf $GOPATH/src/github.com/unidoc/unipdf/v5

or move/copy the unipdf folder to unipdf/v5 if symbolic links are not an option.

Once this has been done, then can build using the build script as well:

$ ./build_examples.sh

or build individual example codes as desired.

About

Examples for creating and processing PDF files with UniPDF https://github.com/unidoc/unipdf

unidoc.io

Resources

Readme

Security policy

Security policy
Activity
Custom properties

Stars

307 stars

Watchers

12 watching

Forks

106 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.