public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext): string
    {
        $key = $arguments['key'];
        $value = $arguments['value'];

        array_push($GLOBALS['TSFE']->registerStack, $GLOBALS['TSFE']->register);
        $GLOBALS['TSFE']->register[$key] = $value;

        $content = $renderChildrenClosure();

        if ($content) {
            // Restore register when content was rendered
            $GLOBALS['TSFE']->register = array_pop($GLOBALS['TSFE']->registerStack);

            return $content;
        }

        return '';
    }
public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext): string
    {
        $key = $arguments['key'];
        $value = $arguments['value'];

        array_push($GLOBALS['TSFE']->registerStack, $GLOBALS['TSFE']->register);
        $GLOBALS['TSFE']->register[$key] = $value;

        $content = $renderChildrenClosure();

        if ($content) {
            // Restore register when content was rendered
            $GLOBALS['TSFE']->register = array_pop($GLOBALS['TSFE']->registerStack);

            return $content;
        }

        return '';
    }
public static function renderStatic ( array $ arguments , \ Closure $ renderChildrenClosure , RenderingContextInterface $ renderingContext ) : string { $ key = $ arguments [ 'key' ] ; $ value = $ arguments [ 'value' ] ; array_push ( $ GLOBALS [ 'TSFE' ] -> registerStack , $ GLOBALS [ 'TSFE' ] -> register ) ; $ GLOBALS [ 'TSFE' ] -> register [ $ key ] = $ value ; $ content = $ renderChildrenClosure ( ) ; if ( $ content ) { // Restore register when content was rendered $ GLOBALS [ 'TSFE' ] -> register = array_pop ( $ GLOBALS [ 'TSFE' ] -> registerStack ) ; return $ content ; } return '' ; }
Renders the viewhelper.

@param array $arguments
@param \Closure $renderChildrenClosure
@param RenderingContextInterface $renderingContext
@return string
Renders the viewhelper .