Skip to content

Stash ​

php
final class KMark\Stash

HTML that is put aside while a text is read, so that nothing reads it again: each piece is replaced by a token, and the tokens are replaced by the pieces at the end.

Source: src/Stash.php

Methods ​

clean() ​

php
public static function clean(string $text): string

The text without the characters that make the tokens, so that a text cannot forge one.

put() ​

php
public function put(string $html): string

Puts a piece of HTML aside and gives the token that stands for it.

restore() ​

php
public function restore(string $text): string

Writes the pieces back, the ones that hold tokens too.

Documentation of 2.0.0 , built from f573e5f on 2.0.0 by pipeline #37507527063 on 2026-10-06.