Aspose.Imaging Java For PHP

Introduction to Aspose.Imaging Java for PHP

PHP / Java Bridge

The PHP/Java Bridge is an implementation of a streaming, XML-based network protocol, which can be used to connect a native script engine, for example PHP, Scheme or Python, with a Java virtual machine. It is up to 50 times faster than local RPC via SOAP, requires less resources on the web-server side. It is faster and more reliable than direct communication via the Java Native Interface, and it requires no additional components to invoke Java procedures from PHP or PHP procedures from Java.

Read more at sourceforge.net

Aspose.Imaging for Java

Aspose.Imaging for Java is an imaging library that lets developers create, edit, draw or convert images in their Java applications with ease and performance. It offers broad spectrum of traditional image processing operations as well as most demanded features that makes it most widely used imaging engine.

Aspose.Imaging Java for PHP

Project Aspose.Imaging Java for PHP shows how different tasks can be performed using Aspose.Imaging Java APIs in PHP. This project is aimed to provide useful examples for PHP developers who want to utilize Aspose.Imaging for Java in their PHP Projects using PHP Java Bridge.

System Requirements and Supported Platforms

System Requirements

Following are the system requirements to use Aspose.OCR Java for PHP:

  • Tomcat Server 8.0 or above installed.
  • PHP/JavaBridge is configured.
  • FastCGI is installed.
  • Downloaded Aspose.OCR component.

Supported Platforms

Following are the supported platforms:

  • PHP 5.3 or above
  • Java 1.8 or above

Downloads & Configure

Download Required Libraries

Download required libraries mentioned below. These are the required for executing Aspose.Imaging Java for PHP examples.

Download Examples from Social Coding Sites

Following releases of running examples are available to download on below mentioned social coding sites:

GitHub

Installation And Usage

Installing

It is very simple and easy to install Aspose.Imaging Java for PHP, please follow these simple steps:

  1. Run following command.
 $ gem install asposeimagingjava
  1. Download required Aspose.Imaging for Java Component from following link. https://downloads.aspose.com/imaging/java
  2. Create “jars” folder at root of the Aspose.Imaging Java for PHP and copy downloaded component into it.

Using

Include the required files to export image to different formats.

 require File.dirname(File.dirname(File.dirname(__FILE__))) + '/lib/asposeimagingjava'

include Asposeimagingjava

include Asposeimagingjava::ExportImageToDifferentFormats

initialize_aspose_imaging

Let’s understand the above code.

  1. The first line makes sure that the Aspose.Imaging is loaded and available.
  2. Include the files that are required to access the Aspose.Imaging
  3. Initialize the libraries. The Aspose Java classes are loaded from the path provided in the aspose.yml file