public function render($name = null)
    {
        $args = func_get_args();
        $args[] = config('app.locale');

        return $this->executeCallback(static::class, __FUNCTION__, $args, function () use ($name) {
            $block = $this->prepareQuery($this->createModel())
                ->where('name', $name)
                ->published()
                ->first();

            return $block ? $block->present()->body : '';
        });
    }
public function render($name = null)
    {
        $args = func_get_args();
        $args[] = config('app.locale');

        return $this->executeCallback(static::class, __FUNCTION__, $args, function () use ($name) {
            $block = $this->prepareQuery($this->createModel())
                ->where('name', $name)
                ->published()
                ->first();

            return $block ? $block->present()->body : '';
        });
    }
public function render ( $ name = null ) { $ args = func_get_args ( ) ; $ args [ ] = config ( 'app.locale' ) ; return $ this -> executeCallback ( static :: class , __FUNCTION__ , $ args , function ( ) use ( $ name ) { $ block = $ this -> prepareQuery ( $ this -> createModel ( ) ) -> where ( 'name' , $ name ) -> published ( ) -> first ( ) ; return $ block ? $ block -> present ( ) -> body : '' ; } ) ; }
Get the content of a block.

@param string $name unique name of the block

@return string html
Get the content of a block .