Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8814087
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T04:01:08+00:00 2026-06-14T04:01:08+00:00

I know I am either skipping something or configured session incorrectly but Yii sessions

  • 0

I know I am either skipping something or configured session incorrectly but Yii sessions are not working for me. I have spent a lot of time in debugging and searching but it doesn’t result in any concrete answer.

As described in documentation as well as tutorials over internet I have configured my application session as follows:

'components'=>array(
    'user'=>array(
    // enable cookie-based authentication
    'allowAutoLogin'=>true,
    ),
    'session' => array (
    'sessionName' => 'Site Session',
    'class'=>'CHttpSession',
    'useTransparentSessionID'   =>($_POST['PHPSESSID']) ? true : false,
    'autoStart' => 'true',
    'cookieMode' => 'allow',
    'timeout' => 300
),

However each time I am sending a request to server, I get a new session object. I have verified same via echo "Session id: ".Yii::app()->session->sessionID;, every time it gives me different id. Also variables which I have added in session previously are not accessible due to this behaviour.

Kindly provide some pointers, I have spent more than 4 hours in debugging and looking for a solution. Tons of thanks for any pointers in advance.

Thanks

~Tarun

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T04:01:09+00:00Added an answer on June 14, 2026 at 4:01 am

    It could well be just that you have a space in your sessions name.

    I’ve just done a quick test on my working Yii instance, changed the session name to have a space in it, and the cookie value for the session seems to change every time.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I don't know anything about either library but I have to choose one of
This is something that I'm sure I should know the answer to, but either
I don't know either my implementation have bugs or StringBuilder is going wrong. From
I know this question was already posted in StackOverflow but I either didnt understand
I know this is a simple question, but either nobody is explaining it right,
I've heard about javascript solutions, and accessorkeys... Don't know either... but there seem to
I don't know either its possible to decrypt a shadow file or not. Just
does anyone know how to check if a file or directory is either a
Does anybody know how to force resize the image that opens in lightbox either
I need to know how many replacements are made by Powershell when using either

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.