Jump to content
TNG Community

OpenStreetMap mod v14.0.5.9c installation errors with TNG v14.0.6


OPM

Recommended Posts

Hello,

I have tried to install the OSM Mod v14.0.5.9c under TNG v14.0.6 - unfortunately without success. The TNG installation (https://www.mirke.org) is virgin, i.e. I have not made any changes, installed no other mods and the language is set to English. The necessary OSM mod files can be found in the mod folder.

 

The Mod Manager reports a total of 6 errors:

line 223: %location #2 v867 %replace Bad target

line 361: %location #2 v867 %replace Bad target

line 473: %location #2 v867 %replace Bad target

line 604: %location #2 v867 %replace Bad target

line 716: %location #2 v867 %replace Bad target

line 909: %location #1 v867 %replace Bad target

 

I have thoroughly checked the affected files (the originals from the installation file and those on my server) and found no errors:

 

admin_editplace.php (line 223: %location #2 v867 %replace Bad target)

line 51 - if ( $map['key'] && $isConnected) ...

 

admin_editmedia.php (line 361: %location #2 v867 %replace Bad target)

line 140 - if ( $map['key'] && $isConnected) ...

 

admin_newplace.php (line 473: %location #2 v867 %replace Bad target)

line 37 - if ( $map['key'] && $isConnected) ...

 

admin_editcemetery.php (line 604: %location #2 v867 %replace Bad target)

line 40 - if ( $map['key'] && $isConnected) ...

 

admin_newcemetery.php (line 716: %location #2 v867 %replace Bad target)

line 30 - if ( $map['key'] && $isConnected) ...

 

placesearch.php verified (line 909: %location #1 v867 %replace Bad target)

line 300 - if ( $map['key'] && $isConnected) ...

 

All files contain exactly those lines that are to be replaced according to the openstreetmap_v14.0.5.9c file.

I have a second website with TNG version v14.0.5, where I was able to install the OSM mod without any problems.

 

Is there a solution for the described problem? Many thanks for your suggestions.

Link to comment
Share on other sites

@OPM

You need to download and install the version of the OpenStreetMap that was published for TNG 14.0.5 with Google maps patch that applies to TNG v14.0.6

Link to comment
Share on other sites

Hello,

I have now found the cause of the six errors in the openstreetmap_v14.0.5.9c.cfg file. The mod manager should search for the string

   src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"

and replace it, but in the six files concerned, the string is

   src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"

so without the part

   &loading=async

A small but crucial difference that causes the installation of the mod to fail. I changed the configuration file accordingly and was then able to install the OSM mod without any problems.

--------------------

openstreetmap_v14.0.5.9c.cfg

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"></script>\n";

 

admin_editplace.php

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"></script>\n";

--------------------

openstreetmap_v14.0.5.9c.cfg

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"></script>\n";

 

admin_editmedia.php

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"></script>\n";

--------------------

openstreetmap_v14.0.5.9c.cfg

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"></script>\n";

 

admin_newplace.php

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"></script>\n";

--------------------

openstreetmap_v14.0.5.9c.cfg

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"></script>\n";

 

admin_editcemetery.php

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"></script>\n";

--------------------

openstreetmap_v14.0.5.9c.cfg

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"></script>\n";

 

admin_newcemetery:

if( $map['key'] && $isConnected)

echo "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"></script>\n";

--------------------

openstreetmap_v14.0.5.9c.cfg

if( $map['key'] && $isConnected) {

if( !isset($flags['scripting']) ) $flags['scripting'] = "";

$flags['scripting'] .= "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}&loading=async$mapkeystr\"></script>\n";

}

 

placesearch.php

if( $map['key'] && $isConnected) {

if( !isset($flags['scripting']) ) $flags['scripting'] = "";

$flags['scripting'] .= "<script type=\"text/javascript\" src=\"{$http}://maps.googleapis.com/maps/api/js?language={$text['glang']}$mapkeystr\"></script>\n";

}

 

Link to comment
Share on other sites

Please download and install the correct version of the OpenStreetMap mod.  You are trying to install the version of the mod for TNG v14.0.5 that did not have the fix for Google Maps. 

Note that the OpenStreetMap mod changes the TNG code for Google Maps so you need to download the version that is marked for TNG v14.0.6

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...