Skip to content

Bug: saveData option doesn't work in Views #2818

Description

@njsx

I have a two views header.php and footer.php with a same content:

<h3><?= $title ?></h3>

In my Controller I have this code:


public function index() {

      $data['title'] = "Welcome!";

      echo view('header', $data);

      echo view('footer');


When I call this Controller I can see on my screen:
Welcome! Welcome!

In App\Config\View.php I set:
public $saveData = false; (or true doesn't matter)

In the UserManual

If you call the function multiple times in a single request, you will have to pass the desired data to each view.

Regardless of the transmitted values, this parameter does not work!!! I always see the same thing!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugVerified issues on the current code behavior or pull requests that will fix them

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions