var_dump(CI_VERSION);
var_dump(realpath(BASEPATH));
$config['sess_driver'] = 'files'; $config['sess_cookie_name'] = 'ci_session'; $config['sess_expiration'] = 7200; $config['sess_save_path'] = NULL; $config['sess_match_ip'] = FALSE; $config['sess_time_to_update'] = 300; $config['sess_regenerate_destroy'] = FALSE;
Remove $config['sess_match_useragent']
The user-agent string is input supplied by the user’s browser, or in other words: client side input. As such, it is an ineffective feature and hence why it has been removed.
Remove $config['sess_encrypt_cookie']
As already noted, the library no longer uses cookies as a storage mechanism, which renders this option useless.
Remove $config['sess_expire_on_close']
This option is still usable, but only for backwards compatibility purposes and it should be otherwise removed. The same effect is achieved by setting $config['sess_expiration'] to 0.
참고로 위의 내용대로 테스트 다 해 봤습니다.
위에 캡처한 내용은 테스트를 위해서 일부러 넣어 봤는데, 그걸 복사해서 붙였네요.
혹시 위의 내용을 누군가 답변으로 올릴까봐 미리 알려드립니다.
저도 라이프러리에서 안되는 경우였는데 라이브러리가 컨트롤러를 상속받아 안되는 경우였습니다.
get_instance()가 controller를 잘못 받아와서 생기는 문제더라구요. 상속받은 클래스를 다시 살펴보세요.
컨트롤러/모델에서 사용하시에는 변화가 없지만 autoload.php에 등록시 library 가 아니라 driver 에 등록해 줘야 사용이 가능 합니다.
/* | ------------------------------------------------------------------- | Auto-load Drivers | ------------------------------------------------------------------- | These classes are located in the system/libraries folder or in your | application/libraries folder within their own subdirectory. They | offer multiple interchangeable driver options. | | Prototype: | | $autoload['drivers'] = array('session', 'cache'); */ $autoload['drivers'] = array('session');