Welcome to the Webmaster Forum.
Results 1 to 5 of 5
  1. #1
    Senior Member
    Join Date
    May 2014
    Posts
    394

    Remove data from a session ?

    Hello Dear,

    Please Tell Me How to Remove data from a session ?

  2. #2
    Member
    Join Date
    Sep 2018
    Posts
    92

    Re: Remove data from a session ?

    session_destroy() destroys all of the data associated with the current session. It does not unset any of the global variables associated with the session, or unset the session cookie. To use the session variables again, session_start() has to be called. Note: You do not have to call session_destroy() from usual code.

  3. #3
    Senior Member
    Join Date
    Sep 2018
    Posts
    242

    Re: Remove data from a session ?

    session_unset - Frees all session variables (It is equal to using: $_SESSION = array(); )
    unset($_SESSION['Products']); - Unset only Products index in session variable.
    session_destroy Destroys all data registered to a session.


    Top Indian Astrologer in Canada | Indian Astrologer in Toronto Top Astrology Services in Canada | Top Indian Astrologer in Toronto | Horoscope Reading Services in Canada

  4. #4
    Senior Member
    Join Date
    Sep 2018
    Posts
    133

    Re: Remove data from a session ?

    It is more difficult then to recover data.As a regular user, I need things to be quick and easy. So I chose to use backup soft with these guys https://lostdongle.com/ It has become a discovery to me that this product is easy to use.This tool will also be necessary for you.

  5. #5
    Senior Member
    Join Date
    Aug 2017
    Location
    South Africa
    Posts
    200

    Re: Remove data from a session ?

    You should be careful when using unset as a way to clear sessions as it messes with the way a global like session actually work. Something like this will work unset($_SESSION['name'][$key]); YOu havent really madeclear however what you want to clear from the session of the visitor based on that I would have diffrent answers on what the best practice is for website development.

 

 

Similar Threads

  1. Replies: 0
    Last Post: 01-24-2018, 05:04 AM
  2. Data Entry Business || Sunita Network Pvt Ltd|| Data Entry Service
    By sunitanetwork in forum Social Media & Bookmarking Forums
    Replies: 0
    Last Post: 08-09-2017, 02:28 AM
  3. How to analyze exact traffic session by session?
    By ShreyaKoushik23 in forum Search Engine Optimization (SEO)
    Replies: 0
    Last Post: 12-09-2016, 04:48 AM
  4. What Do You Mean by Session in GA?
    By CarolineMurphy89 in forum Search Engine Optimization (SEO)
    Replies: 0
    Last Post: 05-06-2016, 11:06 AM
  5. Replies: 0
    Last Post: 04-09-2015, 01:52 AM

Bookmarks

Posting Permissions

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

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 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203