We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PHP error: Error Call to a member function setFileName() on null
/* var_dump(is_file($path)); // return true var_dump(basename($path)); // return test.zip */ return $this->response->download($path)->setFileName(basename($path));
CI Version: 4.0.2 PHP Version: 7.4.3
The text was updated successfully, but these errors were encountered:
Try setting the second argument of $this->response->download to a value of null.
$this->response->download
null
Sorry, something went wrong.
According to the documentation, the second argument is unnecessary. Is this counted as a bug?
From the docs: If you set the second parameter to NULL and $filename is an existing, readable file path, then its content will be read instead.
$filename
Based on your code example, you really need to set the second argument to null.
No branches or pull requests
PHP error: Error Call to a member function setFileName() on null
CI Version: 4.0.2
PHP Version: 7.4.3
The text was updated successfully, but these errors were encountered: