Skip to content

Instantly share code, notes, and snippets.

@azazqadir azazqadir/index.php

Created Sep 25, 2018
What would you like to do?
Configuring Redis to be used as a PHP session Handler: ( )
ini_set('session.save_handler', 'redis');
ini_set('session.save_path', "tcp://localhost:6379");
//echo ini_get('session.save_path');
$count = isset($_SESSION['count']) ? $_SESSION['count'] : 1;
echo $count;
$_SESSION['count'] = ++$count;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.