You are here

function imagecrop_get_style_name_from_url in Image javascript crop 7

Get the style name from the current requested url.

1 call to imagecrop_get_style_name_from_url()
imagecrop_effect in includes/imagecrop.effects.inc
Image effect callback: Crop the image based on the javascript selected crop.

File

./imagecrop.module, line 628
Provides a javascript toolbox through an imagecache action.

Code

function imagecrop_get_style_name_from_url() {
  $args = explode('/', $_GET['q']);
  $key = array_search('styles', $args);
  if ($key != FALSE) {
    return $args[$key + 1];
  }
  return 0;
}