MyBB Community Forums

Full Version: skunkmap
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
By using the skunkmap I get lots of errors

http://www.ikf-forum.eu/skunkmap.php

Warning: fopen(/usr/home/deb4195/domains/ikf-forum.eu/public_html//inc/skunkmap/GeoLiteCity.dat) [function.fopen]: failed to open stream: No such file or directory in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 313

Warning: fstat(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 315

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 316

Warning: ftell(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 266

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 267

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fread(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 269

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 294

Warning: fseek(): supplied argument is not a valid stream resource in /usr/home/deb4195/domains/ikf-forum.eu/public_html/inc/skunkmap/geoip.inc on line 302
You didn't download GeoLite City:
http://www.maxmind.com/app/geolitecity

Ow, I made a fix for skunkmap:
http://community.mybboard.net/showthread...#pid182726
I guess this will cost me alot of bandwidth??
Now the page start with USA, can it start with europe.
Change the seletcted items do not work!!!
Open skunkmap.php and find:
// This sets up the items for the map changer selection box

$selectitems[0]['name'] = "USA";
$selectitems[0]['lat'] = "37.0625";
$selectitems[0]['lon'] = "-95.677068";
$selectitems[0]['zoom'] = "4";
$selectitems[1]['name'] = "Europe";
$selectitems[1]['lat'] = "49.439557";
$selectitems[1]['lon'] = "11.513672";
$selectitems[1]['zoom'] = "4";
$selectitems[2]['name'] =  "World";
$selectitems[2]['lat'] = "31.353637";
$selectitems[2]['lon'] = "-1.054687";
$selectitems[2]['zoom'] = "2";

Replace with:
// This sets up the items for the map changer selection box
$selectitems[0]['name'] = "Europe";
$selectitems[0]['lat'] = "49.439557";
$selectitems[0]['lon'] = "11.513672";
$selectitems[0]['zoom'] = "4";
$selectitems[1]['name'] = "USA";
$selectitems[1]['lat'] = "37.0625";
$selectitems[1]['lon'] = "-95.677068";
$selectitems[1]['zoom'] = "4";
$selectitems[2]['name'] =  "World";
$selectitems[2]['lat'] = "31.353637";
$selectitems[2]['lon'] = "-1.054687";
$selectitems[2]['zoom'] = "2";
Paretje Wrote:Open skunkmap.php and find:
// This sets up the items for the map changer selection box

$selectitems[0]['name'] = "USA";
$selectitems[0]['lat'] = "37.0625";
$selectitems[0]['lon'] = "-95.677068";
$selectitems[0]['zoom'] = "4";
$selectitems[1]['name'] = "Europe";
$selectitems[1]['lat'] = "49.439557";
$selectitems[1]['lon'] = "11.513672";
$selectitems[1]['zoom'] = "4";
$selectitems[2]['name'] =  "World";
$selectitems[2]['lat'] = "31.353637";
$selectitems[2]['lon'] = "-1.054687";
$selectitems[2]['zoom'] = "2";

Replace with:
// This sets up the items for the map changer selection box
$selectitems[0]['name'] = "Europe";
$selectitems[0]['lat'] = "49.439557";
$selectitems[0]['lon'] = "11.513672";
$selectitems[0]['zoom'] = "4";
$selectitems[1]['name'] = "USA";
$selectitems[1]['lat'] = "37.0625";
$selectitems[1]['lon'] = "-95.677068";
$selectitems[1]['zoom'] = "4";
$selectitems[2]['name'] =  "World";
$selectitems[2]['lat'] = "31.353637";
$selectitems[2]['lon'] = "-1.054687";
$selectitems[2]['zoom'] = "2";

I have done exactly that and the card is still USA only pulldown menu at the top is now Europe as the first. Am I would prefer if the German map displayed about. I can not even own pin! He always writes that he does not find the place.
Ow, I forgot something: the default one is hard-coded:

Open skunkmap.php and find:
echo '<div id="map" style="width: '.$width.'px; height:'.$height.'px"></div>
                    <script type="text/javascript">
                var map = new GMap2(document.getElementById("map"));
        map.setCenter(new GLatLng(37.0625,-95.677068),4);
map.addControl(new GSmallMapControl());
map.addControl(new GMapTypeControl());';

Replace with:
echo '<div id="map" style="width: '.$width.'px; height:'.$height.'px"></div>
                    <script type="text/javascript">
                var map = new GMap2(document.getElementById("map"));
        map.setCenter(new GLatLng('.$selectitems[0]['lat'].','.$selectitems[0]['lon'].'),'.$selectitems[0]['zoom'].');
map.addControl(new GSmallMapControl());
map.addControl(new GMapTypeControl());';

Now, it's defaultly the 0 Wink

And when you want to make Germany default replace that with Europe, USA World with this:
// This sets up the items for the map changer selection box
$selectitems[0]['name'] = "Germany";
$selectitems[0]['lat'] = "51.165691";
$selectitems[0]['lon'] = "10.451526";
$selectitems[0]['zoom'] = "5";
$selectitems[1]['name'] = "Europe";
$selectitems[1]['lat'] = "49.439557";
$selectitems[1]['lon'] = "11.513672";
$selectitems[1]['zoom'] = "4";
$selectitems[2]['name'] = "USA";
$selectitems[2]['lat'] = "37.0625";
$selectitems[2]['lon'] = "-95.677068";
$selectitems[2]['zoom'] = "4";
$selectitems[3]['name'] =  "World";
$selectitems[3]['lat'] = "31.353637";
$selectitems[3]['lon'] = "-1.054687";
$selectitems[3]['zoom'] = "2"; 
Thx Paretje it works, but the map dont find my location :-(

my location 15806 Zossen, Germany
It's because it isn't in the GeoLite City database. You can do it manual:
1. Go to AdminCP -> Users and Groups ->Custom Profile Fields
2. Look to the ID of the field SkunkMap Settings
3. Go with PHPMyAdmin to the table mybb_userfields
4. Go to the data of your account
5. Fill in the field fid[ID of the SkunkMap Settings] this: 52.216667;13.450000;;Germany
6. Save

Now, it must be in Zossen

Thanks to Wikipedia for the coordinates.