PHPackages                             updatemi/imagex - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Image &amp; Media](/categories/media)
4. /
5. updatemi/imagex

AbandonedArchivedLibrary[Image &amp; Media](/categories/media)

updatemi/imagex
===============

A simple image service which support cropping with a focus point

12.6kPHP

Since Sep 2Pushed 9y ago2 watchersCompare

[ Source](https://github.com/IWAtech/imagex)[ Packagist](https://packagist.org/packages/updatemi/imagex)[ RSS](/packages/updatemi-imagex/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

imagex - Lean Image Service
===========================

[](#imagex---lean-image-service)

Requirements
------------

[](#requirements)

- PHP &gt;= 5.5
- PHP-Extension Imagick

Installation
------------

[](#installation)

- Copy all included files to server destination of your choice
- Create following folders and make sure that your web server has write permissions for these -- cache/source -- cache/thumbs
- Setup following command as cron job to clean up local cache directories periodically: -- find ./cache -mtime +30 -type f -delete

#### Optional Apache Config for clean URLs

[](#optional-apache-config-for-clean-urls)

If you have mod\_rewrite installed on your Apache server you can use following rewrite rule to enable clean URLs for the imagex service:

```
  RewriteRule (crop|resize)\/([0-9]*)\/([0-9]*)(\/([-+]?[0-1]+\.?[0-9]*)\/([-+]?[0-1]+\.?[0-9]*))?\/([A-Za-z0-9+/=]+)(:(nocache))?$ %{ENV:BASE}/imagex.php?mode=$1&width=$2&height=$3&x=$5&y=$6&url=$7&cache=$9 [NE,L]

```

After an apache restart you can also use imagex with URLs like the following:

```
http://my.domain.com/crop/400/280/0.18/0.25/http://upload.wikimedia.org/wikipedia/commons/e/e9/Official_portrait_of_Barack_Obama.jpg

```

Usage
-----

[](#usage)

```
http://my.domain.com/imagex.php?url=http://upload.wikimedia.org/wikipedia/commons/e/e9/Official_portrait_of_Barack_Obama.jpg&mode=crop&width=400&height=280&x=0.18&y=0.25

```

Parameters
----------

[](#parameters)

The following 6 parameters are currently available:

#### url *(required)*

[](#url-required)

The url of the image you want to resize/crop/proxy. *You can also base64-encode the url parameter if you like.*

#### mode

[](#mode)

Currently two modes are available: *"resize"* and *"crop"*. Default is *"resize"*.

#### width

[](#width)

Width of the resulting image. If no width is specified width will be scaled proportionally to the request height. If neither width nor height are specified the image will simply be proxied.

#### height

[](#height)

Height of the resulting image. If no height is specified width will be scaled proportionally to the request width. If neither width nor height are specified the image will simply be proxied.

#### x

[](#x)

X-coordinate of the focus point used for cropping the image. Value must be between *-1* and *1*. Default is 0 - the middle of the axis. See below for more information about the focus point functionality.

#### y

[](#y)

Y-coordinate of the focus point used for cropping the image. Value must be between *-1* and *1*. Default is 0 - the middle of the axis. See below for more information about the focus point functionality.

More details about the focus point
----------------------------------

[](#more-details-about-the-focus-point)

This is basically implemented the same way as in the \[[https://github.com/jonom/jquery-focuspoint\](jquery-focuspoint](https://github.com/jonom/jquery-focuspoint](jquery-focuspoint) plugin):

> An image's focus point is made up of x (horizontal) and y (vertical) coordinates. The value of a coordinate can be a number with decimal points anywhere between -1 and +1, where 0 is the centre. X:-1 indicates the left edge of the image, x:1 the right edge. For the y axis, y:1 is the top edge and y:-1 is the bottom.
>
> [![image](https://raw.githubusercontent.com/jonom/jquery-focuspoint/master/demos/img/grid.png)](https://raw.githubusercontent.com/jonom/jquery-focuspoint/master/demos/img/grid.png)
>
> **Confused?** Don't worry, there's a handy script included to help you find the focus coordinates of an image with a single click. Check out the [helper tool](http://jonom.github.io/jquery-focuspoint/demos/helper/index.html) *(vastly improved courtesy of [@auginator](https://github.com/auginator)).*

###  Health Score

24

—

LowBetter than 32% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/9d315dec67e8e667729909198c985532ec24023b767308a26261d89d3da3ba73?d=identicon)[kl4n4](/maintainers/kl4n4)

---

Top Contributors

[![000panther](https://avatars.githubusercontent.com/u/499094?v=4)](https://github.com/000panther "000panther (1 commits)")

---

Tags

cropimage-processingimagexphp

### Embed Badge

![Health badge](/badges/updatemi-imagex/health.svg)

```
[![Health](https://phpackages.com/badges/updatemi-imagex/health.svg)](https://phpackages.com/packages/updatemi-imagex)
```

###  Alternatives

[milon/barcode

Barcode generator like Qr Code, PDF417, C39, C39+, C39E, C39E+, C93, S25, S25+, I25, I25+, C128, C128A, C128B, C128C, 2-Digits UPC-Based Extention, 5-Digits UPC-Based Extention, EAN 8, EAN 13, UPC-A, UPC-E, MSI (Variation of Plessey code)

1.5k13.3M39](/packages/milon-barcode)[bkwld/croppa

Image thumbnail creation through specially formatted URLs for Laravel

510496.0k23](/packages/bkwld-croppa)[goat1000/svggraph

Generates SVG graphs

132849.6k3](/packages/goat1000-svggraph)[cohensive/embed

Media Embed (for Laravel or as a standalone).

120370.4k](/packages/cohensive-embed)[netresearch/rte-ckeditor-image

Image support in CKEditor for the TYPO3 ecosystem - by Netresearch

63991.3k4](/packages/netresearch-rte-ckeditor-image)[humanmade/tachyon-plugin

Rewrites WordPress image URLs to use Tachyon

87338.5k2](/packages/humanmade-tachyon-plugin)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
