简体   繁体   中英

Codeigniter in PHPStorm

I need to know if any special configuration in the ide PhpStorm to use CodeIgniter . I'm having problems permission to access session variables and writing temporary files . The server is XAMPP local for IOS

Error from comment

A PHP Error was encountered Severity: Warning Message: Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/Applications/temp/) Filename: Unknown Line Number: 0 Backtrace: A PHP Error was encountered Severity: Warning Message: Unknown: open(/Applications/temp//sess_acelvldc0c60ti1pj13fmil6t6, O_RDWR) failed: Permission denied (13) Filename: Unknown Line Number: 0 Backtrace

When you use session files on codeigniter 3

Where ever you save your file example:

application

application > temp

Then on your config.php

$config['sess_driver'] = 'files';
$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration'] = 7200;
$config['sess_save_path'] = APPPATH . 'temp/';
$config['sess_match_ip'] = TRUE;
$config['sess_time_to_update'] = 300;
$config['sess_regenerate_destroy'] = FALSE;

Make sure the sess_save_path has / at end.

Also make sure you have set temp folder permissions to chmod 0700 You need set permission for your var directory

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM