]> git.openstreetmap.org Git - nominatim.git/blobdiff - utils/specialphrases.php
Merge pull request #1314 from mtmail/query-php-5dot4
[nominatim.git] / utils / specialphrases.php
old mode 100755 (executable)
new mode 100644 (file)
index ec00cb6..cb237be
@@ -1,7 +1,5 @@
-#!/usr/bin/php -Cq
 <?php
 
-require_once(dirname(dirname(__FILE__)).'/settings/settings.php');
 require_once(CONST_BasePath.'/lib/init-cmd.php');
 ini_set('memory_limit', '800M');
 ini_set('display_errors', 'stderr');
@@ -16,7 +14,7 @@ $aCMDOptions
   );
 getCmdOpt($_SERVER['argv'], $aCMDOptions, $aCMDResult, true, true);
 
-include(CONST_InstallPath.'/settings/phrase_settings.php');
+include(CONST_Phrase_Config);
 
 if ($aCMDResult['wiki-import']) {
     $oNormalizer = Transliterator::createFromRules(CONST_Term_Normalization_Rules);
@@ -27,7 +25,7 @@ if ($aCMDResult['wiki-import']) {
          'ia,is,it,ja,mk,nl,no,pl,ps,pt,ru,sk,sl,sv,uk,vi');
 
     foreach (explode(',', $sLanguageIn) as $sLanguage) {
-        $sURL = 'http://wiki.openstreetmap.org/wiki/Special:Export/Nominatim/Special_Phrases/'.strtoupper($sLanguage);
+        $sURL = 'https://wiki.openstreetmap.org/wiki/Special:Export/Nominatim/Special_Phrases/'.strtoupper($sLanguage);
         $sWikiPageXML = file_get_contents($sURL);
         if (preg_match_all('#\\| ([^|]+) \\|\\| ([^|]+) \\|\\| ([^|]+) \\|\\| ([^|]+) \\|\\| ([\\-YN])#', $sWikiPageXML, $aMatches, PREG_SET_ORDER)) {
             foreach ($aMatches as $aMatch) {