Closed (fixed)
Project:
Smart IP
Version:
7.x-1.4-alpha1
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
16 Jan 2011 at 21:04 UTC
Updated:
31 Jan 2011 at 08:00 UTC
Hi!
I have this notice while anonymous user comes to my site first time
Notice: Undefined variable: _SESSION in smart_ip_set_session_data() (line 336 of /home/content/06/7198206/html/sites/all/modules/smart_ip/smart_ip.module).
"Anonymous user" in "Roles To Geolocate" is selected.
I'm new to PHP, so how can I fix this? Should I just add new line before 336?
$_SESSION['smart_ip']['location'] = array()
Thank you!
Comments
Comment #1
arpeggio commentedHello,
Tried to replicate your issue, using the following setup:
- Installed fresh Drupal 7.0
- Enabled Smart IP 7.x-1.4-alpha1 (Device Geolocation not enabled)
- Enabled "Anonymous user" in "Roles To Geolocate"
Then I tried to open different browser to simulate first time anonymous user comes to my site and I got:
The fix is:
Already committed to CVS (Please use the development version). Thank you for reporting this bug.