• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

cfcookie problem between computers

Community Beginner ,
Jan 30, 2014 Jan 30, 2014

Copy link to clipboard

Copied

I am migrating websites from a server using CF 8 to a new one using CF 10. In this one site, I have a query that looks up talent and then writes the resulting list to a cfcookie. On my computer with any browser it works correctly. My client uses the same browser as I normally use (Safari) and his browser is not updating the cfcookie with the new talent list after a search. They are very unhappy making me unhappy also. Any ideas as to what might be causing this problem.

In the application.cfm (yes, I know I should be updating to cfc but not enough hours in the day):

<CFAPPLICATION NAME="lil"

          CLIENTMANAGEMENT="yes"

          SESSIONMANAGEMENT="yes"

          SESSIONTIMEOUT=" #createTimeSpan(0,0,30,0)#"

          APPLICATIONTIMEOUT=" #createTimeSpan(0,1,0,0)#"

          clientstorage="cookie">

Setting the cfcookie:

<cfif isdefined('getTalent.recordcount') and getTalent.recordcount gt 0>

         <cfcookie name="tSearch" value="#valueList(getTalent.talentID)#" expires="1">

</cfif>

Views

399

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 01, 2014 Feb 01, 2014

Copy link to clipboard

Copied

LATEST

My guess is that the cookie tag fails to run. The reason is that the variable getTalent.recordcount is undefined. In any case, this points to a potentially bigger problem.

It appears from your description that the query getTalent depends on the user. You should therefore scope it accordingly. For example, wherever the variable getTalent occurs, including in the cfquery tag that defines it, you should change it to session.getTalent.

Also, if only just to tidy things up, I would delete the spaces in the definitions of sessionTimeout and applicationTimeout. I would also set the value of applicatonTimeout to createTimeSpan(1,0,0,0). After all, the cookie is valid for up to a day.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation