think\View::replace PHP Method

replace() public method

视图内容替换
public replace ( string | array $content, string $replace = '' )
$content string | array 被替换内容(支持批量替换)
$replace string 替换内容
    public function replace($content, $replace = '')
    {
        if (is_array($content)) {
            $this->replace = array_merge($this->replace, $content);
        } else {
            $this->replace[$content] = $replace;
        }
        return $this;
    }