Thursday, 3 December 2015

Start Xampp automatically when system start (In Ubuntu)


To Open Xampp Automatically  when system start Follow the Process

Open Terminal (Shortcut key  : cntr+alt+t )

Then type the following command

sudo  /opt/lampp/lampp start
sudo gedit /etc/init.d/lampp

It will open a file paste the following code in that file


#!/bin/bash
/opt/lampp/lampp start



Then save file and type following commands on terminal

sudo chmod +x /etc/init.d/lampp
sudo update-rc.d lampp defaults



Now restart your system.

Codeigniter Session error Message: mkdir(): Invalid path


A PHP Error was encountered

Severity: Warning

Message: mkdir(): Invalid path

Filename: drivers/Session_files_driver.php

Line Number: 117

Backtrace:

File: /home/xxxxx/public_html/xxxxx/application/controllers/xxxxx.php
Line: 8
Function: __construct

File: /home/xxxxx/public_html/xxxxx/index.php
Line: 292
Function: require_once

An uncaught Exception was encountered

Type: Exception

Message: Session: Configured save path '' is not a directory, doesn't exist or cannot be created.

Filename: /home/xxxxx/public_html/xxxxx/system/libraries/Session/drivers/Session_files_driver.php

Line Number: 119

Backtrace:

File: /home/xxxxx/public_html/xxxxx/application/controllers/xxxxx.php
Line: 8
Function: __construct

File: /home/xxxxx/public_html/xxxxx/index.php
Line: 292
Function: require_once



To Solve This error add this in config file found in application/config/config.php

$config['sess_save_path'] = sys_get_temp_dir();