Cleaner



( ZN >= 1.0.0 )

Used for deleting sequences and textual expressions.

 

 

# Methods


Below is a schematic of the Cleaner library.

Mixed data ( Mixed $ searchData , Mixed $ cleanWord )

 

 

# Data ( ZN >= 4.0.1-EIP )


Used to clean expressions in strings or in texts.

Parameters

Mixed $ Searchdata The string or array to search.
Mixed $ CleanData The string or array to delete.
return Mixed

uses

\Output::writeLine( Cleaner::data('robot@znframework.com', 'robot') );
\Output::writeLine( Cleaner::data('robot@znframework.com', ['robot', '.com']) );
@ znframework.com
@znframework 

Delete in Series

output( Cleaner::data(['a', 'b', 'c'], 'b') );
output( Cleaner::data(['a', 'b', 'c'], ['b', 'c']) );
0 => string 'a' (length = 3 )
2 => string 'c' (length = 3 )
0 => string 'a' (length = 3 )