月別アーカイブ: 2019年11月

Warning with PHP upgrade to 7.3

Warning: count(): Parameter must be an array or an object that implements Countable in …/wp-includes/post-template.php on line 310?

The following patch in the “post-template.php” was successful.

/*    if ( $elements['page'] > count( $elements['pages'] ) ) { // if the requested page doesn't exist
         $elements['page'] = count( $elements['pages'] ); // give them the highest numbered page that DOES exist
     }
 */ //replaced by the following 2019/11/11 k.n.
 if ( ! empty( $pages ) ) {
     if ( $page > count( $pages ) ) // if the requested page doesn't exist
         $page = count( $pages ); // give them the highest numbered page that DOES exist} else {
    $page = 0;
}
//replace end


WP move to subdirectory

  1. “japantourguide.net” has been installed in the root directory.
  2. Move everything except the directories for the sub-domains to the new japantourguide directory.
  3. Without modifying the “.htaccess” which is suggested by the WP.org, only change the directory in the LoLipop users setting.

webwork2@murakoshi-site

1.Again work on jtg1.japantourguide:Akismet activated key
52beeb76581d
2. Experienced many times “cannot login”. They were kind of cleared by renaming plugins and themes using ftp.
3. Finally became in good shape by recovering appropriate themes adventure and adventure-child.
4. There remains: on mobile (at least my m03), contact form submit button barely accessed.

webwork @murakoshi site

  1. After many troubles, restoring site and databases backups @2019.10.24 recovered almost everything.
  2. Backup site and databases @2019.10.30.
  3. But japantourguide.net cannot be logged in. Forget about this for the moment.
  4. and work on jsst4.japantourguide.net. It was working fine under wp4.9.12 ; updating all the plugins caused that strange black boxes; deactivating Autoptimize cleard that strange boxes.
  5. Based above, on japansightseeigtour.jp, deactivated Autoptimize, balack boxes gone.: Good Job!
  6. Back on jsst4: placed debug agent @wp-config.php;activated Akismet;reCAPTCHA set as jihsankn; akismet set on Mt.fuji contact; successfully reject trivial spam.;failed to introduce flamingo because of wp version.;now wp vesion up to 5.2.4 succesfully;seemingly all right;php version up to 7.3(CGI);php version up require message gone; still everything seems fine.;Now backup the site and related databases.
  7. Now work on jtg1: at the beginning, jtg1 site was not completely secure, but by clearing the discussion acceptance, the site turned to be secure.;activate Akismet key52beeb76581d;wp3.9.29 was running all right.; update to wp3.9.23?;still cannot get appropriate wp update;
  8. Because php update to 7.3(CGI) on jsst4 went without any problem, same php update was performed on japansightseeing, without any problem.
  9. jtg1 has the problem of inability of automatic wp core update, thus try manual update.; Following the procedure described at wp official site manual update to latest wp 5.4.2 went rather smoothly. Everything is seemingly O.K.;
  10. Now work on japantourguide: Could not be logged in. Manual wp update seemed only one choice.; Following the official procedure, updated to wp 5.4.2. Still could not be logged in 2 notices and 2 warnings.; Renaming pluginsX,was able to be logged in without any notices and warnings.; Activated akismet key 52beeb76581d;
  11. Remaining issues:1.Akismet&CF7&reCAPTCHA does’t work at japantourguide; 2.Either php7.1 or7.3 makes FATAL ERROR at japansightseeingtour/dashboard when clicking plugins at sidebar.
  12. japansightseeingtour: update php7.3 was O.K. by deactivating WP-editor, thus deleted this plugin.;Noteworthily,PHP Compatibility Checker could not detect the WP-Editor imcomatibilily to PHP7.1 nor 7.3.; This site claims to be healthy by Site Health Checker @2019/11/04. Remains: cannot set akismet protect on Homepage contact.