-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c56a7c6
commit f43821a
Showing
7 changed files
with
97 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
src/E4W/ZfcUser/RedirectUrl/Factory/Options/ModuleOptionsFactory.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?php | ||
|
||
namespace E4W\ZfcUser\RedirectUrl\Factory\Options; | ||
|
||
use E4W\ZfcUser\RedirectUrl\Options\ModuleOptions; | ||
use Zend\ServiceManager\FactoryInterface; | ||
use Zend\ServiceManager\ServiceLocatorInterface; | ||
|
||
class ModuleOptionsFactory implements FactoryInterface | ||
{ | ||
/** | ||
* Create options | ||
* | ||
* @param ServiceLocatorInterface $serviceLocator | ||
* @return SocialService | ||
*/ | ||
public function createService(ServiceLocatorInterface $serviceLocator) | ||
{ | ||
$config = $serviceLocator->get('Config'); | ||
|
||
$service = new ModuleOptions($config['e4wzfcuserredirecturl']); | ||
return $service; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,31 @@ | ||
<?php | ||
/** | ||
* Created by PhpStorm. | ||
* User: Danielss89 | ||
* Date: 09/07/14 | ||
* Time: 10:39 | ||
*/ | ||
|
||
namespace E4W\ZfcUser\RedirectUrl\Options; | ||
|
||
use Zend\Stdlib\AbstractOptions; | ||
|
||
class ModuleOptions extends AbstractOptions | ||
{ | ||
/** | ||
* Array of urls which is allowed redirecting to. | ||
* @var array | ||
*/ | ||
protected $whitelist; | ||
|
||
/** | ||
* @param array $whitelist | ||
*/ | ||
public function setWhitelist($whitelist) | ||
{ | ||
$this->whitelist = $whitelist; | ||
} | ||
|
||
/** | ||
* @return array | ||
*/ | ||
public function getWhitelist() | ||
{ | ||
return $this->whitelist; | ||
} | ||
|
||
} |