Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+2 votes
1.0k views
in Q2A Core by
edited by

When many plugins are installed, "Admin" > "Plugins" page is very slow. In case of worst, we can not operate page.

This is caused by version check of plugins. I hope that check code is stoped by some admin option 

Example source (qa-include/qa-page-admin-plugins.php [around L151]):

if (strlen(@$metadata['version']) && strlen(@$metadata['update'])) {
  if(qa_opt('version_check')) {
    $elementid='version_check_'.md5($plugindirectory);
    $updatehtml='(<span id="'.$elementid.'">...</span>)';
    $qa_content['script_onloads'][]=array("qa_version_check(".qa_js($metadata['update']).", 'Plugin Version', ".qa_js($metadata['version'], true).", 'Plugin URI', ".qa_js($elementid).");"
  );
  }
} else
...
 
Q2A version: 1.6.3
by
I think the issue with your plugins and (and admin/general page) is something else. The plugin checks are done via JavaScript after page load. And the iframes on /general load fast for me.
by
edited by
I recommend that you investigate a little more. It is not page display performance that I think as problem. If we install much plugin, much javascript moves. Besides, the processing of each javascript is very long. While Javascript moves, we cannot scroll page. In other words screen is locked. This behavior may depend on browser.
by
How many plugins do you have installed?
by
I tested various plugins for FlexArmor2.
http://askive.cmsbox.jp/demo/flexarmor2/document-25-compatibility
Now, there is 37 plugins in my qa-plugin folder. 10 plugins of those do version check. They are plugins of you, Kai, NoarY and etc. My plugins do not check version. Therefore, when I remove these 10 plugins, phenomenon does not occur.

1 Answer

0 votes
by

I will post hack source for the person who has been already troubled.

qa-include/qa-app-options.php (L360) : Add 1 line

'version_check' => 1, // Add ASKIVE
qa-include/qa-lang-options.php (L261) : Add 1 line
'version_check' => 'Version check', // Add ASKIVE
qa-include/qa-page-admin-default.php: Add 1 line (L217) , Replace 1 line (L281)
'version_check' => 'checkbox', // Add ASKIVE
//$showoptions=array('site_title', 'site_url', 'neat_urls', 'site_language', 'site_theme', 'site_theme_mobile', 'tags_or_categories', 'site_maintenance');
$showoptions=array('site_title', 'site_url', 'neat_urls', 'site_language', 'site_theme', 'site_theme_mobile', 'tags_or_categories', 'site_maintenance', 'version_check');  // Replace ASKIVE
qa-include/qa-page-admin-plugins.php: Add 2 line (L151 and L159)
if(qa_opt('version_check')) { // Add ASKIVE
  $elementid='version_check_'.md5($plugindirectory);
 
  $updatehtml='(<span id="'.$elementid.'">...</span>)';
 
  $qa_content['script_onloads'][]=array(
  "qa_version_check(".qa_js($metadata['update']).", 'Plugin Version', ".qa_js($metadata['version'], true).", 'Plugin URI', ".qa_js($elementid).");"
  );
} // Add ASKIVE
...