Deleting or Modifying Session Variables in anothersession

Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default Deleting or Modifying Session Variables in anothersession

    Is it possible to delete or clear session variable from another session?

    Here's my scenario.

    A user opens the public part of a web site which uses an application.cfc and
    the application name "abc".

    \abc\application.cfc

    They then access a private area of the site which is contained within a
    subdirectory (bc) of the main site.

    \abc\bc\application.cfc

    The private area uses a different application.cfc and a different application
    name - "abcbc".

    The user then makes a change in a form which should ideally affect the session
    variables in the first session.

    Is there a way to make changes to or delete variables in another session? If
    so how would I identify them?



    drmaves Guest

  2. Similar Questions and Discussions

    1. #39833 [NEW]: Session variables overwritten by local variables (register_globals=off)
      From: sup1382 at accedo dot es Operating system: OpenBSD 3.9 PHP version: 5.2.0 PHP Bug Type: Session related Bug...
    2. #39447 [NEW]: Want to optionally handle apc_upload_progress variables using session variables
      From: krudtaa at yahoo dot com Operating system: All PHP version: 5.2.0 PHP Bug Type: Feature/Change Request Bug...
    3. #25629 [Opn->Bgs]: session cookie being set to deleted when deleting a session
      ID: 25629 Updated by: sniper@php.net Reported By: john at tarot dot com -Status: Open +Status: Bogus...
    4. deleting session variables
      Is there a way to wipe out all previous session variables with one command? Thx Tim Winters Creative Development Manager Sampling...
    5. fork and modifying variables inside the new process
      irb(main):001:0> a = true => true irb(main):002:0> fork do irb(main):003:1* a = false irb(main):004:1> end => 2525 irb(main):005:0> a => true
  3. #2

    Default Re: Deleting or Modifying Session Variables in another session

    > Is there a way to make changes to or delete variables in another session?
    If
    > so how would I identify them?
    You could make a list of the active sessions in the server scope. This will
    allow you to access/modify the data from all cfm files.

    --
    <mack />


    Neculai Macarie Guest

  4. #3

    Default Re: Deleting or Modifying Session Variables in anothersession

    I'm not sure how that would help or how to generate a list like that.

    What I would need to be able to do is set the session variables in the first
    session to new values using something like <cfset> so I need to know how to
    address those variables. As I see it now something like <cfset session.name =
    "Smith"> would only affect the current session's variable. Is there a prefix to
    "session" that would identify which session it is?


    drmaves Guest

  5. #4

    Default Re: Deleting or Modifying Session Variables in another session

    > I'm not sure how that would help or how to generate a list like that. 
    first 
    to 
    session.name = 
    prefix to 

    On session start you would put each session in the server scope:
    server.sessions[session.sessionid] = session

    then, in the second app:
    server.sessions["#first_app_name#_"&session.CFID&"_"&session.cftok en].name =
    "Smith"

    --
    <mack />


    Neculai Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139