GetViewHelper.php 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. namespace Opentalent\OtTemplating\ViewHelpers\Request;
  3. use Closure;
  4. use TYPO3Fluid\Fluid\Core\Rendering\RenderingContextInterface;
  5. use TYPO3Fluid\Fluid\Core\ViewHelper\AbstractViewHelper;
  6. /**
  7. * Returns the current GET request as an array.
  8. *
  9. * {namespace ot=Opentalent\OtTemplating\ViewHelpers}
  10. *
  11. * {ot:request.get()}
  12. *
  13. * @package Opentalent\OtTemplating\ViewHelpers
  14. */
  15. class GetViewHelper extends AbstractViewHelper {
  16. /**
  17. * -- This method is expected by Fluid --
  18. * Declares the viewhelper's parameters
  19. */
  20. public function initializeArguments()
  21. {
  22. }
  23. /**
  24. * -- This method is expected by Fluid --
  25. * Renders the content as html
  26. *
  27. * @param array $arguments
  28. * @param Closure $renderChildrenClosure
  29. * @param RenderingContextInterface $renderingContext
  30. * @return array|null
  31. */
  32. public static function renderStatic(
  33. array $arguments,
  34. Closure $renderChildrenClosure,
  35. RenderingContextInterface $renderingContext
  36. ) {
  37. return $_REQUEST;
  38. }
  39. }