Helper for setting and retrieving stylesheets

Allows the following method calls:

package Default
inherited_from \Zend\View\Helper\Placeholder\Container\AbstractStandalone

 Methods

Overload method calls

__call(string $method, array $args) : void

Proxy to container methods

inherited_from \Zend\View\Helper\Placeholder\Container\AbstractStandalone::__call()

Parameters

$method

string

$args

array

Exceptions

\Zend\View\Exception\BadMethodCallException When no $content provided or invalid method

Overload

__call(string $method, array $args) : mixed
Inherited

Proxy to container methods

Parameters

$method

string

$args

array

Exceptions

\Zend\View\Exception\BadMethodCallException

Returns

mixed

Constructor

__construct() 

Set separator to PHP_EOL.

inherited_from \Zend\View\Helper\Placeholder\Container\AbstractStandalone::__construct()

Constructor

__construct() 
Inherited

Overloading: retrieve property

__get(string $key) : mixed
Inherited

Parameters

$key

string

Returns

mixed

Return headStyle object

__invoke(string $content = null, string $placement = 'APPEND', string|array $attributes = array()) : \Zend\View\Helper\HeadStyle

Returns headStyle helper object; optionally, allows specifying

Parameters

$content

string

Stylesheet contents

$placement

string

Append, prepend, or set

$attributes

stringarray

Optional attributes to utilize

Returns

\Zend\View\Helper\HeadStyle

Overloading: check if property is set

__isset(string $key) : boolean
Inherited

Parameters

$key

string

Returns

boolean

Overloading: set property value

__set(string $key, mixed $value) : void
Inherited

Parameters

$key

string

$value

mixed

Cast to string representation

__toString() : string
Inherited

Returns

string

Overloading: unset property

__unset(string $key) : void
Inherited

Parameters

$key

string

Override append to enforce style creation

append(mixed $value) : void

Parameters

$value

mixed

Exceptions

\Zend\View\Exception\InvalidArgumentException

)

appendStyle() : 
magic
method )

Returns

End capture action and store

captureEnd() : void

Start capture action

captureStart(string $type = \Zend\View\Helper\Placeholder\Container\AbstractContainer::APPEND, string $attrs = null) : void

Parameters

$type

string

$attrs

string

Exceptions

\Zend\View\Exception\RuntimeException

Countable

count() : integer
Inherited

Returns

integer

Create data item for use in stack

createData(string $content, array $attributes) : \stdClass

Parameters

$content

string

$attributes

array

Returns

\stdClass

Delete a container

deleteContainer() : boolean
Inherited

Returns

boolean

Return whether autoEscaping is enabled or disabled

getAutoEscape() 
Inherited

return bool

Retrieve placeholder container

getContainer() : \Zend\View\Helper\Placeholder\Container\AbstractContainer
Inherited

Returns

\Zend\View\Helper\Placeholder\Container\AbstractContainer

Retrieve the container class

getContainerClass() : string
Inherited

Returns

string

Get Escaper instance

getEscaper(string|null $enc = 'UTF-8') : mixed
Inherited

Lazy-loads one if none available

Parameters

$enc

stringnull

Encoding to use

Returns

mixed

IteratorAggregate: get Iterator

getIterator() : \Iterator
Inherited

Returns

\Iterator

Get the view object

getView() : null | \Zend\View\Renderer\RendererInterface
Inherited
inherited_from \Zend\View\Helper\HelperInterface::getView()

Returns

null\Zend\View\Renderer\RendererInterface

Convert content and attributes into valid style tag

itemToString(\stdClass $item, string $indent) : string

Parameters

$item

\stdClass

Item to render

$indent

string

Indentation to use

Returns

string

ArrayAccess: offsetExists

offsetExists(string|integer $offset) : boolean
Inherited

Parameters

$offset

stringinteger

Returns

boolean

ArrayAccess: offsetGet

offsetGet(string|integer $offset) : mixed
Inherited

Parameters

$offset

stringinteger

Returns

mixed

Override offsetSet to enforce style creation

offsetSet(string|integer $index, mixed $value) : void
inherited_from \Zend\View\Helper\Placeholder\Container\AbstractStandalone::offsetSet()

Parameters

$index

stringinteger

$value

mixed

Exceptions

\Zend\View\Exception\InvalidArgumentException

ArrayAccess: offsetSet

offsetSet(string|integer $offset, mixed $value) : void
Inherited

Parameters

$offset

stringinteger

$value

mixed

)

offsetSetStyle() : 
magic
method )

Returns

ArrayAccess: offsetUnset

offsetUnset(string|integer $offset) : void
Inherited

Parameters

$offset

stringinteger

Override prepend to enforce style creation

prepend(mixed $value) : void

Parameters

$value

mixed

Exceptions

\Zend\View\Exception\InvalidArgumentException

)

prependStyle() : 
magic
method )

Returns

Override set to enforce style creation

set(mixed $value) : void

Parameters

$value

mixed

Exceptions

\Zend\View\Exception\InvalidArgumentException

Set whether or not auto escaping should be used

setAutoEscape(boolean $autoEscape = true) : \Zend\View\Helper\Placeholder\Container\AbstractStandalone
Inherited

Parameters

$autoEscape

boolean

whether or not to auto escape output

Returns

\Zend\View\Helper\Placeholder\Container\AbstractStandalone

Set container on which to operate

setContainer(\Zend\View\Helper\Placeholder\Container\AbstractContainer $container) : \Zend\View\Helper\Placeholder\Container\AbstractStandalone
Inherited

Parameters

$container

\Zend\View\Helper\Placeholder\Container\AbstractContainer

Returns

\Zend\View\Helper\Placeholder\Container\AbstractStandalone

Set the container class to use

setContainerClass(string $name) : \Zend\View\Helper\Placeholder\Container\AbstractStandalone
Inherited

Parameters

$name

string

Exceptions

\Zend\View\Exception\InvalidArgumentException
\Zend\View\Exception\DomainException

Returns

\Zend\View\Helper\Placeholder\Container\AbstractStandalone

Set Escaper instance

setEscaper(\Zend\Escaper\Escaper $escaper) : \Zend\View\Helper\Placeholder\Container\AbstractStandalone
Inherited

Parameters

$escaper

\Zend\Escaper\Escaper

Returns

\Zend\View\Helper\Placeholder\Container\AbstractStandalone

)

setStyle() : 
magic
method )

Returns

Set the View object

setView(\Zend\View\Renderer\RendererInterface $view) : \Zend\View\Helper\AbstractHelper
Inherited
inherited_from \Zend\View\Helper\HelperInterface::setView()

Parameters

$view

\Zend\View\Renderer\RendererInterface

Returns

\Zend\View\Helper\AbstractHelper

Create string representation of placeholder

toString(string|integer $indent = null) : string
inherited_from \Zend\View\Helper\Placeholder\Container\AbstractStandalone::toString()

Parameters

$indent

stringinteger

Returns

string

String representation

toString() : string
Inherited

Returns

string

Escape a string

escape(string $string) : string
Inherited

Parameters

$string

string

Returns

string

Determine if a value is a valid style tag

isValid(mixed $value) : boolean

Parameters

$value

mixed

Returns

boolean

 Properties

 

Flag whether to automatically escape output, must also be enforced in the child class if __toString/toString is overridden

$autoEscape : boolean

Default

true
 

Capture type and/or attributes (used for hinting during capture)

$captureAttrs : string

Default

null
 

Capture lock

$captureLock : boolean

Default

 

Capture type (append, prepend, set)

$captureType : string

Default

 

$container

$container : \Zend\View\Helper\Placeholder\Container\AbstractContainer

Default

 

Default container class

$containerClass : string

Default

'Zend\View\Helper\Placeholder\Container'
 

$escapers

$escapers : array<mixed,\Zend\Escaper\Escaper>

Default

array()
 

Allowed media types

$mediaTypes : array

Default

array('all', 'aural', 'braille', 'handheld', 'print', 'projection', 'screen', 'tty', 'tv')
 

Allowed optional attributes

$optionalAttributes : array

Default

array('lang', 'title', 'media', 'dir')
 

Registry key for placeholder

$regKey : string

Default

'Zend_View_Helper_HeadStyle'
 

View object instance

$view : \Zend\View\Renderer\RendererInterface

Default

null