From a16743a23023e24039a66a4ffffee7709c15e364 Mon Sep 17 00:00:00 2001 From: lackovic10 Date: Thu, 26 Sep 2013 20:38:39 +0200 Subject: [PATCH] added background_images to configuration --- DependencyInjection/Configuration.php | 1 + Generator/CaptchaGenerator.php | 3 +++ 2 files changed, 4 insertions(+) diff --git a/DependencyInjection/Configuration.php b/DependencyInjection/Configuration.php index 9f9fbd5..1ffc7e2 100644 --- a/DependencyInjection/Configuration.php +++ b/DependencyInjection/Configuration.php @@ -44,6 +44,7 @@ class Configuration implements ConfigurationInterface ->scalarNode('interpolation')->defaultValue(true)->end() ->arrayNode('text_color')->prototype('scalar')->end()->end() ->arrayNode('background_color')->prototype('scalar')->end()->end() + ->arrayNode('background_images')->prototype('scalar')->end()->end() ->end() ; diff --git a/Generator/CaptchaGenerator.php b/Generator/CaptchaGenerator.php index 60db59b..e997c67 100644 --- a/Generator/CaptchaGenerator.php +++ b/Generator/CaptchaGenerator.php @@ -120,6 +120,9 @@ class CaptchaGenerator $fingerprint = isset($options['fingerprint']) ? $options['fingerprint'] : null; + // set background images + $this->builder->setBackgroundImages($options['background_images']); + $content = $this->builder->build( $options['width'], $options['height'],